Jochen Kubik: Vererbung

Beitrag lesen

Hi Cheatah,

leider glaube ich reden wir irgendwie aneinander vorbei, ich will css Konstrukte wie:

---schnipp-----
.nav1inaktiv   { color:#FF0000; font-weight:bold; font-size:10pt; }
.nav2inaktiv   { color:#FF5F00; font-weight:bold; font-size:10pt; }
.nav3inaktiv   { color:#FF7F00; font-weight:bold; font-size:10pt; }
.nav4inaktiv   { color:#FF9F00; font-weight:bold; font-size:10pt; }
.nav5inaktiv   { color:#FFBF00; font-weight:bold; font-size:10pt; }
.nav6inaktiv   { color:#E00060; font-weight:bold; font-size:10pt; }
.nav7inaktiv   { color:#DF0000; font-weight:bold; font-size:10pt; }
.nav8inaktiv   { color:#6699CC; font-weight:bold; font-size:10pt; }

.nav1 { color:#FF0000; font-style:normal; font-weight:bold; font-size:22pt; }
.nav2 { color:#FF5F00; font-style:normal; font-weight:bold; font-size:22pt; }
.nav3 { color:#FF7F00; font-style:normal; font-weight:bold; font-size:22pt; }
.nav4 { color:#FF9F00; font-style:normal; font-weight:bold; font-size:22pt; }
.nav5 { color:#FFBF00; font-style:normal; font-weight:bold; font-size:22pt; }
.nav6 { color:#E00060; font-style:normal; font-weight:bold; font-size:22pt; }
.nav7 { color:#DF0000; font-style:normal; font-weight:bold; font-size:22pt; }
.nav8 { color:#6699CC; font-style:normal; font-weight:bold; font-size:22pt; }

.kl { font-size:14pt; line-height:14pt;}

.nav1kl { color:#FF0000; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav2kl { color:#FF5F00; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav3kl { color:#FF7F00; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav4kl { color:#FF9F00; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav5kl { color:#FFBF00; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav6kl { color:#E00060; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav7kl { color:#DF0000; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}
.nav8kl { color:#6699CC; font-style:normal; font-weight:bold; font-size:14pt; line-height:14pt;}

-----schnapp-------

vermeiden, und nicht immer alles neu schreiben, sondern nur, das was ich ändert. Ich dachte ich kann dies durch Vererbung von einer Klasse in die andere erreichen. Wie das im HTML aussieht kann ich doch nicht wissen, wenn ich nicht weiß wie ich es vererben soll!

Ich werde mich erst mal mit einem guten Buch bewaffnen, und euch zur Not dann nochmal nerven ;-)

Grüße aus Ludwigsburg