• Home
  • Archive
  • Tools
  • Contact Us

The Customize Windows

Technology Journal

  • Cloud Computing
  • Computer
  • Digital Photography
  • Windows 7
  • Archive
  • Cloud Computing
  • Virtualization
  • Computer and Internet
  • Digital Photography
  • Android
  • Sysadmin
  • Electronics
  • Big Data
  • Virtualization
  • Downloads
  • Web Development
  • Apple
  • Android
Advertisement
You are here:Home » Syntax Highlighting : All About the Colorful Snippets

By Abhishek Ghosh July 7, 2012 3:39 pm Updated on July 7, 2012

Syntax Highlighting : All About the Colorful Snippets

Advertisement

Syntax Highlighting is a method for coloring certain words and characters in a text depending on their importance in in an piece of code or snippet. If you are new to WordPress for blogging purpose, you might have seen in some websites, colored texts for PHP, CSS, HTML etc. languages and markups are used. So how these colored things appears and why we basically need them ? To explain this, here is the article on Syntax Highlighting.

 

Basics of Syntax Highlighting

 

Syntax highlighting is mainly used in text editors, like we previously we wrote about gedit for editing excellent documents, program and configuration files. Syntax Highlighting is based on language elements.

Syntax highlighting improves the readability and clears the structures in the text separating comments from the actual code and it also indicates typographical mistakes more quickly, because in many cases only typo creates the problem.

Advertisement

---

Wilfred Hansen, in 1969 first used practical Syntax Highlighter in the code editor Emily.

 

Resources and Information on Syntax Highlighting

 

Syntax Highlighting in Text Editors 

 

Microsoft Windows, a great malware proof Operating System, has no Syntax Highlighting software shipped by default. However, most free UNIX like Operating System has basic text editors with Syntax Highlighting feature. Even, stripped down server OS versions of Linux has Syntax Highlighting feature, in our recent guide on Installing OpenPanel on Rackspace Cloud Server, we have used nano, a Text Editor which works in Command Line Interface (CLI) :

 

Syntax Highlighting in Nano

 

Gedit is one of the most powerful Syntax Highlighting text Editor.

 

Syntax Highlighting in web browser 

 

In most modern web browsers, like Opera, Mozilla Firefox, Google Chrome, Safari etc. has very good Syntax Highlighting feature while using the development related tools.

Please do not think that the fastest web browser named Internet Explorer has no Syntax Highlighting feature from the corollary that  Microsoft Windows by default has no Syntax Highlighting tool. It has a decade old Syntax Highlighting tool. That is better than having nothing like Notepad.

 

Syntax Highlighting in Web CMS like WordPress, Joomla!

 

GeSHi is a PHP based Generic Syntax Highlighter, which has been used in various Plugins. WP-Syntax is an age old WordPress Plugin that uses GeSHi.

 

Example of Syntax Highlighting

 

If I write this :

 

/**

* Example of Syntax Highlighting

*/

if ( !defined(‘WP_LOAD_IMPORTERS’) && !defined(‘DOING_CRON’) )
return;

require_once ABSPATH . ‘wp-admin/includes/import.php’;
require_once ABSPATH . ‘wp-admin/includes/admin.php’;

It is not possible to understand which is code part and which is not. But if I use WordPress default pre tag, it somewhat looks better :

 

Vim
1
2
3
4
5
6
7
8
9
<?php
/**
* Example of Syntax Highlighting
*/
if ( !defined('WP_LOAD_IMPORTERS') &amp;&amp; !defined('DOING_CRON') )
return;
 
require_once ABSPATH . 'wp-admin/includes/import.php';
require_once ABSPATH . 'wp-admin/includes/admin.php';

There are advanced Syntax Highlighting plugin and scripts which helps to see the code as plain text, copy in one click or print.
Signature

Facebook Twitter Pinterest

Abhishek Ghosh

About Abhishek Ghosh

Abhishek Ghosh is a Businessman, Surgeon, Author and Blogger. You can keep touch with him on Twitter - @AbhishekCTRL.

Here’s what we’ve got for you which might like :

Articles Related to Syntax Highlighting : All About the Colorful Snippets

  • Nginx WordPress Installation Guide (All Steps)

    This is a Full Nginx WordPress Installation Guide With All the Steps, Including Some Optimization and Setup Which is Compatible With WordPress DOT ORG Example Settings For Nginx.

  • Change Github’s Default Gist Style With jQuery Plugins

    Yes, There Are jQuery Plugins to Change Github’s Default Gist Style With jQuery Plugins! They can do lot of works than simple changing look.

  • Changing Data With cURL for OpenStack Swift (HP Cloud CDN)

    Changing Data With cURL For Object is Quite Easy in OpenStack Swift. Here Are Examples With HP Cloud CDN To Make it Clear. Official Examples Are Bad.

  • Nano Syntax Highlighting : nanorc

    Nano Syntax Highlighting Can Be Forced With nanorc Files on All Linux Distro Like Ubuntu, CentOS, REHL, Arch Linux As Well As on OS X & BSD.

performing a search on this website can help you. Also, we have YouTube Videos.

Take The Conversation Further ...

We'd love to know your thoughts on this article.
Meet the Author over on Twitter to join the conversation right now!

If you want to Advertise on our Article or want a Sponsored Article, you are invited to Contact us.

Contact Us

Subscribe To Our Free Newsletter

Get new posts by email:

Please Confirm the Subscription When Approval Email Will Arrive in Your Email Inbox as Second Step.

Search this website…

 

vpsdime

Popular Articles

Our Homepage is best place to find popular articles!

Here Are Some Good to Read Articles :

  • Cloud Computing Service Models
  • What is Cloud Computing?
  • Cloud Computing and Social Networks in Mobile Space
  • ARM Processor Architecture
  • What Camera Mode to Choose
  • Indispensable MySQL queries for custom fields in WordPress
  • Windows 7 Speech Recognition Scripting Related Tutorials

Social Networks

  • Pinterest (24.3K Followers)
  • Twitter (5.8k Followers)
  • Facebook (5.7k Followers)
  • LinkedIn (3.7k Followers)
  • YouTube (1.3k Followers)
  • GitHub (Repository)
  • GitHub (Gists)
Looking to publish sponsored article on our website?

Contact us

Recent Posts

  • Cloud-Powered Play: How Streaming Tech is Reshaping Online GamesSeptember 3, 2025
  • How to Use Transcribed Texts for MarketingAugust 14, 2025
  • nRF7002 DK vs ESP32 – A Technical Comparison for Wireless IoT DesignJune 18, 2025
  • Principles of Non-Invasive Blood Glucose Measurement By Near Infrared (NIR)June 11, 2025
  • Continuous Non-Invasive Blood Glucose Measurements: Present Situation (May 2025)May 23, 2025
PC users can consult Corrine Chorney for Security.

Want to know more about us?

Read Notability and Mentions & Our Setup.

Copyright © 2026 - The Customize Windows | dESIGNed by The Customize Windows

Copyright  · Privacy Policy  · Advertising Policy  · Terms of Service  · Refund Policy