]> gitweb.fluxo.info Git - lorea/elgg.git/commitdiff
Refs #1330: Contributed autop() to Wordpress.
authorbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 22 Oct 2009 21:00:21 +0000 (21:00 +0000)
committerbrettp <brettp@36083f99-b078-4883-b0ff-0f9b5a30f544>
Thu, 22 Oct 2009 21:00:21 +0000 (21:00 +0000)
git-svn-id: http://code.elgg.org/elgg/trunk@3573 36083f99-b078-4883-b0ff-0f9b5a30f544

engine/lib/input.php

index 289542547d34eba62e4c038129aee5e2ab2f239d..a412f3644c68222e8f43f9fae293b7b8d9233414 100644 (file)
@@ -116,6 +116,12 @@ function parse_urls($text) {
        ), $text);
 }
 
+/**
+ *
+ * Adds P tags.
+ * Borrowed from Wordpress.
+ *
+ **/
 function autop($pee, $br = 1) {
        $pee = $pee . "\n"; // just to make things a little easier, pad the end
        $pee = preg_replace('|<br />\s*<br />|', "\n\n", $pee);
@@ -359,4 +365,4 @@ function input_init() {
        }
 }
 
-register_elgg_event_handler('init','system','input_init');
\ No newline at end of file
+register_elgg_event_handler('init','system','input_init');