My host just switched off fopen and my php skills are lousy at best.

PLEASE help!

PHP Code:
$file WEATHER_FILE '.' $zip '.xml';
  if(!
file_exists($file) || filemtime($file) < time() - 3600) {
      
$this->data = @file_get_contents('http://xml.mydomain.com/rss?p=' $zip '&u=' $units['temp']);
      
$fp = @fopen($file'w');
      @
fwrite($fp$this->data);
      @
fclose($fd);
  }
  else 
$this->data = @file_get_contents($file);
  if(
strlen($this->data) <= 0) return;