Reputation:
when i click on this link the url on page.php is http://localhost/1/page.php?id=1&edition=muzzaffarabad&dt=09-08-2017. i want that after passing these parameters only edition name will show on url .like http://localhost/1/muzzaffarabad
this is anchor tag i m using
<a class='imgFrame' href='page.php?id=1&edition=muzzaffarabad&dt=<?php echo $paper_set["muzzaffarabad_date"]?>'>
Upvotes: 0
Views: 433
Reputation: 1664
Just make your a tag like this:
<a onclick="changeHref()" class='imgFrame' href='page.php?id=1&edition=muzzaffarabad&dt=<?php echo $paper_set["muzzaffarabad_date"]?>'>
Then in your javascript file add function
function changeHref() {
$(".imgFrame").attr("href", "http://localhost/1/muzzaffarabad");
}
Upvotes: 1