Help with RESTful Resource Routes |
Hi,
Reading REST Resource Naming Guide item 2.4. Never use CRUD function names in URIs, I noticed that the example on the CI4 documentation doesn't follow that. Did I understand correctly? Am I missing something? Thanks.
$routes->resource('photos'); from documentation does that, what your link to REST Guide says it should do (use HTTP request methods)
But with codeigniter you can also easy do eg. deletion with uri segements, like $routes->post('photos/(egment)/delete' - it depends on the application, personally I don't think its completly wrong this way.
You're correct.
Strictly speaking, PHP Code: photos/(:segment)/edit You can remove the edit: https://codeigniter.com/user_guide/incom...l.html#id3 (03-17-2022, 01:04 AM)kenjis Wrote: You're correct. Ok. Thank you. |
Welcome Guest, Not a member yet? Register Sign In |