Last active
December 20, 2017 10:04
-
-
Save zaurmag/2d4ed770687229238eb648c7da4206a1 to your computer and use it in GitHub Desktop.
pervyi abzatc - reguliarka php
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 | |
$text = $this->item->text; | |
$patern="#<[\s]*p[\s]*>([^<]*)<[\s]*/p[\s]*>#i"; | |
if(preg_match($patern, $text, $matches)) echo "<p>".$matches[1]."</p>"; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment