eapro
05-11-2009, 06:17 PM
Look at these two URLs (example):
1: http://codingforums.com/newthread.php/new
2: http://codingforums.com/newthread/new
Both #1 and #2 contain this code.
<?php
echo $_SERVER['REQUEST_URI'];
?>
Of course since #2 is a dir, the code is inside a index.php file.
The problem is #1 works and #2, my preferred method, doesn't work.
I've been googling around for a while and found two solutions to this: mod rewrite and multiview, but these require sever config.
I would like to know if there is a way to accomplish this without configuration, just PHP.
1: http://codingforums.com/newthread.php/new
2: http://codingforums.com/newthread/new
Both #1 and #2 contain this code.
<?php
echo $_SERVER['REQUEST_URI'];
?>
Of course since #2 is a dir, the code is inside a index.php file.
The problem is #1 works and #2, my preferred method, doesn't work.
I've been googling around for a while and found two solutions to this: mod rewrite and multiview, but these require sever config.
I would like to know if there is a way to accomplish this without configuration, just PHP.