So basically, I have a div which is runat=”server”
<div id="results" runat="server" class="results"></div>
Now, I add HTML to this using jQuery.
$('.results').html('Some crazy data');
However, when I try to access the data in this DIV using C#, it says the DIV has no contents.
string myResults = results.innerHtml;
myResults is empty.
Can someone help me out? I’ve never seen this behavior before.
Many Thanks!
You may be looking for something like this…
Now you can access the data on server