I got this code off a site, with a really nice layout and style, I've never worked with input field, so I'm stuck how can I save this to a database.
I tried changing everything to a <asp:Label> and <asp:TextBox> but then I do not get the same layout.
<body>
<div id="text">
<div class="body_resize">
<div class="about">
<h2>Registration</h2>
<form method="post" id="contactform">
<ol>
<li>
<label for="firstName">Name</label>
<input id="firstName" name="nameTextBox" class="text" />
</li>
<li>
<label for="country">Country</label>
<input id="country" name="countryTextBox" class="text" />
</li>
<li>
<label for="email">E-Mail Address</label>
<input id="email" name="emailTextBox" class="text" />
</li>
<li>
<label for="email">Username</label>
<input id="user" name="usernameTextBox" class="text" />
</li>
<li>
<label for="pass1">Password</label>
<input id="pass1" name="pass1TextBox" class="text" />
</li>
<li>
<label for="pass2">Confirm Password</label>
<input id="pass2" name="pass2TextBox" class="text" />
</li>
<li class="buttons">
<input type="image" name="imageField" id="imageField" src="images/send.gif" onclick="Submit" />
</li>
</ol>
</form>
</div>
</div>
</div>
<label for="test"></label>
</body>
I tried this to test:
public partial class Register : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void Submit()
{
test.Text = "Working";
}
}
but I receive an error: The name 'test' does not exist in the current context