javascript - Jquery - Create URL from an associative array -


i have associative array urlvalue values follows:

{"folder":"subscriber", "file":"setstatus", "alert":"yes", "id":"12"} 

i turn array url can send variables page. how can done using jquery appear this:

?folder=subscriber&file=setstatus&alert=yes&id=12 

thanks

you need jquery.param():

var params = {"folder":"subscriber", "file":"setstatus", "alert":"yes", "id":"12"}; var str = jquery.param(params); 

Comments

Popular posts from this blog

matlab - Deleting rows with specific rules -

php - MySQLi multi_query results for later use -