
02-07-2006, 15:41
|
|
|
|
חבר מתאריך: 17.05.05
הודעות: 7,321
|
|
|
הבדל ברוחב בין התג DIV ל-TABLE (כן...שוב >> )
תסתכלו בתמונה:
https://2006-uploaded.fresh.co.il/2...02/43619658.jpg
תראו שיש הבדלים בצד שמאל בין הטבלה (שנמצאת למטה) לבין ה-DIV שנמצא למעלה (איפה שכתוב "ברוך הבא ללוח...").
ניסיתי דברים שונים עם margin, עם align לטבלה וכדו' ולא עבד. הרוחב לא משתנה לטבלה עד הסוף....למרות שקבעתי לטבלה רוחב מקסימלי - 100 אחוז. לפחות שהטבלה תהיה באמצע העמוד אם היא לא הולכת 100 אחוז....אבל גם זה לא ...
איך אני עושה לשניהם 100 אחוז רוחב?
זה הקוד HTML של כל העמוד:
קוד:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" " http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html dir='rtl' xml:lang="en" lang="en" xmlns=" http://www.w3.org/1999/xhtml">
<head>
<script type='text/javascript'></script>
<!--Switch.This.For.User.Redirection-->
<style type='text/css' media="all">@import url("ad_css.css");</style>
</head>
<body>
<!--IMPORTANT ; Do NOT remove!--><div class='MainWrapper'><!--IMPORTANT ; Do NOT remove!-->
<div class='logo'>ברוך בואך ללוח הבקרה למנהלים של Dor's Website!</div><br />
<table class='table-normal' cellspacing='1' cellpadding='4' align='center'>
<tr class='table-tr-head'><td colspan='4'>משתמשים המחוברים ללוח הבקרה למנהלים:</td></tr>
<tr class='table-tr-subhead'><td>מס' משתמש</td><td>שם משתמש</td><td>מספר IP</td><td>פעילות אחרונה ב:</td></tr>
<tr class='table-tr'><td>1</td><td>Dor</td><td>217.132.12.131</td><td>1151843575</td></tr>
</table>
<br /><br /><br /><div align='center' class='bottom-links'><a href='http://dor.friendz-zone.net/admincp.php?act=idx'>עמוד ראשי</a></div>
<!--IMPORTANT ; Do NOT remove! End of MainWrapper--></div><!--IMPORTANT ; Do NOT remove!-->
<div align='center' style='direction:ltr;'>© Copyright Dor Marom. All rights reserved.</div>
</body>
</html>
זה הקוד CSS (לא הכל, אלא הקוד החיוני לאשכול זה):
קוד:
html { overflow-x: auto; }
body
{
background-color:transparent;
color:black;
font-family:Verdana, Arial, Helvetica, sans-serif;
font-weight:normal;
font-size:13px;
text-align:right;
direction:rtl;
margin:2px 2px 2px 2px;
padding:0px;
}
table, tr, td
{
font-family: Verdana, Arial, Tahoma, sans-serif;
font-size: 11px;
color: #000;
margin:auto;
}
.logo
{
padding: 4px 4px 4px 4px;
background-color:#d7e4f3;
color:black;
font-size:16px;
font-weight:bold;
border: 1px solid black;
vertical-align:middle;
z-index:100; /* makes sure nothing will be above the logo */
text-align:right;
width: 100%;
margin:0;
}
.table-normal
{
margin:0;
width:100%;
border: 1px solid black;
color:black;
background-color:#cfcfd1;
}
.table-tr-head
{
color:black;
background-color:#fffedf;
font-weight:bold;
font-family: verdana, helvetica, sans-serif;
width:100%;
}
.table-tr-subhead
{
color:black;
background-color:#e8e8e8;
font-weight:normal;
font-family: verdana, helvetica, sans-serif;
}
.table-tr
{
color:black;
background-color:#fafafa;
font-weight:normal;
font-family: verdana, helvetica, sans-serif;
}
כדי שיהיה לכם יותר נוח להיסתכל בקוד תעתיקו אותו ל-Notepad....
* אני לא יכול להביא את הקישור לעמוד, כי ממילא לא תצליחו להיכנס בגלל שזה לוח הבקרה למנהלים ולא לאורחים \ משתמשים רגילים.
אם יש צורך בפרטים נוספים אני אביא רק תגידו...
תודה..
|