Conditional HTML Building

  • Thread starter Thread starter Demetri
  • Start date Start date
D

Demetri

Lets say I want the page to build a certain way based on a
querystring value and I need to do it within the HTML
(aspx not cs file).

In classic asp using vb I could do something like:

<%if request.querystring("msg") = "hello"%>
<div>Hello world</div>
<%else%>
<div>No message</div>
<%end if%>

What would be the equivalent (translate it) of that in C#?
 
Demetri,

Look up the "Literal" control.

I think it may help you with this type of thing.

Sincerely,

--
S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 
Back
Top