Let user ad javascript code

4 posts by 2 authors in: Forums > CMS Builder
Last Post: August 27, 2013   (RSS)

By gregThomas - August 27, 2013

Hi Maurice, 

The best solution might be to have a separate text box field where the user can enter their JavaScript code, there are two benefits too this:

1)The JavaScript code won't be edited/affected by the WYSIWYG editor.

2)You can place the JavaScript code in the header, or below the body tag of the page. 

It is possible to stop the WYSIWYG editor from formatting the code, but it requires editing some core CMS Builder files, so we don't recommend it. 

Cheers

Greg

Greg Thomas







PHP Programmer - interactivetools.com

By Maurice - August 27, 2013

Hi Greg,

Thats exactly what I did but its not working.

The code keeps getting messed up.

any idea's ???

Thx Maurice

-------------------------------------------

Dropmonkey.nl

By gregThomas - August 27, 2013

Hi Maurice,

How is the code being messed up? Is it not being run and displayed on the page? Or are random characters being added? Could you show me the code you're using to display the JavaScript on your page?

Thanks!

Greg

Greg Thomas







PHP Programmer - interactivetools.com