http://www.sitepoint.com/article/485
Try going to http://www.sitepoint.com/article//485
Your technique is wrong - you need to do this:
$var_array = explode("/",$PATH_INFO);
Instead of that - use:
$pi=preg_replace('@/{2,}@','/',$PATH_INFO);
$var_array = explode("/",$pi);
That will replace any two or more slashes(//-/*n) with a single /.
Thats a good fix - and wont hog the CPU.
Thanks,
Dan
Their method is correct. Doing a preg_replace on every uri is unnecessaire since the articles are linked correctly. If a user changes the uris, don't expect them to work correctly.
Bookmarks