You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Unico Hommes (Created) (JIRA)" <ji...@apache.org> on 2011/11/22 12:08:40 UTC

[jira] [Created] (WICKET-4254) IE allows only 31 stylesheet objects on a page

IE allows only 31 stylesheet objects on a page
----------------------------------------------

                 Key: WICKET-4254
                 URL: https://issues.apache.org/jira/browse/WICKET-4254
             Project: Wicket
          Issue Type: Improvement
    Affects Versions: 1.5.3, 1.4.19
            Reporter: Unico Hommes


We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.

Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.

We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.

I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.

On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Unico Hommes (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13155051#comment-13155051 ] 

Unico Hommes commented on WICKET-4254:
--------------------------------------

patch verified to work with IE 7, 8 and 9, for other browsers there is no impact.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Unico Hommes (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Unico Hommes updated WICKET-4254:
---------------------------------

    Description: 
We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.

Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.

We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.

I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.

On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.

[1] http://support.microsoft.com/kb/262161


  was:
We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.

Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.

We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.

I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.

On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.


    
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Emond Papegaaij (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13176769#comment-13176769 ] 

Emond Papegaaij commented on WICKET-4254:
-----------------------------------------

Isn't it possible to reduce the number of stylesheets by creating bundles? Wicket 6 supports bundles out of the box. To me, it seems a far better solution than converting the stylesheets to a stylesheet with many imports, as it also reduces the number of requests the server needs to handle and it works with AJAX.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Emond Papegaaij (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Emond Papegaaij resolved WICKET-4254.
-------------------------------------

       Resolution: Won't Fix
    Fix Version/s: 6.0.0
         Assignee: Emond Papegaaij

In Wicket 6, it is possible to configure bundled resources, which allows you to automatically concatenate your stylesheets into one. This allows you to stay under the 31 stylesheet limit.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>            Assignee: Emond Papegaaij
>              Labels: patch
>             Fix For: 6.0.0
>
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Martin Grigorov (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13162212#comment-13162212 ] 

Martin Grigorov commented on WICKET-4254:
-----------------------------------------

What is this <script> tag with @import ?
Can you give an example ? 
Maybe you mean <style> ?
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Unico Hommes (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Unico Hommes updated WICKET-4254:
---------------------------------

    Attachment: WICKET-4254.patch

The patch. Verified with IE8 & IE9. Will report wether also works with IE7.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Bertrand Guay-Paquet (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13161728#comment-13161728 ] 

Bertrand Guay-Paquet commented on WICKET-4254:
----------------------------------------------

Have you taken a look at AbstractResourceAggregatingHeaderResponse? It allows aggregating resources so perhaps it could solve your problem. Have a look at its javadoc and the GroupingHeaderResponse in wicket-examples.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (WICKET-4254) IE allows only 31 stylesheet objects on a page

Posted by "Unico Hommes (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-4254?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13162211#comment-13162211 ] 

Unico Hommes commented on WICKET-4254:
--------------------------------------

Yeah, I did look at that. And apart from the ajax trick in the patch I also implemented a HeaderResponse that aggregates the css references and writes them out into <script> tags as @import statements. And we use that HeaderResponse on requests that are not ajax requests. (I did not use AbstractResourceAggregatingHeaderResponse as there were still some issues with it that were not backported to 1.4.x branch which we are on.) Together these two approaches seem to work out very nice for us as we have now upped the limit on the number of stylesheets we can use on a document from 31 to 31*31. Which is more than enough.

Yes, I think providing an extension to AbstractResourceAggregatingHeaderResponse that writes out <scrip> tags with @import statements instead of separate <link> tags is definitely something that Wicket could provide out of the box for people running into this problem.
                
> IE allows only 31 stylesheet objects on a page
> ----------------------------------------------
>
>                 Key: WICKET-4254
>                 URL: https://issues.apache.org/jira/browse/WICKET-4254
>             Project: Wicket
>          Issue Type: Improvement
>    Affects Versions: 1.4.19, 1.5.3
>            Reporter: Unico Hommes
>              Labels: patch
>         Attachments: WICKET-4254.patch
>
>
> We ran into a limitation of IE where it only allows 31 stylesheet objects on a page [1]. This includes objects declared using a <link ..> tag as well as objects declared using <style ..> tags.
> Because we have a pluggable architecture for our CMS, and each plugin is loaded into the page when it is first used, whereby js and css resources are loaded using ajax, we run into this issue quite quickly when the user clicks around for a while.
> We have found a work around by adding the stysheets as @import statements to a dedicated <style> element, instead of adding them to the head as a link.
> I've created a patch for wicket that implements this approach. However, I am not sure if the patch is entirely to the community's satisfaction because the way one can programmatically add imports to a stylesheet doesn't allow setting the type attribute (ref attributes are not possible at all in css @import statements). Which consequently gets lost with this approach.
> On the other hand, I imagine others will sooner or later run into this limitation and want this workaround to be available to them.
> [1] http://support.microsoft.com/kb/262161

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira