After save in grid edit load to the next page

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
sapaypape80
User
Posts: 34

After save in grid edit load to the next page

Post by sapaypape80 »

Hello!
I have a table with to much records and pages. Actually when we edit in "grid edit" and save it loads the first page of pagination. Could we configure to load the same page or the next page?


arbei
User
Posts: 9285

Post by arbei »

You can set the page number in the URL of the Return Page.


sapaypape80
User
Posts: 34

Post by sapaypape80 »

Yes i saw that, but could you tell me how has to be the code to put there? For example to open the next page in grid edit?
Thanks in advance XD


arbei
User
Posts: 9285

Post by arbei »

You need to calculate the next page number (e.g. current page + 1) and use it in the return page URL. The current page number can be obtained from the URL when you enter the Grid-Edit mode.


sapaypape80
User
Posts: 34

Post by sapaypape80 »

Hi, I am trying to calculate the page number, but I don't know which parameter to use. I only see the "start" parameter at URL and I have tried the following:

"entradapujalist.php?action=gridedit&showmaster=subastas&fk_codsubasta=".urlencode($this->codsubasta->CurrentValue)."start=".((isset($GET['start']) ? $GET['start'] + 10 : 11))

Please, ¿can you provide me an example?


arbei
User
Posts: 9285

Post by arbei »

Be reminded that URL paramters should be separated by "&", there is none before "start" in your URL. You may learn also $_GET.


sapaypape80
User
Posts: 34

Post by sapaypape80 »

Thanks that was solved


SOHIB
User
Posts: 93

Post by SOHIB »

sapaypape80 wrote:

Thanks that was solved

please write the solutions , i need to use it also


Post Reply