Thesis Theme and Javascript...why does this not work?

by 4 replies
5
On my old (non thesis) site i had a wordpress post with a simple form which used simple math functions from a script.

I simply put

Code:
<p><script type="text/javascript" src="http://www. MYSITE.com/scripts/wwpscript.js"></script></p>
as first line in the posting, and then below the HTML with the form.

(The script is extremely simple, it just does a calculation based on values input in the form).

Now - this WORKS after i installed Thesis theme on the site, but as soon as i edit the code...or even if i copy the code and paste it in MS Expression WEB and want to test it locally it simply doesnt work anymore.

In other words..i cant edit/change the post without the JS breaking.

I am at a loss since i already tried everything, putting the script in the head, adding the script in the form field for the post in thesis "custom javascript"...i have no clue why the script stops working.

Any help would be appreciated.
#website design #javascriptwhy #theme #thesis #work
  • It's probably because the post editor is changing the script tags to &lt; and &gt; character entities.

    Try going to your user preferences and turning off the Visual Editor. Log out, clear your browser cache, then log back in and try to edit the post with the old editor.
  • ahhhh..that sounds reasonable!! thanks!
    • [1] reply
  • THe wordpress visual editor can cause problems so you may need to trun it off and just use html view for coding work

    Otherwise, consult the Thesis forum which is excellent

Next Topics on Trending Feed