I have had a read over the routing page on the codeigniter site and im still a bit unsure about how to go about this.
For example, in my application to view private messages, the url is http://www.example.com/messages/view/1 … 1 being the message id.
I would really like to change this just to be http://www.example.com/messages/view as i feel having the message id in the url will allow users to manipulate the url to view any private message one the site.
Any help would be much appreciated.
Cheers
If you don’t want the ID in the URL then the only way would be to POST it via a form.
This is pretty pointless however as the ID will be visible one way or another.
Instead you should focus on validation on the page that loads the message from the ID. Check on that page that the message ID exists and that the user has access to that message, if not then show an error.
This is a better approach.