![]() |
I have the following route configured in app/Config/Routes.php
Code: $routes->resource( Then I have the Project controller in app/Controllers/Api/Project.php Code: <?php When I run http://myapp/api/project I get all the records in json, all works fine But when running this url http://myapp/api/project/show/26 I get as output show and not 26 value. What could be happening ? How should I modify the route in case show method has more parameters? Thanks a lot Well I must have looked like an a*****e For anyone having similar "issue" the correct url for show method in resourceController is http://myapp/api/project/26 Because looking several times the way routes are generated, the show route is generated without the show word https://codeigniter.com/user_guide/incom...l.html#id4 |
Welcome Guest, Not a member yet? Register Sign In |