Syntax Highlighting in WordPress Without Plugin


Syntax Highlighting in Without Plugin is a method which will you how Syntax Highlighting is in WordPress in Single post without plugin. People usually makes simple things complex. Most of the blogs never need to load the extra junk of CSS and Javascript for Syntax Highlighting in WordPress to be loaded in each and every pages or posts. Syntax Highlighting in WordPress Without Plugin is a Project Started by me, right now the basics will be described.

 

The Idea Behind Syntax Highlighting in WordPress Without Plugin

 

If you have no idea about Syntax Highlighting, kindly read this article on Syntax Highlighting. If you already know about Syntax Highlighting, please check this post as well to that, it is not only Syntax Highlighting, but actually anything like jQuery can be loaded too using the same method.

 

Limitations of using Syntax Highlighting in WordPress Without Plugin

 

The only limitation is, you need to add the codes while in HTML editing mode. Do not switch back to visual mode before publishing the post with codes. We will try to override this bug of TinyMCE.

You can not use this method in free WordPress as javascript embedding is not allowed, although I have not tested, it should not work.

 

Advantages of using Syntax Highlighting in WordPress Without Plugin

 

You need not to install any extra plugin, thereby from homepage to about us will not load any extra CSS and JS. Moreover, no in MySQL database or the call that actually increases the server’s burden is excluded. As I have said before, most of us never use Syntax Highlighting throughout the blog.

 

Method and Example of Syntax Highlighting in WordPress Without Plugin

Syntax Highlighting in WordPress Without Plugin


When I am pasting this code for Syntax Highlighting in WordPress Without Plugin, I am using visual mode of editing :

 

<link rel=”stylesheet” href=”any link to prettify.css” />
<pre class=”prettyprint”>
Your Code Goes Here

</pre>

<script src=”any link to prettify.js”></script>
<script>prettyPrint();</script>

 

But when I am actually live example of Syntax Highlighting in WordPress Without Plugin, I am using HTML mode and without looking back publishing it.
 

(function() {
var jsSyntaxHighlighting = 'thecustomizewindows.com';
})();


 

Resources used for Syntax Highlighting in WordPress Without Plugin

 

We have used only two files in unmodified form from google-code-prettify project. We have used the minified version’s prettify.js and prettify.css file. This project will be uploaded in Google Project after modification for more easier use with customization. So this webpage will be updated as well.

 

Signature


0saves
If you enjoyed this post, please consider leaving a comment or subscribing to the RSS feed to have future articles delivered to your feed reader.

Leave Lame Behind - Get Engaged

Here’s what we’ve got for you:

Contact Us Today for Smarter Marketing of Knowledge

See each of the premium resources below:

For Publishers and Content Owners

Do you want to optimize your available content?

Do you want to increase the visibility of your content?

Do you want to increase your reliability as an Author?

Do you want your next or existing project to be technically planned?

If your answer to any of these is YES contact us with your approximate budget.

Contact Us Today

For the Media Companies and Advertisers

You must be seeking a publisher website like ours with real content to give an exposure to your client's business?

We provide Industry's Standard opportunities for advertisement.

Do you want some promotion that comes with proper invoicing, SLA on per annum basis?

If your answer is YES contact us today for a quote.

Contact Us Today for Quote

Mentions

  1. Syntax Highlighting in WordPress Without Plugin says:

    [...] Syntax Highlighting in WordPress Without Plugin [...]

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>