Bug when use Template file in EditCompleteDocument mode

  •  09-29-2008, 3:38 AM

    Bug when use Template file in EditCompleteDocument mode

    When you insert a complete static html template file in the editor (with EditCompleteDocument=true), it insert the code from the <HEAD> section into the <BODY> section.
    Steps to reproduce:
    2. Clear all existing content by clikc New document button
    3. Click the Insert Templates button
    4. Upload a very simple static html template file and then insert the file, example html souce code:
    <html>
       <
    head>
          <title>This is a title</title>
          <style type="text/css">
             body
             {
                font-size: 12px !important;
                color: #000000 !important;
             }
             a
             {
                font-size: 12px !important;
                color: #000000 !important;
                }
          </style>
          <link type="text/css" href="http://dnndev2.dnn.global-e.nl/portals/nieuwsbrief.css" />
       </
    head>
       <
    body>
          This is a test for EditCompleteDocument with aTemplate file. 
       </body>
    </
    html>
    5. Go to HTML code view, see the HTML code:
    <html>
        <head>
            <title>test</title>
        </head>
        <body>
            <p>
            <style type="text/css">
            body
            {
            font-size: 12px !important;
            color: #000000 !important;
            }
            a
            {
            font-size: 12px !important;
            color: #000000 !important;
            }
            </style>
            <link href="http://dnndev2.dnn.global-e.nl/portals/nieuwsbrief.css" type="text/css" />

             This is a test for EditCompleteDocument with aTemplate file. </p>
        </body>
    </html>
     
    Titel "This is a title" is completely removed, the stylesheets and external link to stylesheet files is placed in the <Body>!
    But when you paste the exact same html code in the HTML code view manually, this problem will not happen.
    Is this working as intended or is more like a bug?
View Complete Thread