Reputation: 127
I am using Joomla 1.5. and I am writing a blog in joomla and want to highlight some HTML and javascript code but when I save that article after inserting the HTML code as it is, it gets exicuted itself. I also tried it with codecitation plugin but no result. If you people have any solution then please reply.
Upvotes: 3
Views: 1677
Reputation: 972
Sorry for coming late to the party. I used an extension called Easy Script. Just download, install and paste your script in your article manager and Boom. It even supports Bootstraps and other scripts as well.. Just give is a trial
Upvotes: 0
Reputation: 111
You can use <pre>
and <code>
tags.
Also Joomla has a native plugin to display code and syntax highlighting, based on the Geshi project.
It's easy to use, just be sure it is enabled in your plugins config:
<pre lang="html" >
<p> some text </p>
</pre >
Hope it helps!
Upvotes: 0
Reputation: 14628
Use a <pre>
tag it should work.
e.g.
<pre><html><\html></pre>
Upvotes: 1
Reputation: 15333
In your blog try "& lt;" (without space) to write < and "& gt;" (without space) to write > in your HTML Code.
This syntax is used to write "<" and ">" symbols on some web page. Otherwise it will treat your code as part of the blog article and will show its output.
Upvotes: 0