-3
<td align="center" valign="middle" style="color:White;background-color:Red;font-weight:bold;">(.*?)</td>

I can not get any data. Can you help for regex?

mr.android
  • 13
  • 8

1 Answers1

0

Is it RegExp template you show us?

This should be like this in php:

$exp = '<td align="center" valign="middle" style="color:White;background-color:Red;font-weight:bold;">(.*?)</td>';
$subject_string = '';
preg_match_all("|{$exp}|U",
    subject_string,
    $out, PREG_PATTERN_ORDER);

So, $out[0] contains array of strings that matched full pattern, and $out[1] contains array of strings enclosed by TD tag.

Don't forget to wrap your expression like shown in example - "|{$exp}|U"

For more info watch this - http://php.net/manual/en/function.preg-match-all.php

bfday
  • 163
  • 2
  • 11
  • With templates you have given "subject_string" as an example instead of ' 67 td> 'I'm taking the summer when 67 value. But how do I get all this value in the page? – mr.android Apr 16 '16 at 19:24