Location: PHPKode > scripts > Feed Finder > indexajax.php
<?
/*
 * index.php Sample file
 * Author: Manel Zaera (hide@address.com)
 * Description: Singleton class to find syndication feeds in
 * a website.
 * Creation date: 2007-11-06
 *
 * This work is published under the GPL license (http://www.gnu.org/copyleft/gpl.html)
 *
 */
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">

<head>

<title>FeedFinder Sample</title>
<script type="text/javascript" src="prototype.js"></script>
<script type="text/javascript" src="rico.js"></script>

<!-- Dependency --> 
<script type="text/javascript" src="yui/build/yahoo/yahoo-min.js" ></script>

<!-- Event source file -->
<script type="text/javascript" src="yui/build/event/event-min.js" ></script>

<script type="text/javascript">
var ajaxSubmit = function(e) {
	$('rescerca').innerHTML = 'Working...';
	var url = $('url').value;
	var options={parameters: 'url='+url,method: 'post'};
	ajaxEngine.sendRequest('FeedFinder',options);
}

YAHOO.util.Event.addListener('cerca',"click",ajaxSubmit);
</script>

</head>
<body>
<form id="frmfindfeed" name="frmfindfeed">
<fieldset>
<label for="url">URL:</label>
<input type="text" size="100" maxlenght="255" name="url" id="url"/>
<input type="button" id="cerca" name="cerca" value="Cerca"/>
</form>
<div id="rescerca">
</div>
<!-- AJAX -->
<script type="text/javascript">
	ajaxEngine.registerRequest('FeedFinder','targetfrmajax.php');
	ajaxEngine.registerAjaxElement('rescerca');
</script>

</body>
</html>
Return current item: Feed Finder