function getPartUrl(part) {
var query = self.location.href;
if( query.indexOf(part) == -1 ){
return false;
}else{
return true;
}
}
//Example
<script>document.write getPartUrl('news.php') ? 1 : 0</script>
Javascript – Get Part Url
Leave a Reply
You must be logged in to post a comment.