Announcement

Collapse
No announcement yet.

cURL Multiple entities

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • cURL Multiple entities

    Hi guys, im trying to scrape some data using cURL from a site, with classes being the point of reference.

    2 things im experiencing :

    1) If more than 1 entity exists under the same class, how can i only take the 1st reference of this?

    and

    2) How can i get a heading text from a class, i've tried the following :

    <?php
    foreach($html->find('.masthead-detail h4') as $games_won)
    echo $games_won->plaintext;
    ?>

    But this never worked.

    Any suggestions would be great!

    Many thanks,
    Eddy
Working...
X