Templates is not strictly enforcing the output

B

Barn

I have made this template:

<mobile:ObjectList id="resultlist" Font-Size="Small" Font-Name="Tahoma,
Arial" runat="server" LabelStyle-StyleReference="title"
CommandStyle-StyleReference="subcommand">
<DeviceSpecific>
<Choice Filter="isWML11" Argument="wml11"
Xmlns="http://schemas.microsoft.com/mobile/html32template">
<ItemTemplate>
<div style="background-color: ##C3D4D4">
<p><small>
<mobile:Label id="Label2" text='<%#((ObjectListItem)Container)["Navn"] %>'
Runat="server">
</mobile:Label>
<mobile:Label id=Label11 text='<%#((ObjectListItem)Container)["Vej"] %>'
Runat="server">
</mobile:Label>
<mobile:Label id=Label12 text='<%#((ObjectListItem)Container)["Byen"] %>'
Runat="server">
</mobile:Label>
<mobile:phoneCall id="Phonecall2" Runat="server"
PhoneNumber='<%#((ObjectListItem)Container)["Nummer"] %>'>
</mobile:phoneCall></small></p>
</div>
</ItemTemplate>

<AlternatingItemTemplate>
<div style="background-color: #D1E3E3">
<p><small>
<mobile:Label id="Label4" text='<%#((ObjectListItem)Container)["Navn"] %>'
Runat="server">
</mobile:Label>
<mobile:Label id="Label13" text='<%#((ObjectListItem)Container)["Vej"] %>'
Runat="server">
</mobile:Label>
<mobile:Label id="Label14" text='<%#((ObjectListItem)Container)["Byen"] %>'
Runat="server">
</mobile:Label>
<mobile:phoneCall id="Phonecall3" Runat="server"
PhoneNumber='<%#((ObjectListItem)Container)["Nummer"] %>'>
</mobile:phoneCall></small></p>
</div>
</AlternatingItemTemplate>
</Choice>
</DeviceSpecific>
</mobile:ObjectList>

It yields this (wrong) output, where it is the second line "<do
type="accept"><noop /></do><p> "
That last <p> did I NOT ask for.
Furthermore on line 15, in the alternating line, the output it also gives an
extra "</br>" before NAVN.


<card>
<do type="accept"><noop /></do><p>
<div style="background-color: ##C3D4D4">
<p><small>
NAVN
<br/>
VEJ
<br/>
BYEN
<br/>
NUMMER</small></p>
</div>

<div style="background-color: #D1E3E3">
<p><small>
<br/>
NAVN
<br/>
VEJ
<br/>
BYEN
<br/>
NUMMER</small></p>
</div>
</small></p></card>

How do I remove these extras <p> and </br> ?
Is the templating only "guidelines" for how to create the output?
It looks like my application puts extra tags at its own discretion.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top