bugfix for handling tickerforum.org
This commit is contained in:
		
							
								
								
									
										12
									
								
								fullrss.php
									
									
									
									
									
								
							
							
						
						
									
										12
									
								
								fullrss.php
									
									
									
									
									
								
							| @@ -41,9 +41,15 @@ | ||||
|         return file_get_contents($cachefile); | ||||
|     } | ||||
|  | ||||
|     $url=$_GET["url"]; | ||||
|     $feed=new SimpleXmlElement(file_get_contents($url)); // read feed into object | ||||
|  | ||||
|     $url=$_GET["url"];       | ||||
|     $ch=curl_init(); // 8 Apr 25: market-ticker.org wants a user agent set | ||||
|     curl_setopt($ch, CURLOPT_URL, $url); | ||||
|     curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows NT 6.2; WOW64; rv:17.0) Gecko/20100101 Firefox/17.0"); | ||||
|     curl_setopt($ch, CURLOPT_HEADER, 0); | ||||
|     curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); | ||||
|     $feed=new SimpleXmlElement(curl_exec($ch)); // read feed into object | ||||
|     curl_close($ch); | ||||
|      | ||||
|     // type 1 | ||||
|     foreach ($feed->item as $entry) // fix up each entry | ||||
|     { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user