Redirect blog post to another web page
This task use javascript to redirect blog post to another web page.
Redirect blog post to another web page
1 | <script> |
2 | var srcUrl = 'URL of blog post'; |
3 | var tagUrl = 'URL of new web page'; |
4 | var curUrl = window.location + ''; |
5 | if (srcUrl != '' && tagUrl != '' && srcUrl.toLowerCase() == curUrl.toLowerCase()) { |
6 | window.location.replace(tagUrl); |
7 | } |
8 | </script> |
<script> var srcUrl = 'URL of blog post'; var tagUrl = 'URL of new web page'; var curUrl = window.location + ''; if (srcUrl != '' && tagUrl != '' && srcUrl.toLowerCase() == curUrl.toLowerCase()) { window.location.replace(tagUrl); } </script>
No comments:
Post a Comment