General discussion
Scrape DIV class with PHP and echo it

Hello I have my code that scrapes the whole html of a page. But I need to scrape ONLY specific DIV class


Can someone help me


I would like to scrape this class HTML span3 height-325


this is my code


<?php

header("Content-Type: text/plain"); // We choose to display the content as plain text

$ch = curl_init("www.trade-ideas.com/ticky/ticky.html?symbol=amzn");
curl_setopt($ch, CURLOPT_HEADER, 0);
$response = curl_exec($ch); // Running the request

if (curl_error($ch)) {
echo curl_error($ch); // Displaying possible errors from the request
} else {
echo $response; // Displaying the content of the response
}

curl_close($ch);
?>

Hello I have my code that scrapes the whole html of a page. But I need to scrape ONLY specific DIV class Can someone help me I would like to scrape this class HTML span3 height-325 this is my code ```` &lt;?php header(&quot;Content-Type: text/plain&quot;); // We choose to display the content as plain text $ch = curl_init(&quot;www.trade-ideas.com/ticky/ticky.html?symbol=amzn&quot;); curl_setopt($ch, CURLOPT_HEADER, 0); $response = curl_exec($ch); // Running the request if (curl_error($ch)) { echo curl_error($ch); // Displaying possible errors from the request } else { echo $response; // Displaying the content of the response } curl_close($ch); ?&gt; ````
37
0
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft