codice:
 //-------------- Crea il codice JS per il populate
 function createSinglePopulate($rssName) {
  ob_start()?>
  <script language="JavaScript" type="text/javascript">
  <!--
   var marqueecontent<? print $rssName ?>=document.getElementById("txta<? print $rssName ?>").value;
	 populate<? print $rssName ?>(document.getElementById('<? print $this->place[$rssName] ?>'));
  //-->
  </script><?
 $jsCode = ob_get_contents();
 ob_end_clean();
 return $jsCode;
 } // function createSinglePopulate($rssName)

 function startElement($parser, $name, $attrs) {
  global $curTag;
  $curTag .= "^$name";
 } // function startElement($parser, $name, $attrs)

 function endElement($parser, $name) {
  global $curTag;
  $caret_pos = strrpos($curTag,'^');
  $curTag = substr($curTag,0,$caret_pos);
 } // function endElement($parser, $name)

 function characterData($parser, $data) {
  global $curTag;
  global $sTitle, $sLink, $sDescription;
  $titleKey = "^RSS^CHANNEL^TITLE";
  $linkKey = "^RSS^CHANNEL^LINK";
  $descKey = "^RSS^CHANNEL^DESCRIPTION";
  if ($curTag == $titleKey) {
    $sTitle = $data;
  }
  elseif ($curTag == $linkKey) {
    $sLink = $data;
  }
  elseif ($curTag == $descKey) {
    $sDescription = $data;
  }

  global $arItems, $itemCount, $keyProcessed;
	
  $itemTitleKey = "^RSS^CHANNEL^ITEM^TITLE";
  $itemLinkKey  = "^RSS^CHANNEL^ITEM^LINK";
  $itemDescKey  = "^RSS^CHANNEL^ITEM^DESCRIPTION";
	
	if (! isset($this->arItems[$itemCount])) {
	 $this->arItems[$itemCount] = new xItem();
   $this->arItems[$itemCount]->xTitle       = "";
   $this->arItems[$itemCount]->xLink        = "";
	 $this->arItems[$itemCount]->xDescription = "";	 
	 $keyProcessed = 0;
	} // if (! isset($this->arItems[$itemCount]))
	
  if ($curTag == $itemTitleKey) {
    $this->arItems[$itemCount]->xTitle       = $data;
		$keyProcessed++;
  } // if ($curTag == $itemTitleKey)
  elseif ($curTag == $itemLinkKey) {
    $this->arItems[$itemCount]->xLink        = $data;
		$keyProcessed++;
  } // elseif ($curTag == $itemLinkKey)
  elseif ($curTag == $itemDescKey) {
		$this->arItems[$itemCount]->xDescription = $data;
		$keyProcessed++;
  } // elseif ($curTag == $itemDescKey)
	
	//----------- Prossimo item se tutti i tre campi sono
	//            stati trattati
	if ($keyProcessed == "3") {
	 $itemCount++;
	} // if ($keyProcessed == "3")
 } // function characterData($parser, $data)
 
} // class RssObjects
?>
Fine