'') { $fp = fopen("refer.log","a"); if ($fp) { fwrite($fp,date('Y-m-d H:i').' '.$_SERVER['REMOTE_ADDR'].' '.$HTTP_SERVER_VARS['HTTP_REFERER']."\n"); fclose($fp); } } function startElement($parser, $name, $attrs) { global $insideitem, $tag, $title, $description, $link, $pubdt, $display_cnt; if ($insideitem) { $tag = $name; } elseif ($name == "ITEM") { $insideitem = true; $display_cnt++; } } function endElement($parser, $name) { global $insideitem, $tag, $title, $description, $link, $pubdt, $display_cnt, $max_display_cnt; if ($name == "ITEM" && $display_cnt < $max_display_cnt) { $description = str_replace(chr(226).chr(128).chr(153),'´',$description); // single tick mark $description = str_replace(chr(226).chr(128).chr(148),'',$description); $description = str_replace(chr(228).chr(152).chr(180),'"',$description); $description = str_replace(chr(195).chr(169),'é',$description); $description = str_replace(chr(194).chr(174),'®',$description); $description = str_replace(chr(172).chr(34),'',$description); $description = str_replace(chr(128).chr(147),'',$description); $description = str_replace(chr(233),'é',$description); // little e with right-leaning tick $description = str_replace(chr(180),'´',$description); // right-leaning tick $description = str_replace(chr(194),'',$description); // right-leaning tick $description = str_replace(chr(226),'',$description); // little a with hat printf("%s",trim($link),trim($title)); printf("%s","
| ". ($pubdt<>''?''.$pubdt.' -- ':""). trim($description)." |
xxxxxxxxxxxxxxxxxxxxxxxxxx $data xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"; } */ // Get time of year $mo = date('m'); if (in_array($mo,array('01','02','03','04'))) $msg = ' summer coming up'; else if (in_array($mo,array('05'))) $msg = ' summer almost upon us'; else if (in_array($mo,array('06','07','08'))) $msg = ' summer in full swing'; else if (in_array($mo,array('09','10'))) $msg = ' prices lowest in the fall'; else if (in_array($mo,array('11','12'))) $msg = ' spring just around the corner'; ?>