Note that there are some explanatory texts on larger screens.

plurals
  1. POWhat is the best way to create this table layout? (image attached)
    primarykey
    data
    text
    <p>I want to create an html table that is best supported on all browsers, and that is w3c compliant. The table shall consist 3-4 elements in it:</p> <ol> <li><p>Text in the blue area - the text might be (a) shown as an image (so I can use nicer fonts, and I'll know for sure that all browsers display it the same way), or (b) might be real text (which would load faster), I haven't decided it.</p></li> <li><p>Background image - according to the above decision, either (a) one background image that would cover both blue and pink parts, or (b) just the pink area, while the blue area would just use css background, and I'll write the text inside. </p></li> <li><p>Text that would be positioned exactly where the yellow area is.</p></li> <li><p>An image that would be positioned exactly where the green area is.</p></li> </ol> <p><img src="https://i.stack.imgur.com/Qp6of.jpg" alt="example"></p> <p>Are the following codes for each of the a/b options are good enough? </p> <p>Option A:</p> <pre><code>&lt;table width="700" align="center" border="0" cellspacing="0" cellpadding="0"&gt; &lt;tr&gt; &lt;td height="680" style="background-image: url(bgimg.jpg)";&gt; &lt;div style="width: 150px; height: 70px; margin-top: 280px; margin-left: 520px; text-align: center; background-color: #FF0;" &gt; text &lt;/div&gt; &lt;div style="width: 400px; height:40px; margin-top:242px; margin-left:18px; background-color:#063;"&gt;image&lt;/div&gt; &lt;/td&gt; &lt;/tr&gt; </code></pre> <p></p> <p>Option B:</p> <pre><code>&lt;table width="700" align="center" border="0" cellspacing="0" cellpadding="0"&gt; &lt;tr&gt; &lt;td width="500" height="680" bgcolor="#C6F3F9"&gt; &lt;div style="width: 400px; height:40px; margin-top:590px; margin-left:18px; background-color:#063;"&gt;image&lt;/div&gt; &lt;/td&gt; &lt;td width="200" style="background-image: url(right-cell-bg.jpg)";&gt; &lt;div style="width: 150px; height: 70px; margin-top: 80px; margin-left: 20px; text-align: center; background-color: #FF0;" &gt; text &lt;/div&gt;&lt;/td&gt; </code></pre> <p></p> <p></p> <p>for example:</p> <p>a. Shall I position the yellow and green areas with DIVs? </p> <p>b. Should I use additional DIVs (maybe for the cells)?</p> <p>c. Is style-margin is the best way to acheive the positioning? </p> <p>d. should I define cell widths with html or with style-width?</p> <p>e. any other comments.</p> <p>Thanks!</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload