|
|||
Link über ganze Tabellenzelle?
Hallo!
Ich möchte einen Monatskalender über eine Tabelle darstellen, dabei soll jede Tabellenzelle anklickbar bar. Ich kenne nur eine nicht-XHTML-konforme Lösung: Code:
<a href="{link}"><td>{text}</td></a> Bei der Lösung Code:
<td><a href="{link}">{text}</a></td> Weiß jemand eine HTML-konforme Lösung, bei der es reicht, irgendwo auf die Zelle zu klicken? |
Sponsored Links |
|
||||
Die einzig wahre Lösung ist die Darstellung der Links als Liste. Die Links bekommen dabei ein display: block; und der IE noch ein paar Anpassungen. Habe das alles hier aufgeschrieben: http://xhtmlforum.de/40267-css-haeuf...tml#post296439. Falls es dennoch eine Tabelle sein soll/muß, läßt sich alles auf deren Zellen übertragen.
Geändert von heiko_rs (27.06.2006 um 13:23 Uhr) |
Sponsored Links |
|
|||
|
|
|||
Ich hab es so gelöst, es funktioniert beim IE sowie beim Firefox:
CSS-Teil: Code:
table.calendar { border:1px solid #000; width:560px; } table.calendar th { width:80px; background-color:#00ff00; color:#000000; text-align:center; font-family: Arial, Helvetica, sans-serif; font-size:10pt; } table.calendar td:hover { background-color:#ff8800; } table.calendar td { font-family: Arial, Helvetica, sans-serif; font-size:8pt; background-color:#ffff00; text-align:right; height:40px; vertical-align:top; } table.calendar td a { display:block; height:40px; text-decoration:none; } Code:
<table class="calendar" cellspacing="1"> <tr> <th>Montag</th> <th>Dienstag</th> <th>Mittwoch</th> <th>Donnerstag</th> <th>Freitag</th> <th>Samstag</th> <th>Sonntag</th> </tr> <tr> <td><a href="#">1.</a></td> <td><a href="#">2.</a></td> <td><a href="#">3.</a></td> <td><a href="#">4.</a></td> <td><a href="#">5.<br /><br />Sommer-Party</a></td> <td><a href="#">6.</a></td> <td><a href="#">7.</a></td> </tr> {usw...} </table> Geändert von phpfuchs (27.06.2006 um 19:12 Uhr) |
|
|||
Zitat:
Zitat:
Robin |
Sponsored Links |
|
|||
/*blödsinn gestrichen */
Geändert von IChao (27.06.2006 um 22:05 Uhr) |
Sponsored Links |
Themen-Optionen | |
Ansicht | |
|
|
Ähnliche Themen | ||||
Thema | Autor | Forum | Antworten | Letzter Beitrag |
100% Höhe Problem im FF und im IE | mimii | CSS | 7 | 08.02.2008 17:55 |
Ständig wechselnde Bilder, Werbung | Vybsi | (X)HTML | 17 | 25.01.2008 00:00 |
Fehlerfreier Code? | _h4ze | CSS | 3 | 04.05.2006 22:31 |
Problem mit Hintergrund vom Sidebar! | Pumpkin | CSS | 2 | 01.04.2006 05:14 |
Link markieren bei Auswahl | Anonymous | CSS | 2 | 17.06.2003 15:32 |