but the html that will be send on iframe will be the HTMLBody of an msg file.
What I have tried:
sample
send
(Insert html codes without replacing the above tags)
Default.aspx.cs:
MailItem item = (MailItem)app.CreateItemFromTemplate(@"C:\Users\elayronj\Desktop\Sample\sample.msg", Type.Missing);
samplediv.InnerHtml = item.HTMLBody;
Talk1:
Why not just type them there? Are you trying to do this programmatically? Can you show the code if so?
Talk2:
- flagged as not-constructive.
Talk3:
Talk4:
pls see default.aspx.cs for the code. Thanks.
Talk5:
Can you change the template to include some value (e.g. a GUID) in the place where you want to insert the new HTML?
Solutions1
The deprecated
tag can be used to show HTML code inside an HTML page but is no longer part of the XHTML spec. It should still work though in all current browsers.See this working fiddle
According to the docs
The HTML Example Element () renders text between the start and
end tags without interpreting the HTML in between and using a
monospaced font. The HTML2 specification recommended that it should be
rendered wide enough to allow 80 characters per line.
As said in the docs,
The
tag has been deprecated since HTML3.2 and was not implemented in a consistent way. It was completely removed from the language in HTML5 and to achieve the functionality, you can usethe
element or, if semantically adequate, the
element instead. Note that you will need to escape the '
as '
A monospaced font can also be obtained on any element, by applying an
adequate CSS style using monospace as the generic-font value for the
font-family property.
Talk1:
isn't the output of the tags inside xmp is in all text?
Talk2:
sorry...didnt get you..
Talk3:
why is the answer downvoted?
Talk4:
I didn't downvote, but I'm pretty sure the the guy is asking just how to escape < and >, not how to use an esoteric feature.
Talk5:
could you please explain to me, the reason why the tag is deprecated..