| px | top | add code | search | signup | login | help |
<?
$url = "http://www.klikbca.com/website/indo/price_rate/exchange_rate.html";
$html_start = "<table border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"100%\">"; // Start html code
$html_end = "<!--- Mulai proses untuk yang BN----->"; // End html code
// Start grabber of content
ini_set('max_execution_time', '0');
flush ();
$fd= fread(fopen("$url", "r"), 16384);
if ($fd)
{
$a = strpos($fd, "$html_start");
$b = strpos($fd, "$html_end");
$c = $b-$a;
$show = Substr($fd, $a, $c);
}
// Editing html code
$show = ereg_replace("<table border=\"0\" cellpadding=\"2\" cellspacing=\"2\" width=\"100%\">", "<table border=0 cellspacing=1 cellpanding=0 width=200>", $show);
// Show finish code
echo "<h2>Exchange Rates : \$US-Rp</h2>\n";
echo $show;
flush ();
?>
Comments or questions?
PX is running PHP 5.2.11
Thanks to Miranda Productions for hosting and bandwidth.
Use of any code from PX is at your own risk.