<?php
/*
LiteComment is a lightweight text formatter working with blazingly fast speed.
The project's homepage is: http://proger.i-forge.net/LiteComment
If you need a full-fledged text formatting framework you might be interested in
UverseWiki, http://uverse.i-forge.net/wiki
*/
require 'litecomment.php';
function FormatLC($text) {
$text = trim( str_replace("\r", '', $text) );
$text = htmlspecialchars($text);
$lc = new LiteComment($text);
return $lc->FormatInHTML();
}
echo FormatLC('*Hello, world!*'), "<br />\n",
FormatLC('a link point to nowhere: http://google.com'), "<br />\n",
FormatLC('some@maili.ng'), "<br />\n";
echo FormatLC('
== Story title ==
A quotation follows:
"
Once upon a time...
"
"That\'s a *nice* reading!" - he said.
');
|