tags:

views:

25

answers:

1

how can you get a GET variable with javascript? i get it in php from the query string: $idmessage = $_GET['id'];

then need to send it in $.ajax() jquery, how can i do this? regards

A: 

GET variables do not exist on clientside. You need to parse document.location.href. You can make a shortcut with this, I believe, if you're using jQuery as you say.

Amadan
yes good one, i succeedeed to get the GET var but by echoing the javascript, parsing location.href looks like the real solution here
tada
thank you Amadan!
tada