WYSIWYG and Yahoo Pipes code

3 posts by 2 authors in: Forums > CMS Builder
Last Post: September 17, 2008   (RSS)

Re: [benedict] WYSIWYG and Yahoo Pipes code

By Dave - September 17, 2008

Hi benedict,

I had a quick look through the tinymce source code. It looks like this is hard coded behavior. Having script content inside a comment or CDATA tag is actually what it is suppose to be for valid HTML. I'm surprised that yahoo doesn't support that.

Try this code before you display that variable:
<?php $yourVariable = preg_replace("|(<script.*?\s*>)<!--\s*(.*?)\s*// -->(</script>)|", "$1$2$3", $yourVariable);

It should strip out the comment for you.

Hope that helps!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] WYSIWYG and Yahoo Pipes code

By benedict - September 17, 2008

Thanks Dave,

Worked great.