Created
August 19, 2014 07:47
-
-
Save ABooooo/b55139712696efd6b609 to your computer and use it in GitHub Desktop.
Check URL and create an array
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// check url | |
var url = window.location.pathname; | |
var output = url.split('/'); | |
//alert (output[0]); | |
if (output[0] == "condition") { | |
// do something | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment