Hi Guys,

I have a problem where I'm inserting javascript into a block and Drupal appears to alter the code as such. This is on Drupal 6.4 with PHP 5.1.6

This shows up .... <!--blogrush_feed =

When it should be this...

The bracket is being altered. The block is setup to accept full html

Any thoughts on this?

Thanks

Comments

Frameshift’s picture

Damnit...

Here is the code that shows up in the source in the browser...&lt;!--blogrush_feed

When it should appear as the code in the top message with the proper left bracket. This is breaking the script

Any thoughts?

bgilday’s picture

Is your block input filter set to PHP? If not, give that a try.

Brian Gilday
Municode
www.municode.com

Frameshift’s picture

The block was set for Full HTML. But the behavior was odd, when I put that snippet that broke INSIDE the block... it would occur then.
When I put the snippet between the closing header tag, and the beginning body tag, it worked just fine. Go figure. Something about that syntax in the same field on the page broke it.

dinknaround’s picture

I finally decided to create my test site locally and upgrade to D6.6 and ran into this same problem...ugh! Searched drupal with no answer yet...where are all you smart people!!!

Anyhow, my bright idea just hit me and I fixed it in a second...went to 'Admin > Settings > Input formats' and unticked the HTML Corrector. I only did this to my Full HTML format.

Then I tested it on another site I have online with D6, and it worked there too!

Hope this helps someone else (if don't mind not using the HTML Corrector).

-------------------------------------------------
Go with my flow or get out of my way!
Ghostcasefiles.com, dinknaround.com on the way...

Frameshift’s picture

Another way to do it is to create an input format that has NO filters at all. Turns out that the canned "Full HTML" filter actually has a few enabled. Creating a new one without any check boxes checked allows all code to work. I use this for Adsense code and works perfectly.