View Single Post
Old 04-10-2012, 07:22 PM
Steve Strickland1's Avatar
Steve Strickland1 Steve Strickland1 is offline
Junior Member
Join Date: Apr 2012
Posts: 13

Originally Posted by Makfruit View Post
Well, it often happens that CMS text editors treat JS codes as an HTML and format them accordingly, so, as a result, they don't work. But there is a workaround. Please refer to the second part of this article:

It recommends to place custom JS scripts in a separate js file (or files) and call it from the page code. Moreover, such way gives another advantage - you can use the same external file in different places instead of pasting the same code into the pages one be one.

Please let me know if you have any question.
I put the script inside a JS file and I'm now making a call to the file using:
<script type="text/javascript" language="javascript" src="/wp-includes/redirect.js"></script>

However, those pesky <p> and </p> come back...