Zen Cart Logo
Forums / General Questions / www address will not resolve - non www does

www address will not resolve - non www does

Locked

Views: 2,284

Results 1 to 20 of 25
This thread is locked. New replies are disabled.
3 Apr 2013, 12:23 AM
#1
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

www address will not resolve - non www does

site resolves to http://sitename.com but for http://www.sitename.com it returns a 'page cannot be found error'. Configure files are set up with urls (https and http) as NON www however even with a re-direct from www to non www the error still comes up. I changed the configure.php files in both admin/includes and in includes to reflect www in the addresses but www version still comes up with 'page not found error' AND non www version resolves as just text.

what other files aside from configure.php files need to be changed to have the www version work and also for the non www version to show up properly. My other sites resolve either way so this is perplexing.

any help appreciated.

cheers,
Mike

3 Apr 2013, 12:24 AM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

shags38:

site resolves to http://sitename.com but for http://www.sitename.com it returns a 'page cannot be found error'.
Sounds very much like a hosting account misconfiguration.

3 Apr 2013, 12:30 AM
#3
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

DrByte:

Sounds very much like a hosting account misconfiguration.

so the two (2) configure.php files are the only files to alter - no 'template' or other files to alter?

3 Apr 2013, 12:37 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

Out-of-the-box, Zen Cart only uses the two configure.php files when generating URLs which it displays to your site.

If you've added .htaccess rewrite rules, or other plugins that rewrite things or otherwise alter how Apache (or your webserver) works, then those are things entirely under your control. Zen Cart doesn't use any .htaccess files in the root of your site, but if you added one, then that might be causing problems for you. Again, your hosting company can help you with refining those issues.

Further, any subdomain rules you've added in your hosting account, or custom DNS/nameserver entries in your hosting account or NS services, could easily affect "resolving" of a URL. Again, talk to your hosting company for tailored help.

3 Apr 2013, 12:40 AM
#5
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

DrByte:

Out-of-the-box, Zen Cart only uses the two configure.php files when generating URLs which it displays to your site.

If you've added .htaccess rewrite rules, or other plugins that rewrite things or otherwise alter how Apache (or your webserver) works, then those are things entirely under your control. Zen Cart doesn't use any .htaccess files in the root of your site, but if you added one, then that might be causing problems for you. Again, your hosting company can help you with refining those issues.

Thanks Doc - I do have Ultimate SEO loaded so that plug-in may need reconfiguring - many thanks for your help - cheers.

3 Apr 2013, 12:44 AM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

Ya, start by turning that off.

3 Apr 2013, 12:51 AM
#7
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

DrByte:

Ya, start by turning that off.

I would but now cannot get to my admin - I think I will revert configure files to non www then hopefully get into admin and turn off Ultimate SEO then re-do config files - (scary thing though is it creates havoc with Google with changes to url configuration/format - hundreds of 404's as a result)

3 Apr 2013, 1:51 AM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

Start by removing all the ultimate-seo crap from the .htaccess file in your site's root, until you sort out the correct logic to put back in there.

And it's probably worth a read thru that mod's support thread ... this is the thread for the 2-0-0 version of that mod: http://www.zen-cart.com/showthread.php?199064-Ultimate-SEO-2-200-%28new-features%29-Support-Thread

3 Apr 2013, 2:08 AM
#9
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

DrByte:

Start by removing all the ultimate-seo crap from the .htaccess file in your site's root, until you sort out the correct logic to put back in there.

And it's probably worth a read thru that mod's support thread ... this is the thread for the 2-0-0 version of that mod: http://www.zen-cart.com/showthread.php?199064-Ultimate-SEO-2-200-%28new-features%29-Support-Thread

Thanks Doc - 1. I have compared .htaccess with 2 other sites that use the same mod (same version of mod and same version of ZC) and they are exactly the same (sites were built at the same time).
2. I have been on to my host (VentraIP) and at their end all is OK, both addresses resolve as they should - they suggested clearing cache (which I had done anyway) and/or doing a DNS Flush which I have subsequently done but no change - could be the modem itself, getting same results on other computers here that use the same modem.

cheers, Mike

3 Apr 2013, 2:51 AM
#10
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

"comparing" is NOT the same as "removing" offending components.

If you won't remove the bad .htaccess file, at least change rewriteEngine "On" to "Off" to rule it out.

Failing that, start posting useful details such as your actual URL and your .htaccess contents, and a list of all your other addons etc. Otherwise, this is like shooting with a blindfold on.

3 Apr 2013, 5:53 AM
#11
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

Points taken - as a start url is http://www.sterlingsilverrings.com.au and http://sterlingsilverrings.com.au

It would be interesting to see if the site resolves ok from others as well as VentraIP - it gave the same issues at my ISP (but it is not their problem!!). I will do the other things you suggested.

cheers, Mike

3 Apr 2013, 7:08 AM
#12
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: www address will not resolve - non www does

At this moment, the www. prefix resolves fine from here.

3 Apr 2013, 7:11 AM
#13
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

DrByte:

At this moment, the www. prefix resolves fine from here.

Thanks Doc - much appreciated

3 Apr 2013, 11:16 PM
#14
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: www address will not resolve - non www does

WWW prefix resolves fine from your link
BUT clicking home resolves to the non www address
I suppose that this is what you want

4 Apr 2013, 4:52 AM
#15
shags38 avatar

shags38

Totally Zenned

Join Date:
Jan 2011
Location:
Adelaide, Australia
Posts:
1,684
Plugin Contributions:
0

Re: www address will not resolve - non www does

kobra:

WWW prefix resolves fine from your link
BUT clicking home resolves to the non www address
I suppose that this is what you want

Firstly thanks for your input - I think it changes to non www because that is how it is configured in configure.php files which I will now change to www.

To all who have read or participated in this thread - problem turned out to be an ISP issue believe it or not - very strange and they won't give an explanation beyond it is now fixed. So it had nothing to do with Ultimate SEO urls or ZenCart configurations - one for the 'make a note for future reference', check with ISP and Host before messing with your configurations.

Thanks to those who assisted me.

cheers,
Mike

8 Apr 2013, 3:16 PM
#16
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,284
Plugin Contributions:
39

Re: www address will not resolve - non www does

What happens with ISPs is that in their endeavor to produce fast browsing (which is what most customer's equate with speed) they cache DNS and such downsteam. Often, ATT for example has no means for you, the customer, to renew/release this cache that they tend to cache for an idiotic length of time.....

9 Apr 2013, 7:28 AM
#17
rodg avatar

rodg

Deceased

Join Date:
Jan 2007
Location:
Australia
Posts:
6,263
Plugin Contributions:
4

Re: www address will not resolve - non www does

mprough:

What happens with ISPs is that in their endeavor to produce fast browsing (which is what most customer's equate with speed) they cache DNS and such downsteam. Often, ATT for example has no means for you, the customer, to renew/release this cache that they tend to cache for an idiotic length of time.....

In the interests of accuracy:

Yes, DNS data does get cached, but the duration has nothing to do with the ISPs, they have no control over this whatsoever. The period of time that an entry is 'cached' is determined by its TTL value that is set/defined on the domain registrars system.

Skilled developers make use of this fact when upgrading/migrating a site to a different server. By careful manipulation of the TTL values it is possible to migrate a site with zero downtime (as apposed to the "It can take up to 24 hours for the DNS changes to propagate" that we hear about far too often).

Cheers
Rod

ps. www address will not resolve - non www does = one thing only. The DNS doesn't/didn't have a 'www' record. Plain n simple.

9 Apr 2013, 11:55 AM
#18
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,284
Plugin Contributions:
39

Re: www address will not resolve - non www does

DNS "and such" ..... ATT is terrible about this. I once had to speak with a net tech to see a favicon after 3 weeks. They flushed, I rebooted and bingo there it was. Most troubling is how they cache requests... which is why he cannot get it resolving for him

9 Apr 2013, 2:23 PM
#19
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: www address will not resolve - non www does

DNS=mprough
It is not the DNS bneing cached that is the issue but the caching of content
When they "flush" they actually refresh the "A" records and refresh the content

9 Apr 2013, 2:30 PM
#20
mprough avatar

mprough

Totally Zenned

Join Date:
Nov 2007
Location:
Woodbine, Georgia, United States
Posts:
4,284
Plugin Contributions:
39

Re: www address will not resolve - non www does

I was simply pointing out that I originally said ISPs cache DNS and stuff................................................. was not specifically referring to DNS, but rather that they overstep their boundaries with caching things in order to produce seemingly faster speeds :huh: