Wednesday, February 14, 2018

php - Parsing HTML element into parts

I'm trying to parse the following code:






Essentially what I need is:



Array
(

[0] => [1] => border="0"
[2] => cellpadding="0"
[3] => cellspacing="0"
[4] => height="100%"
[5] => width="100%"
[6] => id="bodyTable"
[7] => style="table-layout: fixed;max-width:100% !important;width: 100% !important;min-width: 100% !important;
)



However when doing this with a simple explode(" ", $str); I'm getting the "style" split up too, is there a simple way to parse this and loop through it?

No comments:

Post a Comment

plot explanation - Why did Peaches' mom hang on the tree? - Movies & TV

In the middle of the movie Ice Age: Continental Drift Peaches' mom asked Peaches to go to sleep. Then, she hung on the tree. This parti...

Blog Archive