You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Background:
I have an old PHP application from a "pro-bono" client, without framework, where I am modifying the VIEW layer to use Plates and thus facilitate future maintenance. (Before I just did an include of the view file inside the Controller).
During the "conversion" I came across the following situation...
I have two SELECTs connected, as for example STATE -> CITY. When I select the State, the Cities of this State are inserted via $.ajax of the JQuery routine in the code.
Before plates, the url parameter of $.ajax pointed to a php file in the folder itself (directly)... example:
But now with plates, my view of this form is inside a folder themes/admin/...
I guess I can no longer point this url the same way (putting the file __ajaxGetCitiesByState.php inside this same folder themes/admin/).
What would be the correct way to access this file where I search the cities according to the State ID and return the OPTION list to insert in the SELECT of the cities?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello everybody !
I need some relatively simple help...
Background:
I have an old PHP application from a "pro-bono" client, without framework, where I am modifying the VIEW layer to use Plates and thus facilitate future maintenance. (Before I just did an include of the view file inside the Controller).
During the "conversion" I came across the following situation...
I have two SELECTs connected, as for example STATE -> CITY. When I select the State, the Cities of this State are inserted via $.ajax of the JQuery routine in the code.
Before plates, the url parameter of $.ajax pointed to a php file in the folder itself (directly)... example:
...
But now with plates, my view of this form is inside a folder themes/admin/...
I guess I can no longer point this url the same way (putting the file __ajaxGetCitiesByState.php inside this same folder themes/admin/).
What would be the correct way to access this file where I search the cities according to the State ID and return the OPTION list to insert in the SELECT of the cities?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions