4images code on GitHub Click here to visit GitHub.
0 Members and 1 Guest are viewing this topic.
thank's u give me the code but i can't text if use smile i don't know why , and i want code aim in comment and online offline too can u help me ????
Is it possible to enable emoticons in image description?
$description = (!empty($image_row['image_description'])) ? $image_row['image_description'] : REPLACE_EMPTY;
$description = (!empty($image_row['image_description'])) ? format_text($image_row['image_description'], 1) : REPLACE_EMPTY;
V@no,is the WYSIWYG you have in your own site (Under the emotions icons) for the comments area, a hack from here? I tried to search for it but didn't find it. It's just so cool.p.s. if this doesn't fit here, plz forgive me.
<!-- BEGIN SMILIES --><br><script language="JavaScript">function PopUp(aaa,zz,xx,scrb){var wsss = eval (screen.width/2 - zz/2);var hsss = eval(screen.height/2 - xx/2);helpWin = window.open(aaa,"imageWin","toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars="+scrb+",resizable=0,width="+ zz +",height="+ xx +",left="+ wsss +",top="+ hsss +"");}</script> <a href="JavaScript:paste_strinL(':)',0)"><img src="./img/smilies/grin.gif" border=0></a><a href="JavaScript:paste_strinL(';)',0)"><img src="./img/smilies/wink.gif" border=0></a><a href="JavaScript:paste_strinL(':up:',0)"><img src="./img/smilies/up.gif" border=0></a><a href="JavaScript:paste_strinL(':down:',0)"><img src="./img/smilies/down.gif" border=0></a><a href="JavaScript:paste_strinL(':biglol:',0)"><img src="./img/smilies/biglol.gif" border=0></a><a href="JavaScript:paste_strinL(':confused:',0)"><img src="./img/smilies/confused.gif" border=0></a><a href="JavaScript:paste_strinL(':cool:',0)"><img src="./img/smilies/cool.gif" border=0></a><a href="JavaScript:paste_strinL(':mad:',0)"><img src="./img/smilies/mad.gif" border=0></a><a href="JavaScript:paste_strinL(':sad:',0)"><img src="./img/smilies/sad.gif" border=0></a><a href="JavaScript:paste_strinL(':shame:',0)"><img src="./img/smilies/shame.gif" border=0></a><a href="JavaScript:paste_strinL(':smirk:',0)"><img src="./img/smilies/smirk.gif" border=0></a><a href="JavaScript:paste_strinL(':tongue:',0)"><img src="./img/smilies/tongue.gif" border=0></a><small><a href="javascript:PopUp('hack_smilies.php?p=display',150,400,1)">...</a></small><!-- END SMILIES -->
//--------------------------//--------Smiles------------//--------------------------function smilies($text,$enablesmilies = 1) { global $smileyfromcache, $smileytocache; $imagesdir = TEMPLATE_PATH."/smiles"; if(gettype($smileyfromcache) != "array") { $smilesfrom = array( ":)" => "smile", ";)" => "wink", ":(" => "sad", ":D" => "laugh", "8-)" => "calm", ":o" => "surprised", ";(" => "sob", "(sweat)" => "sweat", ":|" => "silence", ":*" => "kiss", ":P" => "tonque", ":$" => "blush", "(blush)" => "blush", ":^)" => "wondering", "|-)" => "sleepy", "|-(" => "dull", "|(" => "dull", "(inlove)" => "inlove", "]:)" => "evil-grin", "(talk)" => "talking", "(yawn)" => "yawn", "(puke)" => "puke", "(doh)" => "doh", ":@" => "angry", "(wasntme)" => "wasntme", "(party)" => "party", ":S" => "worried", "(mm)" => "mm", "8-|" => "nerdy", ":x" => "lips", ":X" => "lips", "(wave)" => "hi", "(devil)" => "devil", "(angel)" => "angel", "(makeup)" => "makeup", "(chuckle)" => "chuckle", "(rofl)" => "rofl", "(whew)" => "whew", "(happy)" => "happy", "(smirk)" => "smirk", "(nod)" => "nod", "(shake)" => "shake", "(punch)" => "punch", "(emo)" => "emo", "(y)" => "y", "(n)" => "n", "(handshake)" => "handshake", "(h)" => "heart", "(u)" => "brocken", "(e)" => "mail", "(F)" => "flower", "(rain)" => "rain", "(sun)" => "sun", "(o)" => "time", "(music)" => "music", "(~)" => "movie", "(mp)" => "phone", "(coffee)" => "coffee", "(pi)" => "pizza", "(pizza)" => "pizza", "(l)" => "heart", "(L)" => "heart", "(muscle)" => "muscle", "(flex)" => "muscle", "(cash)" => "cash", "(^)" => "cake", "(beer)" => "beer", "(d)" => "drink", "(dance)" => "dance", "(ninja)" => "ninja", "(*)" => "star", "(bandit)" => "bandit", "(bug)" => "bug", "(drunk)" => "drunk", "(evilgrin)" => "evilgrin", "(finger)" => "finger", "(flagbg)" => "flagbg", "(fubar)" => "fubar", "(hi)" => "hi", "(call)" => "call", "(envy)" => "envy", "(wait)" => "wait", "(clap)" => "clap", "(think)" => "think", "(hug)" => "bear", "(skype)" => "skype", "(ss)" => "skype", "(bow)" => "bow", "(headbang)" => "headbang", "(mooning)" => "mooning", "(poolparty)" => "poolparty", "(rock)" => "rock", "(smoke)" => "smoke", "(tmi)" => "tmi", "(toivo)" => "toivo", "(yawn1)" => "yawn1", "(swear)" => "swear" ); foreach ($smilesfrom as $key => $val) { $smileyfromcache[] ='/(((>[^<]*)|(^[^<]*))([\s\n\r]|^|<br( \/)?[>]))('.str_replace('|','\|', quotemeta(str_replace("<", "<", str_replace(">", ">", str_replace("\/", "\\\/", $key))))).')/s'; $smileytocache[] = "\\1<img src=\"$imagesdir/$val.gif\" alt=\"\" border=\"0\">"; } } if ($enablesmilies) { $text = parsesmilies($text); } return $text;}function parsesmilies($text) { global $smileyfromcache, $smileytocache; $oldtext = ""; while($oldtext != $text) { $oldtext = $text; $text = preg_replace($smileyfromcache, $smileytocache, $text); } return $text;}//------End Smiles-------