php - curl_init and curl_exec: extract table? -


hey guys, i'm new curl - i've never used before. if paste following 2 lines inside of sidebar ...

<?php     $objcurl = curl_init("http://www.domain.com/hptool/weather_v1.php?cid=43x1351&l=en");     curl_exec($objcurl); ?> 

...i 2 divs , table inserted page. there method can kind of inspect gets loaded curl_init function? want specific stuff on page inserted , not everything? e.g. want insert table not 2 divs inserted page.

i know hide them css, i'm curious.

save result string instead of outputting it.

$url = 'http://www.domain.com/hptool/weather_v1.php?cid=43x1351&l=en';  $curl = curl_init(); curl_setopt($curl, curlopt_url, $url); curl_setopt($curl, curlopt_returntransfer, true); curl_setopt($curl, curlopt_header, false);  $str = curl_exec($curl); 

now can pull whatever need out of $str , display that.

first place should go the documentation how use function/library.


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -