note 63694 added to function.preg-match-all
| From: | slavomirdothustatyatgmaildotcom at osu1 dot php dot net | Date: | Tue, 28 Mar 2006 15:10:21 +0000 |
| Subject: | note 63694 added to function.preg-match-all | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-106851@lists.php.net to get a copy of this message | ||
//<h1>some text</h1><b>bold</b><h1>some further text</h1>
//if needed what's between tags :-)
class find_regex
{
var $search_tag;
var $result;
//preg_match_all("/(<h1[^>]*>)([^<]*)(<\/h1>)/", $html, $matches);
function find_regex($tag = "h1")
{
$this->search_tag = $tag;
}
function parse($text_to_parse = "")
{
$regex = "/(<" . $this->search_tag . "[^>]*>)([^<]*)(<\/" .
$this->search_tag . ">)/";
preg_match_all( $regex , $row->buffer_sk , $matches );
$this->result = $matches;
return $matches[2];
}
}
----
Server IP: 62.65.181.66
Probable Submitter: 194.1.131.4
----
X-Spam-Status: No, hits=3.1 required=5.0 tests=DATE_MISSING,FROM_NO_LOWER
autolearn=no version=2.64
----
Manual Page -- http://www.php.net/manual/en/function.preg-match-all.php
Edit -- http://master.php.net/note/edit/63694
Del: integrated -- http://master.php.net/note/delete/63694/integrated
Del: useless -- http://master.php.net/note/delete/63694/useless
Del: bad code -- http://master.php.net/note/delete/63694/bad+code
Del: spam -- http://master.php.net/note/delete/63694/spam
Del: non-english -- http://master.php.net/note/delete/63694/non-english
Del: in docs -- http://master.php.net/note/delete/63694/in+docs
Del: other reasons-- http://master.php.net/note/delete/63694
Reject -- http://master.php.net/note/reject/63694
Search -- http://master.php.net/manage/user-notes.php