I'm working on one php project without using framework and I want to form nice urls without tons of get parameters and ? and & characters. I know this could be solved in zend using controllers and actions and I'm looking for somerhing simillar.
On my site, I have faculties, now when somebody open one faculty to see information, it should be mysite.com/faculty.php?id=6 for example, and then faculty with id=6 is shown.
I'd like this url to be mysite.com/faculties/faculty_name (for example). Also, when user opens list of faculties, url should be mysite.com/faculties indstead of mysite.com/faculties.php. Is only way I can do this by putting special folder faculties and index.php to show all faculties. And maybe when someone opens one faculty, it should be
mysite.com/faculties?ref=6 for faculty with id 6. This is much better than faculty.php?id=6.
How can I do this best, with less code and less folders?
Thanks in advance,