Wierd... a reboot says nevermind... guess the code was right. Just so you know, though:
<?
// calllog.php
// include auth and nav
include("auth.php");
include("connect.php");
// begin content
include("userinfo.php");
include("nav.php");
$getcallers = mysql_query("select distinct caller from calllog",$db);
$getphone = mysql_query("select distinct phone from calllog where caller = '" . $caller . "'",$db);
$keepacall = "<input type=\"hidden\" name=\"takeacall\" value=\"1\" />";
$keepacaller = "<input type=\"hidden\" name=\"caller\" value=\"$caller\" />";
$keepaphone = "<input type=\"hidden\" name=\"phone\" value=\"$phone\" />";
$keeptimein = "<input type=\"hidden\" name=\"timein\" value=\"$timein\" />";
$br = "<br />";
?>
<h1>Welcome to the M&C Call Log</h1>
<form method="post" action="<?php echo $PHP_SELF ?>">
<?php
if ($thiscaller){
//-------------------------CallLog-------------
echo $keepcaller;
echo $keepaphone;
?>
Caller: <?php echo $caller;
echo $br; ?>
Phone Number: <?php echo $phone;
echo $keeptimein;
// other input fields later ?>
<?php
//--------------------end-CallLog------------
} else {
if ($getaphone) {
//--------------Get-Phone-Number------------------
echo $keeptimein;
echo $keepcaller;
echo $caller;
?>
<br /><br />Select a phone number:
<select name="phone">
<option></option>
<?php while ($myrow = mysql_fetch_array($getphone)){ ?>
<option><?php echo $myrow["phone"] ?></option><?php } ?>
</select>
<input type="submit" name="thiscaller" value="Insert into Log" />
<?php
//------------------end-Get-Phone-Number---------------
} else {
if ($takeacall) {
// someone is calling, we're sure of that
?>
Name of person calling:
<?php if ($nevercalled) {
//-----------------------Never-Called---------------
echo $keeptimein;
?>
<br />
Please enter caller's name with last name first (i.e. "Smith, John Q.")<br />
<input type="text" name="caller" /><br />
Please enter phone number with numbers only (i.e. "8002211760", no dashes or parentheses)<br />
<input type="text" name="phone" /><br />
<input type="submit" name="thiscaller" value="Insert Into Log" />
<?php
//--------------------end-Never-Called--------------
} else {
//-------------------Get-Name----------------
echo $keeptimein
?>
<select name="caller">
<option></option>
<?php while ($myrow = mysql_fetch_array($getcallers)) { ?>
<option><?php echo $myrow["caller"] ?></option><?php } ?>
</select>
<?php echo $keepacall ?>
<input type="submit" name="getaphone" value="Find This Person" />
<br />
<br />
<br />
<input type="submit" name="nevercalled" value="Caller Is Not In The List" />
<?php }
//---------------------end-Get-Name---------------
?>
<?php } else {
// ------------Starter------------------
// This form starts the call
?>
<input type="hidden" name="timein" value="<?php echo date('Y-m-d H:i:s') ?>" />
<input type="submit" name="takeacall" value="Take a Call" />
<?php
// -----------end-Starter----------------
} } }?>
</form>