Visualizzazione dei risultati da 1 a 2 su 2

Discussione: Da tabella a css

  1. #1

    Da tabella a css

    Ciao a tutti,
    potete darmi una mano a "tradurre" questo codice utilizzando solamente i css??

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
    <head>
    <title>Nome Tab.</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>

    <body>
    <table width="800" border="0" cellpadding="0" cellspacing="0" align="CENTER">
    <tr> <td width="260" rowspan="3" valign="TOP" height="240">[img]cartella/box1.gif[/img]</td><td width="370" rowspan="3" valign="TOP" height="240">[img]cartella/box2.gif[/img]</td><td width="170" valign="TOP" height="80">[img]cartella/box3.gif[/img]</td></tr>
    <tr> <td valign="TOP" height="80">[img]cartella/box4.gif[/img]</td></tr>
    <tr> <td valign="TOP" height="80">[img]cartella/box5.gif[/img]</td></tr>
    <tr> <td valign="TOP">[img]cartella/box6.gif[/img]</td><td valign="TOP">[img]cartella/box7.gif[/img]</td><td valign="TOP" height="40">[img]cartella/box8.gif[/img]</td></tr>
    </table>
    </body>
    </html>


    Grazie!!

  2. #2
    Personalmente farei così:

    Codice PHP:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <
    html>
    <
    head>
    <
    title>Nome Tab.</title>
    <
    meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    <
    style type="text/css">
    body
    {
        
    text-aligncenter;
    }
    #container
    {
        
    width800px;
        
    margin-rightauto;
        
    margin-leftauto;
    }
    #box1
    {
        
    background#FF0000 url(cartella/box1.gif) no-repeat;
        
    width260px;
        
    height240px;
    }
    #box2
    {
        
    background#00FF00 url(cartella/box2.gif) no-repeat;
        
    width370px;
        
    height240px;
    }
    #box3
    {
        
    background#0000FF url(cartella/box3.gif) no-repeat;
        
    width170px;
        
    height80px;
    }
    #box4
    {
        
    background#FFFF00 url(cartella/box4.gif) no-repeat;
        
    width170px;
        
    height80px;
    }
    #box5
    {
        
    background#FF6600 url(cartella/box5.gif) no-repeat;
        
    width170px;
        
    height80px;
    }
    #box6
    {
        
    background#FF00FF url(cartella/box6.gif) no-repeat;
        
    width260px;
        
    height40px;
    }
    #box7
    {
        
    background#00FFFF url(cartella/box7.gif) no-repeat;
        
    width370px;
        
    height40px;
    }
    #box8
    {
        
    background#999999 url(cartella/box8.gif) no-repeat;
        
    width170px;
        
    height40px;
    }
    .
    box
    {
        
    floatleft;
    }
    </
    style>
    </
    head>

    <
    body>
        <
    div id="container">
            <
    div id="box1" class="box"></div>
            <
    div id="box2" class="box"></div>
            <
    div id="box3" class="box"></div>
            <
    div id="box4" class="box"></div>
            <
    div id="box5" class="box"></div>
            <
    div id="box6" class="box"></div>
            <
    div id="box7" class="box"></div>
            <
    div id="box8" class="box"></div>
            <
    div style="clear: both"></div>
        </
    div>
    </
    body>
    </
    html
    Cerco ombrello vecchio, nuovo, moderno o antidiluviano; purché protegga da una pioggia che vien giù come Dio la manda. Fate presto che ho l’acqua alla gola. (Noè)

    C# programming and other stuffs

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.