Adding ASP.Net Controls to Pages
I'm trying to add ASP.Net controls to pages. I try to create a new template called CodeTest_Template and I add the following:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<h2>Dynamic Data Loader</h2>
<asp:DropDownList ID="ddlTest" runat="server">
</asp:DropDownList>
<!--#START-CODE
'here I will dynamically populate the above dropdown list when the page loads
#END-CODE-->
<system-region name="DEFAULT"/>
</form>
</body>
</html>
However once I click 'submit' the asp:DropDownList element is removed. I am extremely new to Cascade Server so any pointers would be greatly appreciated.
Thanks!
Discussions are closed to public comments.
If you need help with Cascade CMS please
start a new discussion.
Keyboard shortcuts
Generic
| ? | Show this help |
|---|---|
| ESC | Blurs the current field |
Comment Form
| r | Focus the comment reply box |
|---|---|
| ^ + ↩ | Submit the comment |
You can use Command ⌘ instead of Control ^ on Mac
1 Posted by david.klanac on 02 Sep, 2010 02:09 PM
Hi Greg,
You just need to specify an XML namespace so that the XML parser will allow your "asp" prefix to be used.
If you modify the
<html>element like this, your .net control will be preserved:Original:
<html xmlns="http://www.w3.org/1999/xhtml">Modified with asp namespace:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:asp="http://www.asp.net">Tim closed this discussion on 24 Sep, 2010 03:23 PM.