Newbie: how to handle large response.write blocks

B

Brian F

Hi everyone -

Is there a way to abbreviate the aspx below? Specifically, is there a
way to eliminate the response.write syntax and escaped characters?

<%
if (MyObject.SomeBoolean)
{
Response.Write("<div class=\"myclass\">");
Response.Write("You may have won 1,000,000 dollars...");
Response.Write("lots of text...");
Response.Write("lots of text...");
Response.Write("</div>");
}
else
{
Response.Write("<div class=\"error\">");
Response.Write("You should buy more magazines...");
Response.Write("lots of text...");
Response.Write("lots of text...");
Response.Write("</div>");
}
%>

Thanks.
Brian
 

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,013
Latest member
KatriceSwa

Latest Threads

Top