Mobile app version of vmapp.org
Login or Join
Shelley277

: Why is having (or excluding) 'www' in the URL affecting how my site displays to users? I am cleaning markup on a website for my first customer. I did not build the site; I want to remove

@Shelley277

Posted in: #Html #Http

I am cleaning markup on a website for my first customer. I did not build the site; I want to remove the table-based design and replace it with proper CSS, before I add a shopping cart to the site. www.theresheglowsdayspa.com
I noticed by accident that the appearance will change if 'www' is removed from the URL.

Can someone explain what's going on here? Also, is there a best practice with 'www' or no 'www' in the URL?

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Shelley277

2 Comments

Sorted by latest first Latest Oldest Best

 

@Angie530

take a look at the links in the side menu.


they strip out the www and show a full domain link.
you could linke them as:


this would shorten the url, and would work in both and non www requets.

here is how i usually do it:
i like all my assets from
it may be a bit longer, but keeps things cleaner in the long run.

Then i use a URL Rewrite script to redirect all non www to This is for SEO purposes because google sees yoursite.com and yoursite.com as two seperate sites.

If you are using IIS its simple to do with URLRewrite, apache has something called mod rewrite.

10% popularity Vote Up Vote Down


 

@Margaret670

Using www or not is debatable for aesthetic reasons - however cookies and other same domain policy stuff attached to a example.com will affect something.example.com, however example.com will affect itself only.

There could also be stuff like server side code that assumes the presence of www in the URL.

There could also be rules for a server such as Apache that handles things differently.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme