I am trying to skip the List view of a table and go right to the Edit view of the table. Page_Redirecting seems to be firing in a loop until it throws a browser error.[Fri Aug 23 12:19:23 2019] ::1:49970 [302]: /classesedit.php?employee_id=920
[Fri Aug 23 12:19:23 2019] ::1:49971 [302]: /classeslist.php
[Fri Aug 23 12:19:23 2019] ::1:49972 [302]: /classesview.php?employee_id=970
[Fri Aug 23 12:19:24 2019] PHP Notice: session_start(): ps_files_cleanup_dir: opendir(C:\Windows\Temp) failed: No error (0) in C:\Users\ryans\Documents\PHPMaker\WebSites\ArborCircleTrainings\classeslist.php on line 6
…
from the php.exe cmd window, it looks like the page redirect is running until it gets the browser error that it has redirected too many times
Make sure the user has permission to the edit page.
Thank you!
in the classes table List Page scripts “Page_Redirecting” I have
"function Page_Redirecting(&$url) {
$url = “classesedit.php?employee_id=id”;
}"How do I get the “id” parameter to the Page_Redirecting event?
If there is only one record in the List page (you need to make sure about that first), then the ID should be $this->employee_id->CurrentValue.
The list page would have around 400 rows, but I want to show those rows as View or Edit pages with paging and search
If there are more than one record in the list page, how did you determine which record to redirect to?To achieve paging in View/Edit page, just enable PHP → Page Options (Global) → Paging section in View/Edit page
ryansyt wrote:
How do I get the “id” parameter to the Page_Redirecting event?You may simply use a session variable in order to store the value from your desired server event, and then use that session variable in that Page_Redirecting server event.