Jquery and serialize

Hi Folks

I have this question posted on teh jquery website but haven’t had any responses yet, so here I am.

I have created a jquery sortable list page where the user can move and drop elements between lists. The lists are <li>. I need help understanding how to get serialize to work.

Here is a link for a serialize script that I am trying to use. http://www.bram.us/2008/10/27/jqueryserializeanything-serialize-anything-and-not-just-forms/.

I program in classic asp and don’t understand javascript particularly well. All help much appreciated.

Cheers

Joe

Basically save that plugin script as a new javascript file and include it into your HTML. Once you have done that you can simply call it by using

jQueryVar.serializeAnything();

In this instance jQueryVar would be the values you want to serialize.

Hi SgtLegend

Well I declare myself bamboozled. I just can’t get the idea of how to use jquery straight so here I am lookinf for some more assistance. Below is my code. I want to click the button and serialize the li elements into something that I can transport to an asp page for saving, testing, etc. Any chance of a leg up?

<html>
<head>
<script type="text/javascript" src="../common/js/jquery.js"></script>
<script type="text/javascript" src="../common/js/jquery.serializeanything.js"></script>

<script type="text/javascript">
$(document).ready(function() {
	("#me").click(function(event){
	
		$("li").serializeanything(),}
 });

</script>
</head>
<body>
--------

<ul>
	<li id="1">a</li>
	<li id="2">b</li>
	<li id="3">c</li>
	<li id="4">d</li>
</ul>
<button id="me">Click me</button>
</body>
</html>