<?php // Script: Copyright 2003 Janice Heinold, jmhdesign@att.net or // heinold@falcon.tamucc.edu // // Modified for PmWiki-0.6 by Patrick R. Michaud, 23-Feb-2004. // To make this script work, add the following line to your config.php: // include("local/smileys.php"); // Configuration // By default, this script looks for the smiley images // in a folder called "smileys" in the "pub" folder for pmwiki. // If your smiley images are elsewhere, // you can set the path to the folder the smileys are in. // It should end with the name of the directory with no ending slash. // For example, you can set: // $SmileysFolder = "http://www.yourdomain.com/smileys/gif"; SDV($SmileysFolder,"$PubDirUrl/smileys"); // *************************************************** // You shouldn't need to edit anything below this line // Assign smiley "img src" tags to regular expression patterns $Smileys = array ( "/\{?:-?\)/" => "<img src='$SmileysFolder/happy.gif' border='0' width='15' height='15' alt='happy smiley'>", "/\{?;-?\)/" => "<img src='$SmileysFolder/wink.gif' border='0' width='15' height='15' alt='winking smiley'>", "/\{?:-?\(/" => "<img src='$SmileysFolder/sad.gif' border='0' width='15' height='15' alt='frowning smiley'>", "/\{?:-?p/" => "<img src='$SmileysFolder/tongue.gif' border='0' width='15' height='15' alt='laughing smiley'>", "/\{?:-?o/" => "<img src='$SmileysFolder/redface.gif' border='0' width='15' height='15' alt='embarrassed smiley'>", "/\{cool\}/" => "<img src='$SmileysFolder/cool.gif' border='0' width='15' height='15' alt='cool smiley'>", "/\{?:-?D/" => "<img src='$SmileysFolder/biggrin.gif' border='0' width='15' height='15' alt='grinning smiley'>", "/\{confused\}/" => "<img src='$SmileysFolder/confused.gif' border='0' width='15' height='22' alt='confused smiley'>", "/\{eek\}/" => "<img src='$SmileysFolder/eek.gif' border='0' width='15' height='15' alt='shrieking smiley'>", "/\{angry\}/" => "<img src='$SmileysFolder/mad.gif' border='0' width='15' height='15' alt='angry smiley'>", "/\{rolleyes\}/" => "<img src='$SmileysFolder/rolleyes.gif' border='0' width='15' height='15' alt='rolling eyes smiley'>", ); // Merge InlineReplacements with Smiley array $InlineReplacements = array_merge($InlineReplacements, $Smileys); ?>