Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I'm currently working on optimizing a clients website for all big browsers (IE, FF, Safari, Chrome, Opera) and I've encountered unsolveable issues (for me at least) here regarding the CQWP & ListViews which uses XSLT to render content.

In IE everything looks perfect, not a single flaw. But as soon as I open the pages containing CQWP's in any other browser everything in these webparts looks like a bomb exploted in them.

E.g.

<a href="whatever" class="someClass">
    <div class="someOtherClass">
        <div class="iLikeTurtles1"> Content 1 </div>
        <div class="iLikeTurtles2"> Content 2 </div>
        <div class="iLikeTurtles3"> Content 3 </div>
    </div>
</a>

When rendered in FF the HTML to this looks like this:

<a href="whatever" class="someClass">
    <div class="someOtherClass">
    <a href="whatever" class="someClass">
        <div class="iLikeTurtles1"> Content 1 </div>
    </a>
    <a href="whatever" class="someClass">
        <div class="iLikeTurtles2"> Content 2 </div>
    </a>
    <a href="whatever" class="someClass">
        <div class="iLikeTurtles3"> Content 3 </div>
    </a>
    </div>
</a>

I know that SharePoint overall is optimized for IE, but how come such simple HTML can be rendered so bad by other browsers? Does FF and the other browsers read XSLT differently than IE?

share|improve this question
add comment

3 Answers

up vote 1 down vote accepted

Dandroid,

Are you sure you're not looking at some kind of caching problem? I've worked with the CQWP and XSLT many times and I use FF and IE. I have never seen this kind of behaviour.

As far as I know, SharePoint doesn't render different HTML for different browsers. If so, I'd like to know :) Anyway, the HTML you generate through XSLT should be the same in each browser.

Perhaps you need to look at the status of your XSLT file. Is it published?

share|improve this answer
add comment

In CQWP the XSLT is processed at server side and html is passed on to browsers.
So the problems you are facing should be because of improperly formed html.

share|improve this answer
add comment

I'd also double and triple check you have no unclosed tags in your XSLT, as browsers treat those differently in their DOMs.

share|improve this answer
    
I've quadruple checked and there is nothing wrong with html. All endings match,no misspells, css works out -- It's only in FF now that it doesn't work properly. –  Daniel Ziga Dec 15 '11 at 13:34
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.