i have a div element in my html,
<div id="userSolution" runat="server" text="1234512345123451234512345"></div>
Yes it does contain 25 characters,
i have a button:
<asp:Button id="saveGame" runat="server" text="Save Game" onclick="saveGame_Click" />
server Code:
protected void saveGame_Click(object sender, EventArgs e)
{
string clientInput = userSolution.Attributes["text"];
}
So why... when i debug, does clientInput = "" ?
By my reckoning... text="1234512345123451234512345"
so string clientInput= userSolution.Attribute["text"]; should work right? :s
confused...
even if the div is:
<div id="userSolution" runat="server">1234512345123451234512345</div>
and i read
string clientId = userSolution.InnerHTML;
Still Fails