I have put a javascript code on footer.php of my wordpress blog but I don't want it to execute on 404 page and few other posts/pages. How can I do this ? I know a simple IF expression will work but what is the exact code for it ? Thanks
You can use echo. =) <?php echo '<script>alert("Here insert your JavaScript code.");</script>'; php?> PHP:
No, what I was asking was..I DO not want to show the script on some pages like /404 and /conatct-us and /about so I need something like this - [If page is Not /404 and /conatct-us and /about] echo Script And this code will go in the footer file.