* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.ocbcnisp.com/?opt=kurs&lang=1'); $pecah = explode('<table width="618" border="0" cellpadding="0" cellspacing="0" id="tabel_kurs">', $url); $pecah2 = explode('</table>', $pecah[1]); echo "<table border=1>"; print_r($pecah2[0]); echo "</table>";
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.btn.co.id/Layanan/Kurs-Valuta-Asing.aspx'); $pecah = explode('<strong><font color="#FFFFFF">KURS</font></strong></font></center></td><td width="70" bgColor="#005595"><center><font face="Verdana" color="#000000" size="1">', $url); $pecah2 = explode('</table>', $pecah[1]); echo '<table border=1><td bgColor="#005595"><font color="#FFFFFF">KURS</font></td><td bgColor="#005595"><font color="#FFFFFF">Jual</font></td>'; print_r($pecah2[0]); echo "</table>";
* This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); //curl_setopt($data, CURLOPT_AUTOREFERER, true); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bri.co.id/bri_kurs.php'); $pecah = explode('<h1>KURS BRI</h1>', $url); $pecah2 = explode("<div id='rates-container'>", $pecah[1]); echo "<br>---------------------------------------------------------------------<br>"; echo $pecah2[1]; echo "<br>---------------------------------------------------------------------<br>";
* * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // isi mandiri.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bankmandiri.co.id/resource/kurs.asp'); $pecah = explode('<table class="tbl-view" cellpadding="0" cellspacing="0" border="0" width="100%">', $url); $pecah2 = explode('</table>', $pecah[1]); $pecah3 = explode('<th> </th>', $pecah2[0]); $pecah4 = explode('<td> </td>', $pecah3[2]); echo "<br>"; echo "<table border='1'>"; echo "\n <tr>\n <td>Mata Uang</td>\n <td>Symbol</td>\n <td>Beli</td>\n <td>Jual</td>\n \n </tr>"; echo $pecah4[0]; echo $pecah4[1]; echo $pecah4[2]; echo $pecah4[3]; echo $pecah4[6]; echo $pecah4[7]; echo "</table>";
* This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.banksinarmas.com/id/i.php?id=exchangeRates'); $pecah = explode('<table width="100%" cellpadding="0" cellspacing="1" align="center" bgcolor="#E1E3E3">', $url); $pecah2 = explode(' </tr> <tr>', $pecah[1]); echo '<table border=1>'; print_r($pecah2[0]); echo "</table>";
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('www.bankmega.com/rates/kurs.php'); $pecah = explode('<table width="158" height="201" border="0" cellpadding="0" cellspacing="0">', $url); $pecah2 = explode('</table>', $pecah[1]); echo "<table border=1>"; print_r($pecah2[0]); echo "</table>";
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.panin.co.id/content.asp?idm=k&idsm=6&id=20'); $pecah = explode('<table cellpadding=1 cellspacing=1 border=0 width=100% class="bggrey1">', $url); $pecah2 = explode('</table>', $pecah[1]); echo "<table border=1>"; print_r($pecah2[0]); echo "</table>";
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.danamon.co.id/Home/AboutDanamon/Kurs/tabid/272/language/en-US/Default.aspx'); $pecah = explode('<table class="kurs" height="193" width="510" style="font-size: 11px">', $url); $pecah2 = explode('</table>', $pecah[1]); echo "<table border=1>"; print_r($pecah2[0]); echo "</table>";
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.banksaudara.com/'); $pecah = explode('<table cellspacing="1" class="tableModule" width="90%" align="center">', $url); $pecah2 = explode('</table><br />', $pecah[1]); echo "<table border=1>"; print_r($pecah2[0]); echo "</table>";
* This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // isi ortax.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://ortax.org/ortax/?mod=kurs'); $pecah = explode('<table id="table" width="100%" border="0" cellpadding="2" cellspacing="0" >', $url); $pecah2 = explode('</table>', $pecah[1]); echo "<table border='1'>"; echo $pecah2[0]; echo "</table>";
* @author tommy * @copyright 2013 Tommy A. Surbakti tommy@surbakti.net * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bankekonomi.co.id/1/2/home/kurs-mata-uang'); $pecah = explode('<div class="hsbcStyleContent02">', $url); $pecah2 = explode('</div>', $pecah[1]); print_r($pecah2[0]);
* You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // isi bca.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bankmaspion.co.id/Kurs.zul'); $pecah = explode('Bank Note', $url); $pecah2 = explode('<a href=', $pecah[1]); $kambing = str_replace('</div>', ' ', $pecah2); $test = strip_tags($kambing[0]); $pecah3 = explode("Last Update", $test); preg_match_all('/<div id="(.*?)" style="display:none">(.*?)<\\/div>/si', $pecah2[0], $output_array); echo "<table border='1'>"; echo "<tr><td>Simbol</td><td>Mata Uang</td><td>BELI</td><td>JUAL</td></tr>"; echo "<tr>"; echo "<td>" . $output_array[2][5] . "</td>"; echo "<td>" . $output_array[2][6] . "</td>"; echo "<td>" . $output_array[2][7] . "</td>"; echo "<td>" . $output_array[2][8] . "</td>"; echo "</td>"; echo "</table>";
* License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // isi bca.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bca.co.id/id/biaya-limit/kurs_counter_bca/kurs_counter_bca_landing.jsp'); $pecah = explode('<tr bgcolor="#dee9f2" style="text-align:center;">', $url); $pecah2 = explode('<td><strong>Beli</strong></td>', $pecah[1]); $pecah3 = explode('<table width="200" border="1" style="float:left;">', $pecah2[1]); echo "<table border='1'>"; echo "<tr><td>KURS</td><td>JUAL</td><td>BELI</td></tr>"; echo $pecah3[0]; echo "</table>";
* @author tommy * @copyright 2013 Tommy A. Surbakti tommy@surbakti.net * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.perdania.co.id/index.php/rate'); $pecah = explode('<td valign="top" colspan="2" align="left" height="20" background="http://www.perdania.co.id/app/webroot/img/title/bg.gif"><img src="http://www.perdania.co.id/app/webroot/img/title/rate_tt.gif" border="0" /></td>', $url); $pecah2 = explode('</table></td>', $pecah[1]); print_r($pecah2[0]);
* @copyright 2013 Tommy A. Surbakti tommy@surbakti.net * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // chinatrust.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.chinatrust.co.id/'); $pecah = explode('<div class="textFooter" style="width:170px; margin-left:auto; margin-right:auto;">:', $url); $pecah2 = explode('Rates are subject to change without prior notice. For Bank Notes, please consult with customer service.', $pecah[1]); print_r($pecah2[0]);
* * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_HTTPHEADER, array('Content-Type: application/x-www-form-urlencoded; charset=UTF-8')); curl_setopt($data, CURLOPT_ENCODING, 'gzip,deflate'); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bukopin.co.id/'); $pecah = explode("<span id='kurs'>", $url); $pecah2 = explode('</span>', $pecah[1]); print_r($pecah2[0]);
* @author tommy * @copyright 2013 Tommy A. Surbakti tommy@surbakti.net * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bankmayapada.com/index.php?page=product&t=kurs'); $pecah = explode('<table width="300" cellpadding="0" cellspacing="1">', $url); $pecah2 = explode('</table></td></tr></table>', $pecah[1]); print_r($pecah2);
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE * License as published by the Free Software Foundation; either * version 3 of the License, or any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU AFFERO GENERAL PUBLIC LICENSE for more details. * * You should have received a copy of the GNU Affero General Public * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ // file bi.php function fungsiCurl($url) { $data = curl_init(); curl_setopt($data, CURLOPT_RETURNTRANSFER, 1); curl_setopt($data, CURLOPT_URL, $url); curl_setopt($data, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6"); $hasil = curl_exec($data); curl_close($data); return $hasil; } $url = fungsiCurl('http://www.bi.go.id/web/id/Moneter/Kurs+Bank+Indonesia/Kurs+Transaksi/'); $pecah = explode('<td valign="top" align="center"><font size="-1" face="verdana,arial" ><b>Graph</b></font></td>', $url); $pecah2 = explode("<IMG SRC='/biweb/Resources/images/graph.gif' border=0 alt='Grafik Time Series'>", $pecah[1]); echo "<table border='1'>"; print_r($pecah2[21]); print_r($pecah2[6]); echo "</table>";