Hi Scott,

The hash was a suggestion on another site. I have tried it without it as 
well but no joy. If I alert the "serial" on success I get what I would 
expect ie. item[]=2&item[]=3&item[]=10

At the moment the "updatesql.php" file is simply setup so if the page is 
called it connects to the database and updates a record. I dont make use 
of the 'serial' data. This is how I know its not working. If I do :

data: serial.hash or data: serial, = nothing gets updated.
data: "name=John&location=Boston" = the table gets updated via updatesql.php

Chris.

Scott Sauyet wrote:
>
> Chris Jones wrote:
>> <script>
>> $(document).ready(function(){
>>     $("#list").sortable({
>>         accept: 'item',
>>         update: function(sorted) {
>>             serial = $('#list').sortable('serialize');
>>             $.ajax({
>>                 url:"updatesql.php",
>>                 type:"POST",
>>                 data: serial.hash,
>>                 error:function(){alert('Failed');},
>>                 success:function(){alert('Success');}
>>             });
>>         }
>>     });
>> });
>> </script>
>
> Have you tried doing an alert on serial.hash?
>
> I don't know that property.  The sortable('serialize') function 
> returns a String that should be all set for being part of a URL, so 
> you might just try
>
>                 data: serial,
>
> Where is that hash property defined?
>
>   -- Scott

Reply via email to