
-----------------------------------
Drahcir
Wed Aug 13, 2008 5:26 pm

./foo.php
-----------------------------------
So, I've been seeing links that go ./foo.php, and I'm wondering what the "./" part means.
I thought it was something like "../", which goes up a directory, but ./ doesn't do that. 
If it doesn't go up a directory, then why is it there? Why don't they just leave it as foo.php?
It's driving me nuts that I can't find the solution to this by searching it, since search engines don't really accept weird characters as search terms.
Someone please enlighten me!

-----------------------------------
Dan
Wed Aug 13, 2008 5:28 pm

RE:./foo.php
-----------------------------------
./ noramly means the current directory you are in. 

As for why it would be used rather then just foo.php in xhtml i am not sure.

-----------------------------------
Drahcir
Wed Aug 13, 2008 6:05 pm

RE:./foo.php
-----------------------------------
Oh, so it's just a standard in xhtml? So if I wanted an xhtml valid page, all my links that go to the same directory need to have ./?

-----------------------------------
Tony
Wed Aug 13, 2008 6:17 pm

Re: RE:./foo.php
-----------------------------------
Oh, so it's just a standard in xhtml?
More like Unix.

So the server figures out what was meant.

No, you don't need to have this in your links to validate. Use the validation tools to check what you're missing -- http://validator.w3.org/

-----------------------------------
Dan
Wed Aug 13, 2008 7:35 pm

Re: RE:./foo.php
-----------------------------------
Oh, so it's just a standard in xhtml? So if I wanted an xhtml valid page, all my links that go to the same directory need to have ./?

Sorry i did not mean to say that it should be used like that in xhtml as a standard, i ment i do not know why it whould be used like that in xhtml.

It makes sence in a command line enveroment but not so much in a static xhtml page (at least to me, if there is a reason to add in the ./ i would love to know).

My guess is it is there as the browser just parases the path in an xhtml document like it would a noraml path on a *nix enviroment.
