- parent) {echo getPermalinkFromCoid($comments->parent);} $comments->content();?>
+ parent) {echo getPermalinkFromCoid($comments->parent);} echo parse_smiley_shortcode($comments->content);?>
agent);
diff --git a/functions.php b/functions.php
index 8cf0027..27ce07b 100644
--- a/functions.php
+++ b/functions.php
@@ -918,4 +918,51 @@ class AttachmentHelper {
'doubt.png',
+ ':razz:' => 'razz.png',
+ ':sad:' => 'sad.png',
+ ':evil:' => 'evil.png',
+ ':naughty:' => 'naughty.png',
+ ':!:' => 'scare.png',
+ ':smile:' => 'smile.png',
+ ':oops:' => 'oops.png',
+ ':neutral:' => 'neutral.png',
+ ':cry:' => 'cry.png',
+ ':mrgreen:' => 'mrgreen.png',
+ ':grin:' => 'grin.png',
+ ':eek:' => 'eek.png',
+ ':shock:' => 'shock.png',
+ ':???:' => 'bz.png',
+ ':cool:' => 'cool.png',
+ ':lol:' => 'lol.png',
+ ':mad:' => 'mad.png',
+ ':twisted:' => 'twisted.png',
+ ':roll:' => 'roll.png',
+ ':wink:' => 'wink.png',
+ ':idea:' => 'idea.png',
+ ':despise:' => 'despise.png',
+ ':celebrate:' => 'celebrate.png',
+ ':watermelon:' => 'watermelon.png',
+ ':xmas:' => 'xmas.png',
+ ':warn:' => 'warn.png',
+ ':rainbow:' => 'rainbow.png',
+ ':loveyou:' => 'loveyou.png',
+ ':love:' => 'love.png',
+ ':beer:' => 'beer.png',
+ ];
+ $themeUrl = Helper::options()->themeUrl . '/assets/img/smiley/';
+ foreach ($smileys as $code => $img) {
+ $imgTag = '
';
+ $content = str_replace($code, $imgTag, $content);
+ }
+ return $content;
+}
?>
\ No newline at end of file
diff --git a/index.php b/index.php
index 4f919ab..4c6f550 100644
--- a/index.php
+++ b/index.php
@@ -4,7 +4,7 @@
*
* @package Typecho Pouck Theme
* @author 老孙博客
- * @version 1.1.4
+ * @version 1.1.5
* @link http://www.imsun.org
*/