Welcome to WebmasterWorld Guest from 54.161.201.189

Forum Moderators: brotherhood of lan & mack

File locations don't match physical location

File locations don't match reality

   
11:40 pm on Dec 16, 2008 (gmt 0)

5+ Year Member



Hi,

Sorry if this is real lame.

I have a site with the following structure (kinda)

www.MyDomain.com
www.MyDomain.com/index.php
www.MyDomain.com/contact.php
www.MyDomain.com/sitemap.php
www.MyDomain.com/products
www.MyDomain.com/products/index.php
www.MyDomain.com/products/product1.php
www.MyDomain.com/products/product2.php
www.MyDomain.com/products/product3.php

When I run coffeecup or any other sitemap generator they ALL report errors and report the following structure:

www.MyDomain.com/index.php
www.MyDomain.com/contact.php
www.MyDomain.com/sitemap.php
www.MyDomain.com/products
www.MyDomain.com/products/index.php
www.MyDomain.com/products/product1.php
www.MyDomain.com/products/product2.php
www.MyDomain.com/products/product3.php
www.MyDomain.com/product1.php
www.MyDomain.com/product2.php
www.MyDomain.com/product3.php

Notice the last three files.

Should I ignore it? If not, how the heck do I fix that!

I'm worried Google will put me in the sin bin for being a poor quality site.

Anyone?

11:57 pm on Dec 16, 2008 (gmt 0)

5+ Year Member



Just in case you're wondering, my links in the page do not refer to the whole url.

This is what I have on the products/index.php page

<a href="product1.php">product1</a>
<a href="product2.php">product2</a>
<a href="product3.php">product3</a>

Should I be using
<a href="http://www.MyDomain.com/products/product3.php">product3</a>
Everywhere?

12:18 am on Dec 17, 2008 (gmt 0)

WebmasterWorld Senior Member jdmorgan is a WebmasterWorld Top Contributor of All Time 10+ Year Member



Don't confuse URLs with filepaths, as the two are not the same thing. In fact, the primary job of a server is to translate a URL request into a file request that is compatible with the operating system of the machine on which the server runs.

It is possible that there is some code in the server configuration that is mapping the file product1.php onto multiple URLs, and that is why your sitemap generator finds multiple URLs.

The real question is, if you click on one of those "product" links, does it work?

If you have a link on a page, and it refers to another page at the same URL "directory" level, then using href="otherpage.php" is fine. If the other page is in the "directory" above the one that is linking, then you'd use href="../otherpage.php", and if below, then href="/child-directory/otherpage.php".

You can also use server-root-relative links by specifying a leading slash to point to the Web root "directory" and then work down from there: href="/parent/child/child/otherpage.php". Finally, you can also use the canonical URL as you stated in your post.

This is all general info; It will take a much more-detailed description of your server type, server configuration, "shopping cart" and server software, and development environment in order to diagnose this problem.

Jim

12:26 am on Dec 17, 2008 (gmt 0)

5+ Year Member



Thanks Jim.

I just did a test and errors go away when I use the full path, so I'll use it until I get the scoop on the server config
(httpd.ini maybe?)

 

Featured Threads

My Threads

Hot Threads This Week

Hot Threads This Month