- file_get_contents: documentation ( source)
- explode: documentation ( source)
- htmlspecialchars: documentation ( source)
<?php
$counter = 0;
$counter2 = 20;
$content = file_get_contents("THEURL");
// sleep(2);
while($counter < $counter2)
{
$counter++;
$first_step = explode( '<h2 class="rgs">' , $content );
$second_step = explode("</h2>" , $first_step[$counter] );
// echo $second_step[0];
$link[$counter] = htmlspecialchars($second_step[0]);
// echo "$link";
// echo "<br>";
}