vicoldan Posted March 1, 2010 Share Posted March 1, 2010 hello , I need to extract all the tables with class="tb" parameter, that's what I got so far: @^<table[^>]*class="tb"[^>]*>(.*?)</table>$@ ,but it doesn't work, please help me. The output should be something like this: <table ... class="tb" ... > ... </table> , where "..." stands for anything. Quote Link to comment https://forums.phpfreaks.com/topic/193825-get-a-table-from-html/ Share on other sites More sharing options...
JAY6390 Posted March 1, 2010 Share Posted March 1, 2010 %<table[^>]+\bclass="tb"[^>]*>.*?</table>%sm Something like that should do it Quote Link to comment https://forums.phpfreaks.com/topic/193825-get-a-table-from-html/#findComment-1020122 Share on other sites More sharing options...
vicoldan Posted March 1, 2010 Author Share Posted March 1, 2010 %<table[^>]+\bclass="tb"[^>]*>.*?</table>%sm Something like that should do it thank you , it really did work Quote Link to comment https://forums.phpfreaks.com/topic/193825-get-a-table-from-html/#findComment-1020141 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.