Try this. You need to post the variable back to the script so that upon each page load, it can know what the previous value was.
<?php
$letter = 'A';
if (isset($_POST["letter"]))
{
$letter = $_POST["letter"];
$alphabet = array('A', 'B', 'C', 'D', 'E');
$get = array_search($letter, $alphabet);
if($get < (count($alphabet) - 1))
{
$get++;
}
else
{
$get = 0;
}
$letter = $alphabet[$get];
echo $letter;
}
?>
<form name="alphabet" method="post">
<input type="hidden" name="letter" value="<?php echo $letter ?>" />
<input type="submit" value="next" />
</form>
Edit: Have added a check on the index variable $get
to only increment if it is not at the end of the array, otherwise it should reset.