| Author |
wrapping issue
|
prajwala solanki
Greenhorn
Joined: Jul 17, 2007
Posts: 9
|
|
Hi, I have a problem with the wrap.. one of my <td> width is 150....but the content is like a big string without any spaces in between... so I wraped the content....but the cell width was expanding.. Here I am attaching the code just copy it and run...for your clear idea i used background colors..wrapping works fine but cell expanding??/ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <script type="text/javascript"> function toggleSection( secid ) { var sectionId = document.getElementById(secid); if (sectionId == null) return; if (sectionId.style.display == '') { sectionId.style.display = 'none'; } else { sectionId.style.display = ''; } } function toggleCoaCmt( cmtId ) { toggleSection('max_' + cmtId); toggleSection('min_' + cmtId); } </script> </head> <body> <form id="form1"> <table width="950" border="0" cellpadding="0" cellspacing="1" > <tr bgcolor="#E0E0E0"> <td> </td> <td width="225" bgcolor="#E0E0E0" class="datacellhead3" style="width:225px;word-wrap:break-word" wrap> test COA 3 (achoy2 19-Oct-2007 at 00:14:27 EDT) <br/> <div id="coa_rpt_cmt_6" class="comment"></div> </td> <td width="25" bgcolor="#E0E0E0" class="datacell">hello</td> <td width="80" bgcolor="#E0E0E0" class="datacell">01-Dec-2008</td> <td width="80" bgcolor="#E0E0E0" class="datacell"></td> <td width="90" bgcolor="#E0E0E0" class="datacell">Demonstrator</td> <td width="70" bgcolor="#E0E0E0" class="datacell">Recommended: Not Required</td> <td width="150" bgcolor="red" class="comment" wrap> <div id="max_Status_1" style="float:left;background-color:yellow;word-wrap:break-word;width:150px"> <a href="javascript:toggleCoaCmt('Status_1')" >[+]</a> testing123456789012345678901234567890123456... </div> <div id="min_Status_1" style="float:left;display:none;background-color:yellow;word-wrap:break-word;width:150px"> <a href="javascript:toggleCoaCmt('Status_1')" >[-]</a> testing123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890 (abcd1 19-Oct-2007 at 00:17:21 EDT) test (abcd1 19-Oct-2007 at 00:14:27 EDT) </div> </td> <td width="10" align="center" bgcolor="#E0E0E0" class="datacell">3</td> <td width="50" bgcolor="#E0E0E0" class="datacell" style="word-wrap:break-word">Melbourne</td> <td width="50" bgcolor="#E0E0E0" class="datacell">Vehicles Sales</td> <td width="50" bgcolor="#E0E0E0" class="datacell"></td> </tr> <tr> <td colspan="12" bgcolor="#E0E0E0"> </td> </tr> </table> </form> </body> </html>
|
 |
Eric Pascarello
author
Rancher
Joined: Nov 08, 2001
Posts: 15357
|
|
When you specify a width, you need to include units. Eric
|
 |
prajwala solanki
Greenhorn
Joined: Jul 17, 2007
Posts: 9
|
|
means .... like width="150px" i tried that one also....can you please run the code...and see the problem where its occuring ...because i am not so good in this alignment...with my knowledge i tried maximum possibilities... when you click [+] link you will see the cell expansion....
|
 |
prajwala solanki
Greenhorn
Joined: Jul 17, 2007
Posts: 9
|
|
|
Is there any possible way to fix width of a specific cell(mean i want to fix width of 6th column only)...so that i can fix this problem...
|
 |
 |
|
|
subject: wrapping issue
|
|
|