0
window.location="http://test.rgniyd.com/test1/?q=node/36/"&dept="+ dept +"&bath="+  
bat +"&month=+month+"&year="+year+"&semester="+sem";

how to redirect the page to http://test.rgniyd.com/test1/?q=node/36/ with values in
JavaScript. the above code is not working , please help or please suggest me how to redirect page without clearing the session values in JavaScript

Bala Krishnan
  • 25
  • 2
  • 9

2 Answers2

1

Change your JavaScript as

window.location="http://test.rgniyd.com/test1/?q=node/36/&dept=" + dept + "&bath=" + bat + "&month=" + month + "&year=" + year + "&semester=" + sem;

Because you have misplaced double quotes "

Naveen Kumar Alone
  • 7,536
  • 5
  • 36
  • 57
0

You have messed up (a bit) the string concatenation..

window.location="http://test.rgniyd.com/test1/?q=node/36/&dept="+ dept +"&bath="+  
bat +"&month="+month+"&year="+year+"&semester="+sem;
Gabriele Petrioli
  • 191,379
  • 34
  • 261
  • 317