Hi Karl ! Here is what i've try : function ajax_test(){
anc_pv = $('.pv_act').attr("pv"); alert(anc_pv); $.ajax({ type: "GET", url: "ajax_test.php", data: "", dataType: "html", success: function(data){ alert(anc_pv); // But it show "undefinided" alert(anc_pv); } }); }; Here is what i get : First alert : "30" (wich is the right value) Second alert : "undefinided" I've try with or without "var" before anc_pv Another ideas ? :) Thanks for your answers !