With the help of this community, I was able to transfer a static piece of text from javascript (clientside) to ASP 3.5 (server side)! This piece of code works great:
$('.drop').droppable({
tolerance: "touch",
drop: function() {
$('[id$="myHidden"]').val('Testy test test');
__doPostBack('<%= HiddenButton.UniqueID %>', '');
alert($('[id$="myHidden"]').val());
}
});
What is stated above is when an element with the .drop class is removed, it will assign the string "Testy test test" to my hidden field on my aspx page. Then it does a postback to the invisible button that I have within the update panel. A hidden button click event launches a command that issues an msgbox that displays the contents of the hidden element, which invariably is a "Testy test test".
. dropzone, , , , dropzone. , :
$('[id$="myHidden"]').val($(ui.draggable).attr("id"));
__doPostBack('<%= HiddenButton.UniqueID %>', '');
alert($('[id$="myHidden"]').val());
, -, dropzone, . - ? ?
, , aspx:
<asp:Button ID="HiddenButton" runat="server" Text="Button" />
, , css, .
!!!!
, ( "var"?)
var foo = $(ui.draggable).attr("id")
$('[id$="myHidden"]').val(foo);
__doPostBack('<%= HiddenButton.UniqueID %>', '');
alert($('[id$="myHidden"]').val());