Advertisement
Guest User

Untitled

a guest
Jul 27th, 2017
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. var x = 0
  2. mySearch = location.search.substr(1).split("?")
  3. if (mySearch == "pack2") {
  4. alert(mySearch);
  5. } else {
  6.  
  7. }
  8.  
  9. I have passed the variable okay to next page and then I can read the variabe I have passed and
  10. display it in messege box using the code above. But i want it to instead of alerting to perform
  11. another javascript function. I have tried
  12.  
  13. var x = 0
  14. mySearch = location.search.substr(1).split("?")
  15. if (mySearch == "pack2") {
  16. function()
  17. } else {
  18.  
  19. }
  20.  
  21. but it doesnt work can any help me please?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement