Product Pages Breaking in IE 7

Questions and answers about ShopSite Custom Templates

Product Pages Breaking in IE 7

Postby aaemnnosttv » Tue Nov 08, 2011 10:44 am

Greetings all, first post.

I have a shop site store that I am developing that I just found out is having some major rendering problems (everything but the footer is not showing up) in IE 7.

I don't have any problem viewing it in any modern browser (hooray!) but my client's online merchant is reviewing the site in IE 7 (...)

Here's a link to the store: http://minnick.accountsupport.com/store/index.html

I've looked at the site in the W3 Validator and it's mostly coming back with errors from unencoded ampersands in URLs which are coming from the
Code: Select all
[-- PRODUCT.AddToCartURL --]
tags.
(Anyone know why these aren't encoded or am I just doing something wrong?)

Could this really break the site or is it something else?

Please help!
aaemnnosttv
 
Posts: 4
Joined: Tue Nov 08, 2011 10:28 am

Re: Product Pages Breaking in IE 7

Postby Jim » Tue Nov 08, 2011 11:24 am

The code [-- PRODUCT.AddToCartURL --] is a ShopSite template tag. If it is showing up on an html page then it was not evaluated by the ShopSite code that processes the templates. Most likely this is coming from a separate file and not the main template. It would be called in the template as [-- INCLUDE <somefilename> --] when it should be using [-- INCLUDE <somefilename> PROCESS --] .

So look through the template at the place where the Add to cart button is suppose to display and see if you can find an [-- INCLUDE ... --] tag that does not have the word PROCESS inside of the tag brackets.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Re: Product Pages Breaking in IE 7

Postby aaemnnosttv » Tue Nov 08, 2011 12:24 pm

Thanks for the reply.

I didn't mean that the [-- PRODUCT.AddToCartURL --] tag itself was showing up in the HTML page without being processed.

What I said is that there are unencoded ampersands (rendering "&" instead of "&amp;") that are in the URL that is generated by that tag that I thought could be creating the problem.
aaemnnosttv
 
Posts: 4
Joined: Tue Nov 08, 2011 10:28 am

Re: Product Pages Breaking in IE 7

Postby Jim » Tue Nov 08, 2011 4:25 pm

Although the specs now say that urls should have &amp; instead of just &, there is not a browser around that does not process the plain & character. Go to almost any major site (google.com, bing.com, Amazon.com, etc) and you will see that they almost always use just & as parameters for urls. The "picky" html validation services will complain about them because they don't meet the html specification. However, their use is so wide and long standing that any browser that stopped accepting them would find itself being abandoned by users. Billions of existing pages that rely on & will probably never be updated to use &amp; and breaking all those pages would cause big problems on the web.
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Re: Product Pages Breaking in IE 7

Postby aaemnnosttv » Tue Nov 08, 2011 5:33 pm

Ok, so that probably isn't the problem then.

Any idea why my site is breaking?
aaemnnosttv
 
Posts: 4
Joined: Tue Nov 08, 2011 10:28 am

Re: Product Pages Breaking in IE 7

Postby Jim » Tue Nov 08, 2011 10:02 pm

My best guess is that you are looking at it in IE. Lots of problems with trying to get a website to comply with Microsofts "standards" that don't match the actual standards.

What type of errors are reported when you run the pages through the html validation, other than the & issue?
Jim
Site Admin
 
Posts: 4953
Joined: Fri Aug 04, 2006 1:42 pm
Location: Utah

Re: Product Pages Breaking in IE 7

Postby aaemnnosttv » Wed Nov 09, 2011 8:17 am

Fixed the problem.

It had to do with the javascript shopsite adds on the page for the minicart. I'm really not sure what about the script was causing an error - I was getting a syntax error at the closing </script> tag - but I was able to fix it by copying this code and moving it to an external .js file and linking to it that way instead of having it all in the <head>.

This is rather odd, as it was included in the page template just as shopsite recommends in the custom template tutorials.
aaemnnosttv
 
Posts: 4
Joined: Tue Nov 08, 2011 10:28 am


Return to Custom Template Questions

Who is online

Users browsing this forum: No registered users and 16 guests