Created
February 26, 2012 14:41
-
-
Save lluchs/1917101 to your computer and use it in GitHub Desktop.
Plugin for email-style quotes in Wordpress
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Email Quotes | |
Description: Allows comments to have email-style '>' quotes | |
Version: 1.0 | |
Author: Lukas Werling | |
Author URI: http://github.com/lluchs | |
License: MIT | |
*/ | |
add_filter('comment_text', 'emailquotes'); | |
function emailquotes($text) { | |
return preg_replace('/^((>|>).+)/m', '<blockquote>$1</blockquote>', $text, 100); | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment