I have three different types of URL schemes in my website:
http://example.com/page.php
http://example.com/anotherpage.php/23
where23
is the id and is being captured as GET data.http://example.com/yetanotherpage.php/23/somedata
where23
andsomedata
is being captured as GET data.
What I need as a .htaccess rule is whatever comes after example.com/
should be considered as PHP page, such that:
http://example.com/page.php
be converted tohttp://example.com/page
http://example.com/anotherpage.php/23
be converted tohttp://example.com/anotherpage/23
http://example.com/yetanotherpage.php/23/somedata
be converted tohttp://example.com/yetanotherpage/23/somedata
I was able to write rules for #1 but didn't find anything for #2 and #3.