Jump to content

Why do my pages end with a "/" ?


moonman

Recommended Posts

I've been making a website and say I have a page like www.home.com -- that link is all fine. Now I make another page for say a FAQ. It'll be www.home.com/FAQ/ I can't get it to be www.home.com/FAQ it seems to have to have that / on the end. Why is this and what can I do to change it? My www.home.com is on say a public_html folder using an index.html for the page's contents. Then i made a new folder called FAQ, and inside that folder is another index.html that is the contents of the index page. What am I doing wrong?

Link to comment
Share on other sites

It doesn't seem like you're doing anything wrong. If you created a new directory called "FAQ" with another index page and you're linking to it from the parent directory then nothing is wrong. It's doing what it's suppose to do. Now if you want it to be: www.home.com/FAQ/index.html then you will have to add "/FAQ/index.html" to your links.

Link to comment
Share on other sites

By default when you type "www.home.com" or "www.home.com/FAQ" it will look for any file with index.* and default.* in uppercase and lowercase first and use that, IF found, and then place a forward slash at end to represent the directory it found the file. www.home.com/ represents the root directory, www.home.com/FAQ/ is that it found the index.* or default.* in FAQ directory and used that, if you type the name of file itself you will end up with 'www.home.com/index.html' or 'www.home.com/FAQ/index.html' or 'www.home.com/FAQ/faq.html' You can however use mod_rewite on Apache server (google on how to implement), to force the removal of forward slash, you would use a link such as 'www.home.com/FAQ' and it will know you trully mean 'www.home.com/FAQ/index.html' load the file at correct location, but show the link you used instead.

Link to comment
Share on other sites

Couldn't I possibly edit my .htaccess to remove the bar?I had a similar problem with my links looking like www.home.com/faq.php for example I edit the .htaccess, placed a rewrite and got it to be www.home.com/faq However, this actual page I'm working on is in a folder that's from my main folder (with my index and everything for www.home.com) and this actual page has more folders inside it, which need to be there for the page to fully function. Anyone understand me? I hope I'm not being confusing.

Link to comment
Share on other sites

I know very little about this but I can at least point you in the right direction, I hope it's helpful:http://www.google.com/search?q=flat+links+htaccess

Link to comment
Share on other sites

you can also contact your host provide and fine out whats the problem is "they might be some lazy ones, so if one of them dont give you a decent answer call back and get onto a different person"

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...