CSS - Info Box With Roundrd Heading
I have 3 images that I would like to go togather to form a heading with rounded corners. I want to use 3 div tag to accomplish this. I am unable to get all 3 to lign up
Code: .rounded_STYLE{ background-color: #fff; border: 1px solid BORDER_COLOR; position: relative; } .rounded_STYLE{background:url('/images/chg.gif') repeat-x; } .rounded_STYLE > .tl, .rounded_STYLE > .tr, .rounded_STYLE > .bl, .rounded_STYLE > .br{ width: 6px; height: 24px; position: absolute; } .rounded_STYLE > .tl{ background: url(/images/clg.gif) top left no-repeat; } .rounded_STYLE > .tr{ background: url(/images/crg.gif) top right no-repeat; } .rounded_STYLE > .tc{ background: url(/images/chg.gif) top right no-repeat; } .rounded_STYLE > .bl{ background: url(/images/bl.png) bottom left no-repeat; } .rounded_STYLE > .br{ background: url(/images/br.png) bottom right no-repeat; } Code: <div class="rounded_STYLE rounded"> <div class="tl"></div> <div class="tc"><table class="h"><tr><td class="l"></td><td>dddddddddd</td><td class="r">ssssssss</td></tr></table></div> <div class="tr"></div> ... contents of the block go here ... <div class="bl"></div><div class="br"></div> </div> Similar TutorialsHi guys. The strangest thing happened to me a few minutes ago. I tried centering the heading for my webpage using css in dreamweaver. When I looked it up on the browser to see whether it checked out right, to my horror, I discovered that the heading had disappeared. Could someone tell me what went wrong? thanx kaz. I'm trying to put together a CSS layout for a blog, and unfortunately my meager skills have crapped out on me. The page currently looks like this: http://prestonandtread.com/test/ I want it to be a full screen header while the footer is fixed and the width of the content. I thought I had it pieced together ok enough from different tutorials, but the top and left sides of the screen show background and the content isn't parking itself on the page correctly. Help me get this to where it should be! Code: <style type="text/css"> html, body { margin:0; padding:0; height:100%; /* 100 % height */ } #header { width: 100%; height: 150px; } html>body #header { position:fixed; z-index:10; /* Prevent certain problems with form controls */ } html>body #wrap {height:100%;} /* 100 % height */ #wrap { width:479px; margin:0 auto; } html>body #content-wrap {height:100%;} /* 100 % height */ html>body #content {padding:10px 10px 10px 10px;} /* 6em = height of #header and #footer + 1em, 1em = give the content some breathing space */ #footer { width:479px; height:160px; } html>body #footer { position:fixed; bottom:0; z-index:10; } html, body { background-color: #99CCFF; } #header { text-align: center; background-image: url(background.jpg); background-position: top left; background-repeat: repeat-x; background-color: #99CCFF; } #footer { text-align: center; background-image: url(eyes.jpg); background-color: #99CCFF; } #content-wrap, #content { background-color: #FFFFFF; } #footer a {color:#111;} </style> H all, I have a horizontal navigation bar which basically looks like this: Thing0 | Thing1 | Thing2 | Thing34 What I want to do is when I select a link to a new page, I'd like (using CSS) to have that link highlighted so that the user can see which page he is on. It's either that or hardcoding the name to each page...but since it's already in the Nav bar, I thought highlighting the link on the nav bar serves as a heading as well... Possible? Hi everybody. I am developing a site for classic games, and I am having trouble putting a navigation list on the left of my page and aligning a heading on the right with the top of the list border. Code: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html lang="en"> <head> <title>Choose a Page</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <style type="text/css"> /* <![CDATA[ */ body { font-family: arial; font-size: 12pt; margin: 0; padding: 0; } h1, h2 { text-align: center; } ul { margin: 0; width: 25%; height: 20em; padding: 0; border: .5em solid #00f; list-style-type: none; list-style-position: outside; } li { background-color: #0ff; padding: .5em 0 .5em; } li a { background-color: #0f0; height: 1em; padding-left: .5em; display: block; font-weight: bold; } /* ]]> */ </style> </head> <body> <h1>Game Index</h1> <ul> <li><a>Home</a></li> <li><a href="dir.html" title="View the Directions">Directions</a></li> <li><a href="gbc.html" title="View GameBoy/GameBoy Color games">GameBoy/GB Color</a></li> <li><a href="gba.html" title="View GameBoy Advance games">GameBoy Advance</a></li> <li><a href="nes.html" title="View Nintendo/Famicom games">NES/Famicom</a></li> <li><a href="snes.html" title="View Super NES/Super Famicom games">SNES/Super Famicom</a></li> <li><a href="ggear.html" title="View Game Gear games">Game Gear</a></li> <li><a href="genesis.html" title="View Genesis MegaDrive games">Genesis/MegaDrive</a></li> <li><a href="32x.html" title="View 32X games">32X</a></li> <li><a href="psx.html" title="View PlayStation games">PlayStation</a></li> </ul> <h2>Select a page</h2> <div id="pgdesc">Please make a selection from the list above</div> <h3>Note: This page does not host ANY emulators. You have come to the wrong place if you are looking for an emulation site.</h3> <div id="img"> <img id="atari" src="atari2600.jpg" alt="Atari 2600"> </div> </body> </html> I realize that a list and a heading are both block-level elements, but I'm wondering... I'd rather not use absolute positioning since it doesn't work well with different resolutions. I'm just wanting it to work with 800x600 and 1024x768 resolutions. Can anybody help? Is there a way I can have the checkbox to the right of the heading without stretching out the actual heading? It works fine when it is floated to the left http://www.iankovi.com/html_.html http://www.iankovi.com/css_.css Hi, I am trying to add a 8px border under my headings, but I only want it to go as far as the word. At the moment, it is going the whole width of my div container. This is what I have at the moment: PHP Code: #sidebar h2, #sidebar h3 { color: #444; font-size: 20px; font-weight: normal; margin: 0px 0 5px 0; padding: 0px 0 0px 0; border-bottom: 8px solid #FE9023; } Any help would be great. Thanks Again I am new to CSS so bear with me here...I did search this forum before posting this... I am using a 3 column template, I am having some problems between the "#columns" with the heading <h*> of these columns. as long as each column has a differnt heading size all is well but if two columns have the same size heading I can't seem to be able to make them different colors I'm trying to figure out how to do something like this: Code: <h6>Lorem Ipsum Dolor <span>jan 10 2006</span></h6> And make the heading line up to the left side and the span on the right. It's close. It's lining up on the right but on the next line down rather than the same line. Take a look. Any bright ideas on why this is happening or how to fix it? Thanks. This is probably something extremely simple, but I'm the slow kid today... I have a right-hand sidebar with a heading that is not behaving the way I want it to. After each word, it creates a new line, then the next word.... Any suggestions, as always, are appreciated. Here's the page: http://www.websimage.com/pcqtest/index.html Thanks guys/gals :) Hi There - Have a simple container div containing two other divs, top and content. My problem is that I can't get the colorboxtop to stick to the top of its container. There's a wayward space. Can't find any stray margins or padding hanging around. Perhaps fresh eyes can see what I cannot. Please let me know. Any help you can give me would be greatly appreciated. Thanks! Code: <body> <div class="colorbox"> <div class="colorboxtop"> <h2>title goes here</h2> </div><!-- /colorboxtop --> <div class="boxcontent"> <p>You should read this and <a href="#">Click Here</a>.</p> <a title="Go Here!" href="#">[button]</a> </div><!-- /boxcontent --> </div><!-- /colorbox --> </body> No great complexity there...here's the CSS: Code: body { color:#666666; font-family:Lucida Grande,Verdana,sans; font-size:10px; font-size-adjust:none; font-style:normal; font-variant:normal; font-weight:normal; line-height:13px; } .colorbox { margin-bottom:9px; padding-bottom:15px; width:300px; border:thin solid #CCCCCC; } .colorbox h2 { color:#FFCC33; } .colorbox { color:#CC6633; padding:0px 20px 15px; margin-top:0; margin-bottom:10px; } .colorboxtop { background-color: #dddddd; height:50px; color:#666666; background-image: url(images/bg_Tiles/stripe-dk-blue-green.png); padding:auto 20px; } .colorbox a { color:#C5DBE9; font-weight:bold; text-decoration:none; } I know that there has to be a better way to do this than they way I did it with all sorts of "marging-left's". I was hoping there was an efficient way to do this without using a table or the table-layout properties. Code: <h1>Current Natoinal Average Rates*</h1> <p class="rateheader">Bus Types<label style="margin-left: 200px; ">Transfer</label><label style="margin-left: 45px; ">5 Hours</label><label style="margin-left: 45px; ">Day Rate</label></p> <p class="ratewhite">Deluxe Motor Coach<label style="margin-left: 145px; ">$230</label><label style="margin-left: 60px; ">$350</label><label style="margin-left: 60px; ">$735</label></p> <p class="ratepurple">Minibus<label style="margin-left: 220px; ">$175</label><label style="margin-left: 58px; ">$275</label><label style="margin-left: 62px; ">$600</label></p> <p class="ratewhite">Schoolbus<label style="margin-left: 205px; ">$120</label><label style="margin-left: 57px; ">$200</label><label style="margin-left: 64px; ">$400</label></p> <p class="ratepurple">Entertainer<label style="margin-left: 201px; ">N/A</label><label style="margin-left: 65px; ">N/A</label><label style="margin-left: 72px; ">$800</label></p> <p class="ratewhite">Executive<label style="margin-left: 211px; ">N/A</label><label style="margin-left: 63px; ">$600</label><label style="margin-left: 64px; ">$1200</label></p> <p class="ratepurple">Trolley<label style="margin-left: 227px; ">$360</label><label style="margin-left: 56px; ">$550</label><label style="margin-left: 65px; ">$870</label></p> <p class="ratewhite">Double Decker<label style="margin-left: 180px; ">$400</label><label style="margin-left: 57px; ">$600</label><label style="margin-left: 64px; ">$950</label></p> <p class="ratepurple">Van<label style="margin-left: 242px; ">$150</label><label style="margin-left: 57px; ">$250</label><label style="margin-left: 66px; ">$500</label></p> <p class="ratewhite">*Rates vary from city to city. Run a search for specific rates in your area.</p> Hi all, I'm not sure if im being stupid here, but ive now been looking at it for far too long and its confusing me...i think this is a CSS issue, although it could be HTML, i really dont know. sorry if this is the case all. I'm just trying to set a skeleton layout for future work, at the top is a <div> for header, followed by the <div> for menus, then content and footer - standard layout really. But when i try to put the menus <div> below the header there seems the be an issue with the spacing...for some reason there is a gap between the two, unless i put a word in the menu <div> in which case the two section are touching(which is what want, just minus a random word in there) Code: <body> <div id="wrap"> <div id="innerwrap"> <div id="header" class="test"> <div id="logo" class="headericons"> COMPANY NAME </div> <div id="name" class="headericons"> COMPANY LOGO </div> </div> <div id="menu"> so, this bit when empty, will not display properly, yet when a word is added it joins with the above <div> <ul> <li><a href="#">MENU</a></li> <li><a href="#">MENU</a></li> <li><a href="#">MENU</a></li> </ul> </div> <div id="content"> Content </div> <div id="footer"> Company infomation here. </div> </div> </div> </body> My CSS is: Code: #wrap{width:60em;height:46em;background:silver;margin:0 auto;text-align:left; /*covers all in ie*/ padding-top:.1em;} #innerwrap{ background-color:gray;margin:.5em;height:45em;} #header{ background:#3F8BCA url(/img/topgradient.jpg) repeat-x scroll left top; height:6em;} #name{ background-color:white; width:10em;height:6em; margin-left:2em;} #logo{ background-color:PowderBlue;width:10em;height:6em;float:right; margin-right:2em;} #menu{background-color:OliveDrab;} #content{background-color:Olive;margin:0 2em; height:30em;} #footer{background-color:OliveDrab;margin:.5em;} ul {font-family:Arial,helvetica, sans-serif;} a {text-decoration: none; color:White;} Any help would be grand Regards and thanks MG I defined several css styles to be nested within an overall "pageBlock" style and some of the nested divs don't seem to revert to the settings of the parent pageBlock div after a </div>. Safari is the only browser that does what intuitively I think should happen. IE, OmniWeb, FireFox, iCab all do their own squirrely things. In general though, in all browsers except Safari, elements are being positioned not relative to the parent (pageBlock) but relative to left edge of the item directly above them. This causes them to get farther and farther from the left edge of the page the more blocks are used. Is this rightward creep what's "supposed" to happen and it's Safari that's getting it "wrong"? Thanks Ken Here's the styles: Code: .pageBlock { margin-right: auto; margin-left: auto; top: 32px; width: 80%; height: auto } .indentBlock { color: black; font-size: 14px; line-height: 18px; font-family: "Times New Roman", Georgia, Times; text-align: left; padding-bottom: 4px; position: relative; top: 8px; left: 32px } .imageBlock { padding-bottom: 8px } And here's how I'm using them... Code: <div class="pageBlock"> <p>bla bla bla</p> <div class="indentBlock"> <p>rah rah rah</p> </div> <p>cha cha cha</p> <div class="indentBlock"> <p>rah rah rah</p> </div> </div> |