Raw HTML Plugin for WordPress
Introduction
Recently I needed to put some style definitions and a JavaScript function in a post on another blog that I have. I wasted several hours trying to do this, because WordPress insisted on putting backslashes in front of my apostrophes, inserting superfluous <p> or <br /> tags in place of newlines, and generally breaking my HTML in various horrible ways.
In the end I decided to just go and write a plugin that would let me disable the automatic formatting that WordPress applies to post content. This plugin adds a set of shortcodes that you can use to “protect” specific parts of your post and prevent WP from messing with them.
Download & Installation
Requirements :
- WordPress 2.8 or later
- If you use the free version, I strongly recommend disabling the visual editor. It (the editor) can mess up your code even if you use this plugin.
Installation is straightforward – download the zip file, unzip, upload the raw-html folder to /wp-content/plugins and activate it in the Plugins tab.
Usage
There are two ways to use the plugin. First, to turn off “smart quotes” and other built-in filters for an entire post, use the checkboxes that Raw HTML adds to the “Edit Post” screen:
If you want to prevent a specific part of your post or page from being processed and “texturized” by WordPress, wrap it in ... or <!–raw–>…<!–/raw–> tags. The two versions work exactly the same, with one exception – the <!–raw–>’s won’t be visible to your visitors even if you deactivate the plugin.
Example :
<!--raw-->
This
is
a ‘test’!
<!–/raw–>
Result :
This
is
a 'test'!
If you view the source code of this page, you will see that the newlines are still there, and the apostrophes haven’t been converted/escaped.
Other Notes
This plugin is provided AS IS, with no guarantee that it will work on your site.
Related posts :
Hey Dude,
Thanks for your plugin. But the 1.4.3 update introduced a problem on my site; it causes a large space to be left under buttons created by Really Simple Facebook Twitter Share Buttons. It looks like a spurious [br /] is being inserted into the button code or something. Version 1.4.2 works fine.
Cheers,
Graham
Looks like a problem with filter priorities. I’ve patched it in the development version, give it a try.
Hi, I just use your plugin in one of my client wordpress website, she having problem with form validation javascript. this just save a lot of my time. many thanks for the Raw HTML plugin.
qammar feroz
I would love to buy the pro version of your plugin for RAW html. However, I pretty much refuse to deal with paypal accounts after they ripped me off for $7000. I don’t mind using a credit card through paypal, but your cart requires the creation of a paypal account, which it does not have to do. Any alternative ways I can pay you?
Thanks
Rich Dutton
Gracias!!!! Gracias!!!!!! me has salvado la vida con este plugin!!!!!!!
[…] RAW HTML […]
I like the idea of your raw plug-in but was surprised to discover that it creates 4 separate post_meta entries for every post – even for posts which activate none of the features.
The much abused post_meta table is bloated enough already – was there any special reason for not serializing or otherwise compressing the 4 bits of data your plug-in uses?
You make a good point. I’ll have to change that in the next version.
[…] it. These innocuous actions rendered XML entities into their default (non-escaped) representation. "RawHTML" is a plugin which stopped that outrage 🙂 You just wrap your code by special tags and that's […]
Thanks, great plugin, I always wondered why the code changes sometimes in the wordpress editor.
I was going to buy the Pro version but found out you also want $3 per month? So if I use this for the next 10 years which I probably would, you are valuing the plugin at $360 + $15 = $375?
That is not the normal way to make money from a plugin. Are you getting tons of sales? I doubt it. I would like a reasonable price. Please let me know and I will buy it right away.
It sounds like it’s $3/month, optionally, for ongoing support David. I could be wrong but that’s what I read under the pricing page. 🙂
I have a client that is going nuts with the HTML getting mangled everytime she tries to make a change to her WordPress pages. I tried to show her how to avoid visual mode on the editor, but she seems to be doing it wrong (she lives across the world from me, so I haven’t observed what she is doing wrong…). Avoiding visual mode is a method that works flawlessly for me, but she is over 60 years old, quite an impressive tech granny but still a granny nonetheless so I understand her frustrations. She doesn’t part well with her money, so I need to be able to test your plugin before I purchase it. Is this possible? Seems like the free version doesn’t do what the pro does by a long shot. Even access to a demo site (with admin access) would be awesome. Please and thank you!!!
Yes, that $3 is for support and updates. If you don’t want them, you can cancel the subscription right after buying, and you won’t need to pay the $3 even once.
As for a demo, I don’t have a demo site set up right now, but I suppose I could whip up a simple one for you. Contact me by privately about this : whiteshadow@w-shadow.com
Hmmm. I can’t find any Terms and Conditions for the Pro version. Is the pricing for the tool itself, buy once, use on several blogs, or on a per blog basis?
Right now, it’s buy once, use on any number of (your) blogs.
Now, THAT’s a deal! Thanks for the clarification.
Hi there,
What is the difference between the free and pro versions of the plugin?
Thanks,
meeble
The Pro version makes it possible to switch between HTML and the Visual editor without WordPress messing up your content. The code between [raw] tags is protected. With the free version, WP can still mangle the code if you use the Visual editor.
I clicked on the link for the Pro Version, went to the site and could not find it. Where is it? Many Thanks!
Sorry about that, the link was outdated. I’ve fixed it now. The right link is: http://rawhtmlpro.com/