codingtcher.com
Theme Night
Home
Login

Jquery get url path

//jquery get url
var currentURL = $(location).attr('href'); //jQuery solution
var currentURL = window.location.href; // raw javascript

//jquery get URL slug
var pathname = window.location.pathname;

Related Code