Help with Cakephp 2.x pagination

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Help with Cakephp 2.x pagination

Clement Crownrise
Hello everyone, below is the first page of my list page, The first attachment..

On clicking on any of the data on the first page, it will open up and show like the second attachment.

Now the problem is, I want to add a "Next " and "Previous" button to the second attachment, so that I will not need to go to the first page(first attachment ) in order to access the next or previous record.

HOW CAN I ACHIEVE THIS?

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.

firstListing.jpeg (137K) Download Attachment
secondListing.jpeg (86K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Help with Cakephp 2.x pagination

Matthew Kaufman
Use the get neighbors function.

On Mon, Dec 28, 2015 at 5:32 PM, Clement Crownrise <[hidden email]> wrote:
Hello everyone, below is the first page of my list page, The first attachment..

On clicking on any of the data on the first page, it will open up and show like the second attachment.

Now the problem is, I want to add a "Next " and "Previous" button to the second attachment, so that I will not need to go to the first page(first attachment ) in order to access the next or previous record.

HOW CAN I ACHIEVE THIS?

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Help with Cakephp 2.x pagination

Clement Crownrise
Thanks for your response, but please what is the neighbour function?

Can you please paste the sytax here.

Thanks


On Monday, December 28, 2015 at 11:35:36 PM UTC+1, Matthew Kaufman wrote:
Use the get neighbors function.

On Mon, Dec 28, 2015 at 5:32 PM, Clement Crownrise <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="hYXMuyj0DwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">clementc...@...> wrote:
Hello everyone, below is the first page of my list page, The first attachment..

On clicking on any of the data on the first page, it will open up and show like the second attachment.

Now the problem is, I want to add a "Next " and "Previous" button to the second attachment, so that I will not need to go to the first page(first attachment ) in order to access the next or previous record.

HOW CAN I ACHIEVE THIS?

--
Like Us on FaceBook <a href="https://www.facebook.com/CakePHP" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\75https%3A%2F%2Fwww.facebook.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNG_OVGPrsW2S4xCvT0yb2leRWBsQg&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\75https%3A%2F%2Fwww.facebook.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNG_OVGPrsW2S4xCvT0yb2leRWBsQg&#39;;return true;">https://www.facebook.com/CakePHP
Find us on Twitter <a href="http://twitter.com/CakePHP" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\75http%3A%2F%2Ftwitter.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNGm99t3RztzLJAbpv22cUAOb0aFHw&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\75http%3A%2F%2Ftwitter.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNGm99t3RztzLJAbpv22cUAOb0aFHw&#39;;return true;">http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="hYXMuyj0DwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">cake-php+u...@googlegroups.com.
To post to this group, send email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="hYXMuyj0DwAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">cake...@....
Visit this group at <a href="https://groups.google.com/group/cake-php" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/group/cake-php&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/cake-php&#39;;return true;">https://groups.google.com/group/cake-php.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Help with Cakephp 2.x pagination

John Andersen
As Matthew wrote, use the Neighbor function. See the CakePHP book in this page:
http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#find-neighbors

Enjoy, John

On Tuesday, 29 December 2015 00:54:37 UTC+2, Clement Crownrise wrote:
Thanks for your response, but please what is the neighbour function?

Can you please paste the sytax here.

Thanks


On Monday, December 28, 2015 at 11:35:36 PM UTC+1, Matthew Kaufman wrote:
Use the get neighbors function.

On Mon, Dec 28, 2015 at 5:32 PM, Clement Crownrise <[hidden email]> wrote:
Hello everyone, below is the first page of my list page, The first attachment..

On clicking on any of the data on the first page, it will open up and show like the second attachment.

Now the problem is, I want to add a "Next " and "Previous" button to the second attachment, so that I will not need to go to the first page(first attachment ) in order to access the next or previous record.

HOW CAN I ACHIEVE THIS?

--
Like Us on FaceBook <a href="https://www.facebook.com/CakePHP" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\75https%3A%2F%2Fwww.facebook.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNG_OVGPrsW2S4xCvT0yb2leRWBsQg&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\75https%3A%2F%2Fwww.facebook.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNG_OVGPrsW2S4xCvT0yb2leRWBsQg&#39;;return true;">https://www.facebook.com/CakePHP
Find us on Twitter <a href="http://twitter.com/CakePHP" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\75http%3A%2F%2Ftwitter.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNGm99t3RztzLJAbpv22cUAOb0aFHw&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\75http%3A%2F%2Ftwitter.com%2FCakePHP\46sa\75D\46sntz\0751\46usg\75AFQjCNGm99t3RztzLJAbpv22cUAOb0aFHw&#39;;return true;">http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at <a href="https://groups.google.com/group/cake-php" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/group/cake-php&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/cake-php&#39;;return true;">https://groups.google.com/group/cake-php.
For more options, visit <a href="https://groups.google.com/d/optout" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Help with Cakephp 2.x pagination

Clement Crownrise
Thanks @John

On Tue, Dec 29, 2015 at 8:53 AM, John Andersen <[hidden email]> wrote:
As Matthew wrote, use the Neighbor function. See the CakePHP book in this page:
http://book.cakephp.org/2.0/en/models/retrieving-your-data.html#find-neighbors

Enjoy, John


On Tuesday, 29 December 2015 00:54:37 UTC+2, Clement Crownrise wrote:
Thanks for your response, but please what is the neighbour function?

Can you please paste the sytax here.

Thanks


On Monday, December 28, 2015 at 11:35:36 PM UTC+1, Matthew Kaufman wrote:
Use the get neighbors function.

On Mon, Dec 28, 2015 at 5:32 PM, Clement Crownrise <[hidden email]> wrote:
Hello everyone, below is the first page of my list page, The first attachment..

On clicking on any of the data on the first page, it will open up and show like the second attachment.

Now the problem is, I want to add a "Next " and "Previous" button to the second attachment, so that I will not need to go to the first page(first attachment ) in order to access the next or previous record.

HOW CAN I ACHIEVE THIS?

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to a topic in the Google Groups "CakePHP" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/cake-php/HYSgunvislo/unsubscribe.
To unsubscribe from this group and all its topics, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.



--

--
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

---
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.