![]() |
with "(:num)" I get a 404 error.
404 - File Not Found Controller or its method is not found: \App\Controllers\Admin::index if I use it as ":num" the page loads but "$1" is passed as the variable but not what's in the URL
11-18-2021, 08:11 AM
(This post was last modified: 11-18-2021, 08:18 AM by captain-sensible. Edit Reason: extra )
yes @InsiteFX i pointed that out in #2 then forgot in #6 i guess i have a short term memory problem developing ?
whats the base url set to in app/Config/App.php ? mine on local dev is ;: Code: public $baseURL = 'http://127.0.0.2/'; you see that forward slash on the end . None of my routes have a "/" at beginning A route should be setting up url on left then determining on right what class and method to use , so surely Class::method is all thats needed ?
My local URL
'http://xx.localhost/' 'Admin/Reports/' is the path to the file (controller). 'Brands' is the controller 'stores' is the function. PHP Code: $routes->get('/admin/reports/stores/:num', 'Admin/Reports/Brands::stores/$1'); ![]() ![]() thank you 'iRedds' ![]() ![]() |
Welcome Guest, Not a member yet? Register Sign In |