[SOLVED] Limit the number of records users can add |
3/26/2021 1:09:08 PM |
PHPRunner General questions | |
![]() I have a few detail table that I need where they can only add one record too. I have followed https://xlinesoft.com/phprunner/docs/limit_the_number_of_records_users_can_add.htm Details Table Name: trip_load The id in account table is the users id and the account_id in the trip_load is also the users id. So the $_SESSION["UserID"] works. Here is the code I placed in my trip_load Table under Add page, Before record Added. $limit = 1; As per the manual. I have the field limit in my account Table because I tried that way too: But with the same database error. Any advice on where I may have gone wrong would be great.. Thanks |
|
![]() |
Sergey Kornilov admin 3/26/2021 |
Could you show us the exact error message? |
![]() |
Tandy author 3/26/2021 |
Ok I sort of figured it out. It shows as a server error but when you read the details of the error it shows me the line: "Limit reached: 1 records added already". Why is it a server error and not a pop-up or something? Here is my code: //Limit to only one record |