Quick Ajax Project – Form
October 30th, 2009
I need to have a script created to load a function without the page refreshing.
Function:
User inputs website and clicks generate. I need to have the image generated display below it.
This is very simple and should not take long.
Code:
<?php
if (!empty($_POST['siteurl'])) {
$url=’http://www.shrinktheweb.com/xino.php?embed=1&STWAccessKeyId=363351c053391cb&stwsize=xlg&stwUrl=’.$_POST['siteurl'];
echo ‘<img src=”‘,$url,’” />’;
}
?>
<form method=”post”>
<input type=”text” name=”siteurl” />
<input type=”submit” value=”Submit” />
</form>
Please PM questions or demos.



