PSD-Tutorials.de
Forum für Design, Fotografie & Bildbearbeitung
Tutkit
Agentur
Hilfe
Kontakt
Start
Forum
Aktuelles
Besonderer Inhalt
Foren durchsuchen
Tutorials
News
Anmelden
Kostenlos registrieren
Aktuelles
Suche
Suche
Nur Titel durchsuchen
Von:
Menü
Anmelden
Kostenlos registrieren
App installieren
Installieren
JavaScript ist deaktiviert. Für eine bessere Darstellung aktiviere bitte JavaScript in deinem Browser, bevor du fortfährst.
Du verwendest einen veralteten Browser. Es ist möglich, dass diese oder andere Websites nicht korrekt angezeigt werden.
Du solltest ein Upgrade durchführen oder einen
alternativen Browser
verwenden.
Antworten auf deine Fragen:
Neues Thema erstellen
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
Webdesign: HTML/CSS, Responsive Design, Sass...
CSS Navi ohne Text, aber mit Grafiken
Beitrag
<blockquote data-quote="Metal_Head" data-source="post: 1617623" data-attributes="member: 331213"><p><strong>AW: CSS Navi ohne Text, aber mit Grafiken</strong></p><p></p><p>Okay, mittlerweile klappt es doch ganz gut. Die Navigation funktioniert auch. Allerdings(!) wird mir bei Dreamweaver es so angezeigt:</p><p><erledigt></p><p></p><p>und in Firefox so:</p><p><erledigt></p><p></p><p>Dreamweaver is der sache am nähesten...</p><p>Nur sollte alles weiter nach links und die Grafik unten nach ganz rechts...</p><p></p><p>Edit:display:inline-block war der Fehler. display:inline funktioniert!</p><p></p><p>Allerdings hab ich jetzt zuviel Abstand zwischen dem header und der Navi... <img src="/styles/default/xenforo/smilies/uhm.gif" class="smilie" loading="lazy" alt=":(" title="Frown :(" data-shortname=":(" /></p><p>In Dreamweaver ist das wieder mal okay, Firefox zeigt mir ca. 1cm luft dazwischen an...</p><p></p><p>HTML:</p><p>[html]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"></p><p><html xmlns="http://www.w3.org/1999/xhtml"></p><p><head></p><p><title>Dimensionsfabrik</title></p><p><meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /></p><p><link rel="stylesheet" href="style.css" type="text/css" media="screen" /></p><p></head></p><p><body></p><p><div id="container"></p><p> <div id="container_oben"></p><p> <div id="header"></div></p><p> <div id="navi"></p><p> <ul style="list-style: none; display:inline-block"></p><p><li> <a class="button0" href="index.html"></a> </li></p><p><li> <a class="button1" href="index.html"></a> </li></p><p><li> <a class="button2" href="uebermich.html"></a> </li></p><p><li> <a class="button3" href="index.html"></a> </li></p><p><li> <a class="button4" href="uebermich.html"></a> </li></p><p><li> <a class="button5" href="index.html"></a> </li></p><p><li> <a class="button6" href="index.html"></a> </li></p><p></ul></p><p> </div></p><p> </p><p> </div></p><p></div></p><p></p><p></body></p><p></html>[/html]CSS:</p><p>[code]@charset "utf-8";</p><p>/* CSS Document */</p><p></p><p>body{</p><p> background: #FFF;</p><p> color: #000; /* Schriftfarbe */</p><p> font: "Courier New", Courier, monospace;</p><p> font-size: 12px/* Schriftgroesse und Schriftart */</p><p> margin: 0px; /* Aussenabstand */</p><p>}</p><p></p><p>p, pre{</p><p> padding: 0px 0px; /* Innenabstand */</p><p> margin: 0px; /* Aussenanbstand */</p><p> color: #000; /* Schriftfarbe */</p><p>} </p><p></p><p>a {</p><p> color: #000;</p><p>}</p><p>a:visited {</p><p> color:#333;</p><p>}</p><p>a:hover {</p><p> color: #333;</p><p>}</p><p>a:active {</p><p> color:#333;</p><p>}</p><p></p><p></p><p>h1 {</p><p> font-size: 24px;</p><p> font-weight: normal;</p><p> }</p><p></p><p>h2 {</p><p> font-size: 18px;</p><p> font-weight: normal;</p><p>}</p><p>#container{</p><p> background-color:#FFF;</p><p> width:auto;</p><p> margin: 0 auto;</p><p> padding: 0;</p><p>}</p><p></p><p>#container_oben{</p><p> background-color:#FFF;</p><p> width:1024px;</p><p> height:244px;</p><p>}</p><p></p><p>#header{</p><p> background-image:url(Bilder/header.png);</p><p> width:1024px;</p><p> height:185px;</p><p>}</p><p></p><p>#navi{</p><p> width:1024px;</p><p> height:59px;</p><p> float:left;</p><p>}</p><p></p><p></p><p>a.button0:link, a.button0:visited {</p><p> background-image: url(Bilder/leer_1.png);</p><p> width:57px;</p><p> height:59px;</p><p> float:left;</p><p>}</p><p></p><p>a.button1:link, a.button1:visited {</p><p> background-image: url(Bilder/start.png);</p><p> float:left;</p><p> width:141px;</p><p> height:59px;</p><p>}</p><p>a.button1:hover {</p><p> background-image: url(Bilder/start_over.png);</p><p> float:left;</p><p> width:141px;</p><p> height:59px;</p><p>}</p><p></p><p>a.button2:link, a.button2:visited {</p><p> background-image: url(Bilder/ueber_uns.png);</p><p> float:left;</p><p> width:205px;</p><p> height:59px;</p><p>}</p><p>a.button2:hover {</p><p> background-image: url(Bilder/ueber_uns_over.png);</p><p> float:left;</p><p> width:205px;</p><p> height:59px;</p><p>}</p><p></p><p>a.button3:link, a.button3:visited {</p><p> background-image: url(Bilder/referenzen.png);</p><p> float:left;</p><p> width:231px;</p><p> height:59px;</p><p>}</p><p>a.button3:hover {</p><p> background-image: url(Bilder/referenzen_over.png);</p><p> float:left;</p><p> width:231px;</p><p> height:59px;</p><p>}</p><p></p><p>a.button4:link, a.button4:visited {</p><p> background-image: url(Bilder/kontakt.png);</p><p> float:left;</p><p> width:185px;</p><p> height:59px;</p><p>}</p><p>a.button4:hover {</p><p> background-image: url(Bilder/kontakt_over.png);</p><p> float:left;</p><p> width:185px;</p><p> height:59px;</p><p>}</p><p></p><p>a.button5:link, a.button5:visited {</p><p> background-image: url(Bilder/blog.png);</p><p> float:left;</p><p> width:147px;</p><p> height:59px;</p><p>}</p><p>a.button5:hover {</p><p> background-image: url(Bilder/blog_over.png);</p><p> float:left;</p><p> width:147px;</p><p> height:59px;</p><p>}</p><p>a.button6:link, a.button6:visited {</p><p> background-image: url(Bilder/leer_2.png);</p><p> float:left;</p><p> width:57px;</p><p> height:59px;</p><p>}</p><p>[/code]Fehler kann ich keine finden. Ein Freund von mir hat sich den Code auch angeschaut, aber fand auch nichts...</p><p>Unglaublich, was eine Navi für Arbeit machen kann...</p><p></p><p></p><p>Edit: display:inline-block war der Fehler. display:inline funktioniert!</p><p></p><p>Allerdings hab ich jetzt zuviel Abstand zwischen dem header und der Navi... <img src="/styles/default/xenforo/smilies/uhm.gif" class="smilie" loading="lazy" alt=":(" title="Frown :(" data-shortname=":(" /></p><p>In Dreamweaver ist das wieder mal okay, Firefox zeigt mir ca. 1cm luft dazwischen an...</p><p></p><p>Edit 2: Auch erledigt... Hätte nur nochmal padding und margin auf 0 für die ul setzen sollen <img src="/styles/default/xenforo/smilies/zwinker.gif" class="smilie" loading="lazy" alt=";)" title="Wink ;)" data-shortname=";)" /></p></blockquote><p></p>
[QUOTE="Metal_Head, post: 1617623, member: 331213"] [b]AW: CSS Navi ohne Text, aber mit Grafiken[/b] Okay, mittlerweile klappt es doch ganz gut. Die Navigation funktioniert auch. Allerdings(!) wird mir bei Dreamweaver es so angezeigt: <erledigt> und in Firefox so: <erledigt> Dreamweaver is der sache am nähesten... Nur sollte alles weiter nach links und die Grafik unten nach ganz rechts... Edit:display:inline-block war der Fehler. display:inline funktioniert! Allerdings hab ich jetzt zuviel Abstand zwischen dem header und der Navi... :( In Dreamweaver ist das wieder mal okay, Firefox zeigt mir ca. 1cm luft dazwischen an... HTML: [html]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Dimensionsfabrik</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <link rel="stylesheet" href="style.css" type="text/css" media="screen" /> </head> <body> <div id="container"> <div id="container_oben"> <div id="header"></div> <div id="navi"> <ul style="list-style: none; display:inline-block"> <li> <a class="button0" href="index.html"></a> </li> <li> <a class="button1" href="index.html"></a> </li> <li> <a class="button2" href="uebermich.html"></a> </li> <li> <a class="button3" href="index.html"></a> </li> <li> <a class="button4" href="uebermich.html"></a> </li> <li> <a class="button5" href="index.html"></a> </li> <li> <a class="button6" href="index.html"></a> </li> </ul> </div> </div> </div> </body> </html>[/html]CSS: [code]@charset "utf-8"; /* CSS Document */ body{ background: #FFF; color: #000; /* Schriftfarbe */ font: "Courier New", Courier, monospace; font-size: 12px/* Schriftgroesse und Schriftart */ margin: 0px; /* Aussenabstand */ } p, pre{ padding: 0px 0px; /* Innenabstand */ margin: 0px; /* Aussenanbstand */ color: #000; /* Schriftfarbe */ } a { color: #000; } a:visited { color:#333; } a:hover { color: #333; } a:active { color:#333; } h1 { font-size: 24px; font-weight: normal; } h2 { font-size: 18px; font-weight: normal; } #container{ background-color:#FFF; width:auto; margin: 0 auto; padding: 0; } #container_oben{ background-color:#FFF; width:1024px; height:244px; } #header{ background-image:url(Bilder/header.png); width:1024px; height:185px; } #navi{ width:1024px; height:59px; float:left; } a.button0:link, a.button0:visited { background-image: url(Bilder/leer_1.png); width:57px; height:59px; float:left; } a.button1:link, a.button1:visited { background-image: url(Bilder/start.png); float:left; width:141px; height:59px; } a.button1:hover { background-image: url(Bilder/start_over.png); float:left; width:141px; height:59px; } a.button2:link, a.button2:visited { background-image: url(Bilder/ueber_uns.png); float:left; width:205px; height:59px; } a.button2:hover { background-image: url(Bilder/ueber_uns_over.png); float:left; width:205px; height:59px; } a.button3:link, a.button3:visited { background-image: url(Bilder/referenzen.png); float:left; width:231px; height:59px; } a.button3:hover { background-image: url(Bilder/referenzen_over.png); float:left; width:231px; height:59px; } a.button4:link, a.button4:visited { background-image: url(Bilder/kontakt.png); float:left; width:185px; height:59px; } a.button4:hover { background-image: url(Bilder/kontakt_over.png); float:left; width:185px; height:59px; } a.button5:link, a.button5:visited { background-image: url(Bilder/blog.png); float:left; width:147px; height:59px; } a.button5:hover { background-image: url(Bilder/blog_over.png); float:left; width:147px; height:59px; } a.button6:link, a.button6:visited { background-image: url(Bilder/leer_2.png); float:left; width:57px; height:59px; } [/code]Fehler kann ich keine finden. Ein Freund von mir hat sich den Code auch angeschaut, aber fand auch nichts... Unglaublich, was eine Navi für Arbeit machen kann... Edit: display:inline-block war der Fehler. display:inline funktioniert! Allerdings hab ich jetzt zuviel Abstand zwischen dem header und der Navi... :( In Dreamweaver ist das wieder mal okay, Firefox zeigt mir ca. 1cm luft dazwischen an... Edit 2: Auch erledigt... Hätte nur nochmal padding und margin auf 0 für die ul setzen sollen ;) [/QUOTE]
Bilder bitte
hier hochladen
und danach über das Bild-Icon (Direktlink vorher kopieren) platzieren.
Zitate einfügen…
Authentifizierung
Wenn ▲ = 5, ▼ = 2 und ■ = 7, was ist ▲ × ▼ + ■?
Antworten
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
Webdesign: HTML/CSS, Responsive Design, Sass...
CSS Navi ohne Text, aber mit Grafiken
Oben