Tapestry 5
  1. Tapestry 5
  2. TAP5-648

Tapestry should be more careful about where, inside the <head>, it adds new elements

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 5.2.0, 5.2.1, 5.2.2, 5.2.3, 5.2.4, 5.1.0.0, 5.1.0.1, 5.1.0.2, 5.1.0.3, 5.1.0.4, 5.1.0.5
    • Fix Version/s: 5.1.0.4
    • Component/s: tapestry-core
    • Labels:
      None

      Description

      As Microsoft documentation states (http://msdn.microsoft.com/en-us/library/cc817574.aspx) the META tags that direct IE8 must be positioned as follows: "The X-UA-compatible header is not case sensitive; however, it must appear in the Web page's header (the HEAD section) before all other elements, except for the TITLE element and other META elements.".

      The most flexible solution would be to honor the order of META and other tags that author has put directly to the template: the place for T5 tags could be indicated with special tag:

      For an example
      <html>
      <head>
      <title>My Web Page</title>
      <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
      <t:headcontent />
      <link href="dirlang.html" rel="next"/>
      </head>
      .
      .

      If author decides to omit the t:headcontent tag then T5 would not attach any meta or link tags.

      Other solution as Howard indicated in the mailing list would be to just add the T5 specific stuff to the end of the head section.

        Issue Links

          Activity

          Ville Virtanen created issue -
          Hide
          Howard M. Lewis Ship added a comment -

          We can be more careful about where the elements go.

          <script> elements should go before the first <script> element already in the <head>,

          Likewise for <link> tags (for CSS).

          <meta> tags can go last, so as not to interfere with the <meta> tags you are talking about.

          Show
          Howard M. Lewis Ship added a comment - We can be more careful about where the elements go. <script> elements should go before the first <script> element already in the <head>, Likewise for <link> tags (for CSS). <meta> tags can go last, so as not to interfere with the <meta> tags you are talking about.
          Howard M. Lewis Ship made changes -
          Field Original Value New Value
          Assignee Howard M. Lewis Ship [ hlship ]
          Howard M. Lewis Ship made changes -
          Status Open [ 1 ] In Progress [ 3 ]
          Howard M. Lewis Ship made changes -
          Summary Tapestry ignores the order in which user gives the META tags Tapestry should be more careful about where, inside the <head> is adds new elements
          Howard M. Lewis Ship made changes -
          Summary Tapestry should be more careful about where, inside the <head> is adds new elements Tapestry should be more careful about where, inside the <head>, it adds new elements
          Howard M. Lewis Ship made changes -
          Status In Progress [ 3 ] Closed [ 6 ]
          Fix Version/s 5.1.0.4 [ 12313854 ]
          Resolution Fixed [ 1 ]
          Hide
          Ville Virtanen added a comment - - edited

          As of 5.2.4 this is still broken, unfortunately. As MS states, the META tags that direct the rendering of IE must occur before css imports and such. Tapestry includes meta tags after the inclusion of javascript and css, which in this case is plain wrong. Just to make my point, this is again the spec: ".......it must appear in the Web page's header (the HEAD section) before all other elements, except for the TITLE element and other META elements."

          Show
          Ville Virtanen added a comment - - edited As of 5.2.4 this is still broken, unfortunately. As MS states, the META tags that direct the rendering of IE must occur before css imports and such. Tapestry includes meta tags after the inclusion of javascript and css, which in this case is plain wrong. Just to make my point, this is again the spec: ".......it must appear in the Web page's header (the HEAD section) before all other elements, except for the TITLE element and other META elements."
          Ville Virtanen made changes -
          Resolution Fixed [ 1 ]
          Status Closed [ 6 ] Reopened [ 4 ]
          Ville Virtanen made changes -
          Affects Version/s 5.1.0.5 [ 12313913 ]
          Affects Version/s 5.1.0.4 [ 12313854 ]
          Affects Version/s 5.1.0.2 [ 12313706 ]
          Affects Version/s 5.1.0.1 [ 12313660 ]
          Affects Version/s 5.1.0.0 [ 12313428 ]
          Affects Version/s 5.2.4 [ 12315557 ]
          Affects Version/s 5.2.3 [ 12315474 ]
          Affects Version/s 5.2.2 [ 12315376 ]
          Affects Version/s 5.2.1 [ 12315230 ]
          Affects Version/s 5.2.0 [ 12314122 ]
          Fix Version/s 5.1.0.4 [ 12313854 ]
          Howard M. Lewis Ship made changes -
          Link This issue is cloned as TAP5-1366 [ TAP5-1366 ]
          Howard M. Lewis Ship made changes -
          Status Reopened [ 4 ] Closed [ 6 ]
          Fix Version/s 5.1.0.4 [ 12313854 ]
          Resolution Fixed [ 1 ]
          Transition Time In Source Status Execution Times Last Executer Last Execution Date
          Open Open In Progress In Progress
          1d 12h 34m 1 Howard M. Lewis Ship 17/Apr/09 21:39
          In Progress In Progress Closed Closed
          46m 55s 1 Howard M. Lewis Ship 17/Apr/09 22:26
          Closed Closed Reopened Reopened
          596d 23h 14m 1 Ville Virtanen 05/Dec/10 20:41
          Reopened Reopened Closed Closed
          21h 33m 1 Howard M. Lewis Ship 06/Dec/10 18:14

            People

            • Assignee:
              Howard M. Lewis Ship
              Reporter:
              Ville Virtanen
            • Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development