Forum Moderators: open

Message Too Old, No Replies

form lineup

         

Kysmiley

12:16 am on Dec 17, 2004 (gmt 0)

10+ Year Member



i cant seem to get my form to l;ine up correct it is set to center and the top is fine but the bottom I want the text for the three inputs to line up directly on the top right of the input boxes. here is the code i sure hope someone can help me. i had it looking good and then all of a sudden it went cafooy and i dont or cant see why
Pat
#######################
<center>
<tr>
<td><input type="radio" name="messagetype" value="Complaint">Complaint <input type="radio" name="messagetype" value="Problem">Problem
<input type="radio" checked name="messagetype" value="Suggestion">Suggestion
<input type="radio" name="messagetype" value="Praise">Praise</td>
</tr>
<p>Please help us direct your feedback by selecting a catagory you would like to comment on?</p>
<tr>
<td><select name="department" size="1">
<option value="none">Select a Department</option>
<option value="Web Site">Web Site</option>
<option value="Company">Company</option>
<option value="Products">Products</option>
<option value="Artists">Artists</option>
<option value="Employee">Employee</option>
<option value="Customer_service">Customer Service</option>
</select></td>
</tr>

<p>Enter your comments in the space provided below:</p>
<tr><? echo "<font color='red'>$error3</font>";?><br>
<td><textarea name="suggestion" value="<? echo $_POST['suggestion'];?>"rows="10" cols="42"></textarea></td>
</tr>
<p>Tell us how to get in touch with you:</p>

<table>
<tr><td>Name:<? echo "<font color='red'>$error1</font>";?><br>

<input type="text" size="35" maxlength="256" value="<? echo $_POST['name'];?>" name="name" ></td>
</tr>
<tr>
<td>E-Mail:<? echo "<font color='red'>$error2</font>";?>

<input type="text" size="35" maxlength="256" value="<? echo $_POST['email'];?>" name="email"></td>
</tr>
<tr><td>Telephone:<br>
<input type="text" size="35" maxlength="256" value="<? echo $_POST['telephone'];?>" name="telephone"></td>
</tr>
<tr>
<td>Please contact me as soon as possible regarding this matter:
<td><input type="checkbox" name="contactrequested" value="1">

</tr>
</table>
<input name="submit_form" type="Submit" value="Submit_form">
<input type="reset" value="Clear">
</form></center><br>
</div>

rocknbil

2:20 am on Dec 17, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Ky your table rows and cells are all over the place.

<center>
<tr>
<td><input .....

The center tag is depricated (but that's not the problem) as anything you want to center has an align=center attribute.

With that out of the way, immediately following your center tag is a table row. Nothing can come between table rows except comments. So you should start off with

<table align="center">
<tr><td><input . . . .

This follows throughout:

</tr>
<p>Please help us direct your feedback by selecting a catagory you would like to comment on?</p>
<tr>

(Paragraph between rows)

<td><input type="checkbox" name="contactrequested" value="1">
</tr>

This one is probably going to squeak by: the closing </td> tag is actually optional but a good way to get good at tables fast is to
1. Draw a border until you see what's up
2. Be extremely retentive about row and cell pairs.

So. Make sure your tables are like this:

<table align="center" border="1">
<tr><td colspan="2">two columns</td></tr>
<tr><td>col 1</td><td>col 2</td></tr>
</table>

Indent it how you like, but make sure everyone is paired off. Get the content out from between the rows and draw a border so you can see what you're doing and I'll bet your problem goes away, hope this helps.

Kysmiley

4:31 am on Dec 17, 2004 (gmt 0)

10+ Year Member



thanks rocknBill, it sure does help. for some reason it was all looking good then during some of the php editing i did somthing that messed it all up so the text above the fields is in the center above them and not on the left side above them as I would like to see. If i removed the center it would put everyhting on the far left and that would look worse I was thin king of using CSS but was hoping not to for the form table
Pat