I deduce the information from the file as a whole, but how can I output a variable from the file?

require ('data/site_blok.php'); $url = $sym_link . 'data/site_blok.php'; function contact_details($url){ $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)'); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5); curl_setopt($ch, CURLOPT_TIMEOUT, 5); $data = curl_exec($ch); $httpcode = curl_getinfo($ch, CURLINFO_HTTP_CODE); curl_close($ch); return ($httpcode>=200 && $httpcode<300) ? $data : false; } echo contact_details($url) ; 

file

 <? $cachen = "2"; $site_name = "Иван-чай"; $slogan = "полезные свойства, противопоказания"; $adm_name = "admin"; ?> 
  • What other variable? explain what you want - teran
  • information will be displayed on 10 sites from one file therefore via variables - Petro Boyko
  • It seems to me that you do not really imagine what curl is doing here. or i still don’t understand what you want to do with it. - teran
  • surl parsit halyard from server friend - Petro Boyko
  • if I understand correctly, just try var_dump (contact_details ($ url)); there will be all the information that is returned from the remote server - StereoFlo

0