Extraction LeBonCoin

coviauxj51100 -  
heyquem Posted messages 808 Status Member -
Hello,

I am currently developing a project with a friend and I need your help!
I would like to know how to extract information (including the image URLs) from a leboncoin advertisement given an advertisement URL.

PHP? JavaScript?

Thank you in advance for your help.

Configuration: Windows XP / Safari 536.11

2 answers

  1. Blunderer Posted messages 273 Registration date   Status Member Last intervention   83
     
    PHP :
    <?php $homepage = file_get_contents('http://www.example.com/'); echo $homepage; ?>

    https://www.php.net/manual/en/function.file-get-contents.php
    --
    Now, I am.
    1
    1. coviauxj51100
       
      This indeed gives me a table, but how can I search within this table (for example, I'm looking for the string "loyer"), I've tried with Search Array but it doesn't work. I would like it to return the row number of the table.

      Thank you
      0
    2. Blunderer Posted messages 273 Registration date   Status Member Last intervention   83
       
      ```php print_r($homepage); ```
      0