Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $pattern = "/<h2 class=\"date-header\">(.*)<\/h2>/";
- $str = file_get_contents("1.txt");
- $matches = array();
- preg_match_all($pattern, $str, $matches);
- if (count($matches) > 0)
- {
- unset($matches[0]);
- }
- var_dump($matches);
Add Comment
Please, Sign In to add comment