Welcome to WebmasterWorld Guest from

Forum Moderators: incrediBILL

Message Too Old, No Replies

Embedding non-compiled js or html in page

5:40 pm on Sep 21, 2010 (gmt 0)

Junior Member

5+ Year Member

joined:Feb 26, 2010
votes: 0

i would like the ability to embed code in my blog posts. what is the commonly used object for this that does not compile contents?

please excuse if compile is not the correct word, but it best demonstrates my end goal.
7:14 am on Sept 22, 2010 (gmt 0)

Senior Member from KZ 

WebmasterWorld Senior Member lammert is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Jan 10, 2005
posts: 2907
votes: 10

If you don't want compiled code, maybe plain JavaScript is the right option? We have a specialized forum on JavaScript here: [webmasterworld.com...]
12:26 pm on Sept 22, 2010 (gmt 0)

Full Member

10+ Year Member

joined:Mar 21, 2003
votes: 0

I assume what you mean is that you want to post HTML code in your blog to see but not be parsed as part of the page? So you can show code to others.

If this is the case are you using a CMS like Wordpress, a lot of the CMS packages out there already have a built in way to do this like [code][/code].

Personally I don't use any kind of technique but instead just use the html code for angle brackets, so the body tag would look like this:


I've never thought about it before but there's probably a script out there to do it too :)

EDIT: In fact, have a look here: [webmasterworld.com...]
2:26 pm on Sept 23, 2010 (gmt 0)

Junior Member

5+ Year Member

joined:Feb 26, 2010
votes: 0


thanks. i think i am definitely going to go with the &lt etc functionality. seems to be the best option.