Table cell width question

Reply

Join Date: Nov 2007
Posts: 35
Reputation: SergioQ is an unknown quantity at this point 
Solved Threads: 0
SergioQ SergioQ is offline Offline
Light Poster

Table cell width question

 
0
  #1
Jan 21st, 2008
So I am trying to do some sizing formating with my HTML code, and I did something that works but I need to make sure I didn't do anything bad that will come up and bite me later.

I essentially am creating a form to upload files and since I don't know the size of the Browse File element, I made the width of the column it's in super small. This way it would resize itself.

How bad of a thing am I doing?

Thanks ahead as always,

Sergio

<table width="400">
<tr>
	<td ALIGN="RIGHT" VALIGN="MIDDLE">
		Photo to Upload: 
	</td>	
	<td WIDTH="10" ALIGN="RIGHT" VALIGN="MIDDLE">
		<INPUT TYPE="file" NAME="photo">
	</td>	
</tr>
</table>
Reply With Quote Quick reply to this message  
Join Date: Jul 2004
Posts: 764
Reputation: DaveSW is on a distinguished road 
Solved Threads: 17
DaveSW's Avatar
DaveSW DaveSW is offline Offline
Master Poster

Re: Table cell width question

 
1
  #2
Jan 21st, 2008
Very bad ;-)
Some browsers may actually listen to you and not bother to expand it, so I would suggest you simply set the size of your input element instead...
HTML and CSS Syntax (Toggle Plain Text)
  1. <INPUT TYPE="file" NAME="photo" style="width: 50px;">
Then you won't have to worry about setting the cell width or what size the upload element will be!

Regards
Dave
Reply With Quote Quick reply to this message  
Join Date: Nov 2007
Posts: 35
Reputation: SergioQ is an unknown quantity at this point 
Solved Threads: 0
SergioQ SergioQ is offline Offline
Light Poster

Re: Table cell width question

 
0
  #3
Jan 22nd, 2008
Thank you for the solution. Don't have enough wokring knowledge of forms to realize that solution was possible. Obviously I should study more.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the HTML and CSS Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC