Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [css] problem z css'em, poprawka..., prosba
in5ane
post
Post #1





Grupa: Zarejestrowani
Postów: 1 335
Pomógł: 34
Dołączył: 9.11.2005
Skąd: Wrocław

Ostrzeżenie: (10%)
X----


Witam, mam problem otoz chcialem aby ".tekst2" jak bedzie linkiem to nie mial koloru bialego z "A". Ale "A" musi tez zostac, trzeba cos dopisac do ".tekst2".

Jak cos robie na stronie w tym ".tekst2" to uzywam
  1. <span style=".tekst2">cos</span>
(i tak jest kolor dobry), a jak zrobie
  1. <span style=".tekst2"><a href="index.php>cos</a></span>
(to jest biale)

Tutaj sa cale te CSS'y:
Kod
.menu       { font-family: arial; font-size: 11px; color: #FFFADD; text-align: justify; font-weight: bold }
.menu2       { font-family: arial; font-size: 11px; color: #0F3F00; text-align: center }
.menu3       { font-family: arial; font-size: 11px; color: #295F00; text-align: center }
.menu4       { font-family: arial; font-size: 11px; color: #0F3F00; text-align: left }
.tekst       { font-family: arial; font-size: 12px; color: #132110; text-align: justify }
.tekst_lewo    { font-family: arial; font-size: 12px; color: #132110; text-align: left }
.tekst_srodek    { font-family: arial; font-size: 12px; color: #132110; text-align: center }
.dzial       { font-family: arial; font-size: 12px; color: #388500; text-align: justify; font-weight: bold }
.dzial2       { font-family: arial; font-size: 12px; color: #E1C214; text-align: justify; font-weight: bold }
.dzial3       { font-family: arial; font-size: 20px; color: #388500; text-align: justify; font-weight: bold }
.wiecej       { font-family: arial; font-size: 11px; color: #7F878A; text-align: justify; font-weight: bold }
.wiecej:hover       { font-family: arial; font-size: 11px; color: #A5ADB0; text-align: justify; font-weight: bold }
.wiecej2       { font-family: arial; font-size: 11px; color: #BB760D; text-align: justify; font-weight: bold }
.wiecej2:hover       { font-family: arial; font-size: 11px; color: #DE9323; text-align: justify; font-weight: bold }
.wiecej3       { font-family: arial; font-size: 11px; color: #7F878A; text-align: justify }
.wiecej3:hover       { font-family: arial; font-size: 11px; color: #A5ADB0; text-align: justify }
.wiecej4       { font-family: arial; font-size: 11px; color: #DE9323; text-align: justify }
.wiecej4:hover       { font-family: arial; font-size: 11px; color: #BB760D; text-align: justify }
.tytul      { font-family: arial; font-size: 16px; color: #132110; text-align: justify; font-weight: bold }
.tytul2      { font-family: arial; font-size: 12px; color: #36261B; text-align: justify; font-weight: bold }
.tytul2:hover      { font-family: arial; font-size: 12px; color: #737373; text-align: justify; font-weight: bold }
.maly       { font-family: arial; font-size: 10px; color: #6D777E; text-align: justify; }
.maly2       { font-family: arial; font-size: 10px; color: #295F00; text-align: justify; }
.maly3       { font-family: arial; font-size: 10px; color: #E7AF5D; text-align: justify; }
.maly4       { font-family: arial; font-size: 10px; color: #BB760D; text-align: justify; }
.maly5       { font-family: arial; font-size: 10px; color: #ff8787; text-align: justify; }
.tekst2       { font-family: arial; font-size: 11px; color: #132110; }
.tekst2_lewo       { font-family: arial; font-size: 11px; color: #132110; text-align: left; }
.tekst3       { font-family: arial; font-size: 11px; color: #FFFFFF text-align: left; }
.tekst4       { font-family: arial; font-size: 11px; color: #F0DC43 }
.tekst5       { font-family: arial; font-size: 11px; color: #FFFFFF; text-align: left; }
.tekst6       { font-family: arial; font-size: 11px; color: #FFFFFF; text-align: right; }
A           { color: #FCFBFA; text-decoration : none }
a:hover     { color: #DE9323; text-decoration : none }
.m {border-bottom: 1px #EE9616 solid; border-right: 1px #EE9616 solid; border-left: 1px #EE9616 solid; border-top: 1px #EE9616 solid; background: #FEE4BB; font-size: 11px; padding: 2px; font-family: arial; color: #848365; text-align: left;}
.r {border-bottom: 1px #FDE0B5 solid; border-right: 1px #FDE0B5 solid; border-left: 1px #FDE0B5 solid; border-top: 1px #FDE0B5 solid; background: #FEE0B2; font-size: 11px; padding: 2px; font-family: arial; color: #848365; text-align: left;}
.t {border-bottom: 1px #DEE6EB solid; border-right: 1px #DEE6EB solid; border-left: 1px #DEE6EB solid; border-top: 1px #DEE6EB solid; background: #F5F8FA; font-size: 11px; padding: 2px; font-family: arial; color: #848365; text-align: left;}


..........--tutaj--juz--bylo--nie--potrzebne..........


Ten post edytował in5ane 20.03.2007, 15:57:29


--------------------
> > > Tworzenie stron < < <
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 6)
strife
post
Post #2





Grupa: Przyjaciele php.pl
Postów: 2 605
Pomógł: 96
Dołączył: 22.10.2004
Skąd: UK

Ostrzeżenie: (0%)
-----


Konstrukcja <span style=".tekst2">cos</span> jest błędna. Ale jak rozumiem, pomyliło Ci się z class.

Nie poprawię Ci tego kodu, za to dam przykład:

  1. a {
  2. color: red;
  3. }
  4. .zmien a {
  5. color: blue;
  6. }
  7. <p><a href="#">Normalny glowny link</a> </p>
  8. <p class="zmien"><a href="#">Nienormalny link</a></p>


Mam nadzieję, że o to Ci chodzi. winksmiley.jpg


--------------------
Go to the top of the page
+Quote Post
babejsza
post
Post #3





Grupa: Zarejestrowani
Postów: 407
Pomógł: 1
Dołączył: 4.03.2003
Skąd: warszawa

Ostrzeżenie: (0%)
-----


lol 8|,

Cytat
<span style=".tekst2">cos</span>


Co to jest??

  1. <span style="tekst2">cos</span>


Jeżeli już smile.gif.

A tak w ogóle to zrób tak:

  1. .tekst2 a {font-family: arial; font-size: 11px; color: #132110;}


I pocztytaj trochę o css i xhtml/html bo widać, że nie masz o tym zielonego pojęcia.
Go to the top of the page
+Quote Post
in5ane
post
Post #4





Grupa: Zarejestrowani
Postów: 1 335
Pomógł: 34
Dołączył: 9.11.2005
Skąd: Wrocław

Ostrzeżenie: (10%)
X----


done, poradzilem sobie inna metoda smile.gif


--------------------
> > > Tworzenie stron < < <
Go to the top of the page
+Quote Post
babejsza
post
Post #5





Grupa: Zarejestrowani
Postów: 407
Pomógł: 1
Dołączył: 4.03.2003
Skąd: warszawa

Ostrzeżenie: (0%)
-----


Mam nadzieję, że nie równie tragiczną jak do tej pory smile.gif.
Go to the top of the page
+Quote Post
strife
post
Post #6





Grupa: Przyjaciele php.pl
Postów: 2 605
Pomógł: 96
Dołączył: 22.10.2004
Skąd: UK

Ostrzeżenie: (0%)
-----


Cytat
Cytat
<span style=".tekst2">cos</span>

Co to jest??

  1. <span style="tekst2">cos</span>


Jeżeli już smile.gif.


Nie wprowadzaj ludzi w błąd! Jak pisałem wyżej nie można się odwołać poprzez style do klasy. Od tego jest argument class, polecam lekturę http://kurs.browsehappy.pl/.

Cytat
Mam nadzieję, że nie równie tragiczną jak do tej pory .

Mogłeś mu równie dobrze napisać to na PW, ponieważ nic nowego do tematu Twoja wypowiedź nie wnosi.

Pozdrawiam


--------------------
Go to the top of the page
+Quote Post
babejsza
post
Post #7





Grupa: Zarejestrowani
Postów: 407
Pomógł: 1
Dołączył: 4.03.2003
Skąd: warszawa

Ostrzeżenie: (0%)
-----


Nie zauważyłem, że tam jest style zamiast class. Odnośnie ostatniego posta to rzeczywiście się pośpieszyłem, ale ogólnie chodziło o to, żeby nie trzymać się złych metod.
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 20.08.2025 - 10:35