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...
Probleme mit erstem css-layout
Beitrag
<blockquote data-quote="limubai81" data-source="post: 905087" data-attributes="member: 83538"><p>hiho ich bin grad dabei eine seite mit hilfe von css zu gestalten, nun hab ich aber mal 2 fragen dazu.</p><p>ich steh da grad nämlich aufm schlauch, wenn ich die seite verkleiner sollte man scrollen können aber ich möchte nicht den flexiblen hintergrund verlieren.</p><p>ich hab das mal hochgeladen damit ihr euch das mal anschaun könnt</p><p></p><p></p><p>und hier mal der quelltext dazu:</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><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /></p><p><title>Sonnenvoltaik</title></p><p><link rel="stylesheet" type="text/css" href="css/global.css" /></p><p></head></p><p><body></p><p><div id="background"><img src="http://www.psd-tutorials.de/modules/Forum/images/background.jpg" alt="" title="" width=100% height=100%/></p><p><div id="centerlayout"></p><p><!-- rechter navi-div --></p><p><div id="linke_box"></p><p><br /><br /></p><p>&nbsp;&nbsp;&nbsp;Men&uuml;punkt 1</p><p><br /><br /></p><p>&nbsp;&nbsp;&nbsp;Men&uuml;punkt 2</p><p><br /><br /></p><p>&nbsp;&nbsp;&nbsp;Men&uuml;punkt 3</p><p></div> </p><p><div id="banner"></div></p><p><!-- mittlerer content-div --></p><p><div id="boxmittelinks"></div></p><p><div id="boxmitteinhalt"></div></p><p><div id="boxmitterechts"></div></p><p><!-- unterer linker content-div --></p><p><div id="boxuntenlinks"></div></p><p><!-- unterer rechter content-div --></p><p><div id="boxuntenrechts"></div></p><p></p><p></div> <!-- Ende vom centerlayout-div --></p><p></div> <!-- Ende vom background-div --></p><p></body></p><p></html></p><p></p><p>[/html]und hier css:</p><p>[html]@charset "utf-8";</p><p>/* CSS Document */</p><p>img, div, png { behavior: url(iepngfix.htc) }</p><p>html, body {margin:0; padding:0; width:100%; height:100%; overflow:hidden;}</p><p>body {font-family:verdana, arial, sans-serif; font-size:76%;}</p><p>div#background{position:fixed; z-index:1; width:100%; height:100%; }</p><p>div#centerlayout {</p><p>position:fixed;</p><p>left:50%;</p><p>top:50%;</p><p>height:741px;</p><p>width:759px;</p><p>margin-top:-370px;</p><p>margin-left:-379px;</p><p>background-image:url(../images/content-background.png);</p><p>z-index:1;</p><p>}</p><p>#linke_box {</p><p> background:url(../images/main/boxlinks.png);</p><p> width:129px;</p><p> height:700px;</p><p> margin-left:26px;</p><p> margin-top:24px;</p><p>}</p><p>div#banner {</p><p> background:url(../images/banner.png);</p><p> width:578px;</p><p> height:145px;</p><p> margin-left:155px;</p><p> margin-top:-706px;</p><p> z-index:1; </p><p>}</p><p>#boxmittelinks {</p><p> background:url(../images/main/boxmittelinks.png);</p><p> width:10px;</p><p> height:274px;</p><p> margin-left:170px;</p><p> margin-top:17px; </p><p>}</p><p>#boxmitterechts {</p><p> background:url(../images/main/boxmitterechts.png);</p><p> width:10px;</p><p> height:274px;</p><p> margin-left:723px;</p><p> margin-top:-274px; </p><p>}</p><p>#boxmitteinhalt {</p><p> width:543px;</p><p> height:274px;</p><p> margin-left:180px;</p><p> margin-top:-274px;</p><p> background-color:#FFFFFF; </p><p>}</p><p>#boxuntenlinks {</p><p> background:url(../images/main/boxuntenlinks.png);</p><p> width:354px;</p><p> height:263px;</p><p> margin-left:170px;</p><p> margin-top:5px;</p><p>}</p><p>#boxuntenrechts {</p><p> background:url(../images/main/boxuntenrechts.png);</p><p> width:206px;</p><p> height:259px;</p><p> margin-left:530px;</p><p> margin-top:-260px;</p><p>}</p><p></p><p>[/html]also was muss ich machen damit bei zu kleinem fenster scrollbalken erscheinen?</p><p>und dann hatte mich eine css-angabe irritiert und zwar die </p><p>[html]div#banner {</p><p> background:url(../images/banner.png);</p><p> width:578px;</p><p> height:145px;</p><p> margin-left:155px;</p><p> margin-top:-706px;</p><p> z-index:1; </p><p>}[/html]wieso muss ich da ne negative zahl angeben? Oo ich dachte eigentlich margin-top:24px</p><p></p><p>da dies meine ersten versuche sind eine seite ohne tabellen bzw. frames zu gestalten bitte ich sogar darum mich auf fehler hinzuweisen, wills ja lernen <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite1" alt=":)" title="Smile :)" loading="lazy" data-shortname=":)" /></p><p></p><p>lg LiMu</p></blockquote><p></p>
[QUOTE="limubai81, post: 905087, member: 83538"] hiho ich bin grad dabei eine seite mit hilfe von css zu gestalten, nun hab ich aber mal 2 fragen dazu. ich steh da grad nämlich aufm schlauch, wenn ich die seite verkleiner sollte man scrollen können aber ich möchte nicht den flexiblen hintergrund verlieren. ich hab das mal hochgeladen damit ihr euch das mal anschaun könnt und hier mal der quelltext dazu: [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> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Sonnenvoltaik</title> <link rel="stylesheet" type="text/css" href="css/global.css" /> </head> <body> <div id="background"><img src="http://www.psd-tutorials.de/modules/Forum/images/background.jpg" alt="" title="" width=100% height=100%/> <div id="centerlayout"> <!-- rechter navi-div --> <div id="linke_box"> <br /><br /> Menüpunkt 1 <br /><br /> Menüpunkt 2 <br /><br /> Menüpunkt 3 </div> <div id="banner"></div> <!-- mittlerer content-div --> <div id="boxmittelinks"></div> <div id="boxmitteinhalt"></div> <div id="boxmitterechts"></div> <!-- unterer linker content-div --> <div id="boxuntenlinks"></div> <!-- unterer rechter content-div --> <div id="boxuntenrechts"></div> </div> <!-- Ende vom centerlayout-div --> </div> <!-- Ende vom background-div --> </body> </html> [/html]und hier css: [html]@charset "utf-8"; /* CSS Document */ img, div, png { behavior: url(iepngfix.htc) } html, body {margin:0; padding:0; width:100%; height:100%; overflow:hidden;} body {font-family:verdana, arial, sans-serif; font-size:76%;} div#background{position:fixed; z-index:1; width:100%; height:100%; } div#centerlayout { position:fixed; left:50%; top:50%; height:741px; width:759px; margin-top:-370px; margin-left:-379px; background-image:url(../images/content-background.png); z-index:1; } #linke_box { background:url(../images/main/boxlinks.png); width:129px; height:700px; margin-left:26px; margin-top:24px; } div#banner { background:url(../images/banner.png); width:578px; height:145px; margin-left:155px; margin-top:-706px; z-index:1; } #boxmittelinks { background:url(../images/main/boxmittelinks.png); width:10px; height:274px; margin-left:170px; margin-top:17px; } #boxmitterechts { background:url(../images/main/boxmitterechts.png); width:10px; height:274px; margin-left:723px; margin-top:-274px; } #boxmitteinhalt { width:543px; height:274px; margin-left:180px; margin-top:-274px; background-color:#FFFFFF; } #boxuntenlinks { background:url(../images/main/boxuntenlinks.png); width:354px; height:263px; margin-left:170px; margin-top:5px; } #boxuntenrechts { background:url(../images/main/boxuntenrechts.png); width:206px; height:259px; margin-left:530px; margin-top:-260px; } [/html]also was muss ich machen damit bei zu kleinem fenster scrollbalken erscheinen? und dann hatte mich eine css-angabe irritiert und zwar die [html]div#banner { background:url(../images/banner.png); width:578px; height:145px; margin-left:155px; margin-top:-706px; z-index:1; }[/html]wieso muss ich da ne negative zahl angeben? Oo ich dachte eigentlich margin-top:24px da dies meine ersten versuche sind eine seite ohne tabellen bzw. frames zu gestalten bitte ich sogar darum mich auf fehler hinzuweisen, wills ja lernen :) lg LiMu [/QUOTE]
Bilder bitte
hier hochladen
und danach über das Bild-Icon (Direktlink vorher kopieren) platzieren.
Zitate einfügen…
Authentifizierung
Der grüne Frosch hüpft über die Hügel an den Bäumen vorbei in die Höhle. Bitte nenne das fünfte Wort!
Antworten
Start
Forum
Sonstiges
Webdesign, Webentwicklung & Programmierung
Webdesign: HTML/CSS, Responsive Design, Sass...
Probleme mit erstem css-layout
Oben