Click to See Complete Forum and Search --> : [RESOLVED] scrollable table


nuttynibbles
05-21-2007, 06:55 AM
here is code i used to display info frm database. the problem is if I were to display all the columns, the table gets too big and the web template looks funny. can i do a scrollable table whereby if it gets too many columns, user can scroll to the left or right..

echo "<table width='640' height='2' border='0' align='center' cellpadding='1' cellspacing='0' >";
//set heading background color
echo "<tr bgcolor='#E8E8E8'>";
//column customer id
echo "<td width='60' align='left'><strong><span class='style7'> ID
</span></strong>
</td>";
//column customer name
echo "<td width='60' align='left'><strong><span class='style7'>NAME
.......

echo "<td align='left'>";
echo $userID;
echo "</td>";
//print out list of customer
echo "<td align='left'>";
echo"<font size=2>$firstName $lastName</font>";
echo "</td>";

......

nuttynibbles
05-21-2007, 09:07 AM
I solved it .. just put a <div style="width: 650px; height: 300px; overflow-x: auto; overflow-y: auto;">

bradgrafelman
05-22-2007, 12:30 AM
Don't forget to mark this thread resolved.