[jQuery] escaping characters in regex
im attemping to serialize a list i have going, I want to grab the id
it sends back. The issue is that sortserialize.hash is returned as
divArray[]=values;
I want to grab the values on the right side and store them somewhere,
I was trying to replace everything left of the = but, i cant escape []
Eventually I will make it dynamic and for looop through the arry and
sort by commas as well, but
Why is this not working.
Ive tried urlEncoding [] and escaping it and everything
function serialize(s)
{
serial = $.SortSerialize(s);
alert(serial.hash);
var hash = serial.hash;
var temp = hash.replace(new RegExp( "sort1\[\]=", "gi" ),'');
};