Hi, I'm getting the temperature value off of the Environment Canada website along with the icon filename, so I can display my own icons and temperature on my site. All this works and I can display the temperature but my conditional statements aren't working to display my icons. I'm new to PHP and I don't see why this is a problem: Code: <?php $url = "http://www.weatheroffice.gc.ca/city/pages/on-69_metric_e.html"; $ch = curl_init();//Initialise CURL curl_setopt($ch, CURLOPT_URL, $url);//Set the url curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);//We want it to return data curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, 100);//Of course, we don't want your script to run forever, so set a timeout $text = curl_exec($ch);//Execute and get the page
$exploded = explode('<p class="temperature">',$text);//Make an array of the part before and after the <title> tag $result = explode('<sup>',$exploded[1]);//Grab the part after the <title> tag, and split that too
$exploded2 = explode('<img id="currentimg" src="/weathericons/',$text);//Make an array of the part before and after the <title> tag $result2 = explode('.gif"',$exploded2[1]);//Grab the part after the <title> tag, and split that too