Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Intraweb 14.2.7 duplicate head section of my html template

In a Delphi Intraweb application I use a TIWTemplateProcessorHTML with a html template as a workframe, but at runtime, the head section of my html is duplicated, hence runtime issues.
I've uploaded the html page created by Chrome.

What do I do wrong? Any ideea?
Are you using master templates? Most of the times this is caused by issues on the html used as template... so I'd have to check your template do know
Yes, I use master templates and in all of them the head is duplicated. I've attach the template below and the code generated by Chrome at runtime.

Attached Files
.html   webMainForm.html (Size: 6.49 KB / Downloads: 4)
.html   view-source_127.0.0.1_8899_$_.html (Size: 9.5 KB / Downloads: 3)
Hi, read this:
You need a $body tag in your MASTER, ex:
  <div class="div-body">$body
  <div class="div-footer">
    (C) Atozed Software Ltd.
I've put it and now it duplicates the body too; the head remains duplicated.
I've attached both files.

Attached Files
.html   view-source_127.0.0.1_8899_$_.html (Size: 14.5 KB / Downloads: 0)
.html   webMainForm.html (Size: 6.53 KB / Downloads: 2)
Hi, i think you don't understand how IW works when using MasterTemplates. I rewrite your page. In your ServerController -> MasterTemplate := 'MASTER.html';

Attached Files
.html   MASTER.html (Size: 1.55 KB / Downloads: 9)
.html   webMainForm.html (Size: 5.01 KB / Downloads: 12)
Thank you a lot.
You were right.
It works now.

Forum Jump:

Users browsing this thread: 1 Guest(s)