Jump to content

[SOLVED] Submit button not being shown


trilbyfish

Recommended Posts

For some reason when i open this page, the submit button isnt shown. When i use a html WYSIWYG editor, it shows the submit button.

 

<?php



// Table header.
echo '<table align="left" cellspacing="0" cellpadding="5" border ="1">
<tr>
    <td align="left"><b>Bay Number</b></td>
    <td align="left"><b>08:00 - 09:00 </b></td>
    <td align="left"><b>09:00 - 10:00 </b></td>
    <td align="left"><b>10:00 - 11:00 </b></td>
    <td align="left"><b>11:00 - 12:00 </b></td>
    <td align="left"><b>12:00 - 13:00 </b></td>
    <td align="left"><b>13:00 - 14:00 </b></td>
    <td align="left"><b>14:00 - 15:00 </b></td>
    <td align="left"><b>15:00 - 16:00 </b></td>
    <td align="left"><b>16:00 - 17:00 </b></td>
</tr>
';


// Fetch and print the record whice corresponds to the bay id from the 'edit' link that was clicked on the bookingtable page


if ($result) {
while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
echo ' <tr>

                <form action="editbay.php?id=' . $row['id'] . '" method="post">
        <td align="left">' . $row['baynumber']     . '</td> 

';

if (($row['08:00 - 09:00']) == "-")
{
echo '<td align="left"><select name="eight">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['08:00 - 09:00'] . '" selected="selected">' . $row['08:00 - 09:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="08:00 - 09:00" size="12" maxlength="30" readonly="true" value="' . $row['08:00 - 09:00'] . '" /></td>'; 
}'

';






if (($row['09:00 - 10:00']) == "-")
{
echo '<td align="left"><select name="nine">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['09:00 - 10:00'] . '" selected="selected">' . $row['09:00 - 10:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="08:00 - 09:00" size="12" maxlength="30" readonly="true" value="' . $row['09:00 - 10:00'] . '" /></td>'; 
}'

';






if (($row['10:00 - 11:00']) == "-")
{
echo '<td align="left"><select name="ten">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['10:00 - 11:00'] . '" selected="selected">' . $row['10:00 - 11:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="10:00 - 11:00" size="12" maxlength="30" readonly="true" value="' . $row['10:00 - 11:00'] . '" /></td>'; 
}'

';




if (($row['11:00 - 12:00']) == "-")
{
echo '<td align="left"><select name="eleven">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['11:00 - 12:00'] . '" selected="selected">' . $row['11:00 - 12:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="11:00 - 12:00" size="12" maxlength="30" readonly="true" value="' . $row['11:00 - 12:00'] . '" /></td>'; 
}'

';




if (($row['12:00 - 13:00']) == "-")
{
echo '<td align="left"><select name="twelve">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['12:00 - 13:00'] . '" selected="selected">' . $row['12:00 - 13:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="12:00 - 13:00" size="12" maxlength="30" readonly="true" value="' . $row['12:00 - 13:00'] . '" /></td>'; 
}'

';


if (($row['13:00 - 14:00']) == "-")
{
echo '<td align="left"><select name="thirteen">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['13:00 - 14:00'] . '" selected="selected">' . $row['13:00 - 14:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="13:00 - 14:00" size="12" maxlength="30" readonly="true" value="' . $row['13:00 - 14:00'] . '" /></td>'; 
}'

';


if (($row['14:00 - 15:00']) == "-")
{
echo '<td align="left"><select name="fourteen">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['14:00 - 15:00'] . '" selected="selected">' . $row['14:00 - 15:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="14:00 - 15:00" size="12" maxlength="30" readonly="true" value="' . $row['14:00 - 15:00'] . '" /></td>'; 
}'

';


if (($row['15:00 - 16:00']) == "-")
{
echo '<td align="left"><select name="fifteen">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['15:00 - 16:00'] . '" selected="selected">' . $row['15:00 - 16:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="15:00 - 16:00" size="12" maxlength="30" readonly="true" value="' . $row['15:00 - 16:00'] . '" /></td>'; 
}'

';

if (($row['16:00 - 17:00']) == "-")
{
echo '<td align="left"><select name="sixteen">
                <option value="-">-</option>
                <option value="' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '">' .$_SESSION['firstname']. ' ' .$_SESSION['surname']. '</option>
                <option value="' . $row['16:00 - 17:00'] . '" selected="selected">' . $row['16:00 - 17:00'] . '</option>
                </select>  
                </td>'; 
}
else 
{
echo
'<td align="left"><input type="text" name="16:00 - 17:00" size="12" maxlength="30" readonly="true" value="' . $row['16:00 - 17:00'] . '" /></td>'; 
}'



       </tr>
       <tr >    
                <td colspan="11" td align="middle">
                <input type="submit" name="submit" value="Submit"></td>
                <input type="hidden" name="submitted" value="TRUE" />
                <input type="hidden" name="id" value="' . $id . '" />

       </tr>
                








</form>
</table>


';

}


echo '</table>';

// Check if the form has been submitted.

?>

 

I have cut out most of the php code which isnt related to the submit button.

 

I would be very glad if you could help.

 

Thanks in advance.

Link to comment
https://forums.phpfreaks.com/topic/101866-solved-submit-button-not-being-shown/
Share on other sites

I have cut out most of the php code which isnt related to the submit button.

 

Are you sure about that? Looks like a full php page to me...

 

Can you just give the parsed php. Just the html? And cut EVERYTHING out except the submit button.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.