PDA

View Full Version : Odd Queries


BWiz
09-22-2007, 09:20 PM
I recently came across some queries embedding in an address bar which I cannot identify. The page's url was "/index.php/Home". I haven't actually noticed these type of URLs before. So, I tried to use them in my PHP pages, however if I do, all my linked elements (stylesheets, images et cetera) no longer appear. I don't know anything about these types of urls, and any help would be much appreciated.

NancyJ
09-23-2007, 10:07 AM
The easiest way around this problem is to use absolute rather than relative links.
eg. '/styles.css' rather than 'style.css'

That way if you have a url thats /articles/foo/bar but its really serving index.php?cat=articles&sub=foo&id=bar - you will still render your stylesheets.

abduraooft
09-23-2007, 11:08 AM
I recently came across some queries embedding in an address bar which I cannot identify. The page's url was "/index.php/Home". I haven't actually noticed these type of URLs before. So, I tried to use them in my PHP pages, however if I do, all my linked elements (stylesheets, images et cetera) no longer appear. I don't know anything about these types of urls, and any help would be much appreciated.
I think, you are looking for something like mod_rewrite (http://www.alistapart.com/articles/succeed)