Lorsque je veux rediriger, la variable où est toujours définie. Mais, par exemple, je veux mettre cette variable dans alert();
il montre le nombre correct.javascript variable toujours undefined
Code
var where = msg.txt;
window.location = "/page.php?id=".where; //this redirects to /page.php?id=undefined
alert(where); //it show correct number