This page is still a beta!

Chapter 1. EXT: Text Highlighter

Extension Key: texthighlighter

Copyright 2007, Michiel Roos, <extensions@typofree.org>

This document is published under the Open Content License

available from http://www.opencontent.org/opl.shtml

The content of this document is related to TYPO3

- a GNU/GPL CMS/Framework available from www.typo3.com

1.1. Introduction

What does it do?

It adds a new content element which you can use to create highlighted code snippets on your page. It uses CSS to do the highlighting.

Requirements

It uses the PEAR Text Highlighter package from http://pear.php.net/package/Text_Highlighter. I chose this package because it can highlight:

  1. CPP

  2. CSS

  3. DTD

  4. HTML

  5. JAVA

  6. JAVASCRIPT

  7. MYSQL

  8. PHP

  9. PERL

  10. PYTHON

  11. RUBY

  12. SQL

  13. XML

  14. DIFF

Screenshots

Illustration 1: Optionally add static template and default highlighting css

Illustration 2: Create new text element and choose 'Highlighted text'

Illustration 3: Choose format

Illustration 4: The result