www.webdeveloper.com
Results 1 to 2 of 2

Thread: HTML & CSS Layout Help

  1. #1
    Join Date
    Aug 2007
    Posts
    20

    HTML & CSS Layout Help

    Hello,

    I am trying to create a layout with the sidebar on the left and content on the right, this is my first time creating a site with this layout type:

    Doctype: HTML5 -> Transitional

    Issues:

    1. I am having trouble to create a layout that expands dependent on the amount of data given.

    2. How would I produce the graphic -> Metal so that it expands.

    3. Why am I getting overlap with I hover over my nav dropdown menu -> The nav does not seem to get wider for the number of options within it.

    4. Would I make my #rightCol graphic a fixed width?

    5. Do I even need #rightCol?

    6. Should I make the width 960 or 990px?

    HTML:

    HTML Code:
           <html>
        <head>
        </head>
        <body>
        	<div id ="wrapper">
                <div id ="header">
        		<h1 id = "companyName">Houses</h1>
        		<h4 id = "companyQuote">"Houses"</h4>
        	    </div>
        <div id="leftCol">
        <nav>
        <ul>
                    <li>Dashboard></li>
                    <li>Edit Pages
                        <ul>
                            <li><a href="#">Pages</a></li>
                        </ul>
                    </li>
                    <li>Gallery
                        <ul>
                            <li><?php echo anchor('admin/addimage','Add Image');?></li>
                            <li><?php echo anchor('admin/deleteimage','Delete Image');?></li>
                        </ul>
                    </li>
                        <li>Sales
                            <ul>
                                <li>Add Sale</li>
                                <li>Edit Sale
                            <ul>
                                <li><a href="#">Sales</a></li>
                            </ul>
                            </li>
                            </li>
                        <li><Delete Sale </li>
                    </ul>
                            <li><Log Out</li>
                    </li>
        </nav>
        </div><!-- Left Col End -->
        	<div id="rightCol">
                       <section id="content">
                           <h1>PageName></h1>
                            <p>Content<p>
                              </section>
           </div><!-- Right Col End -->     
            
            <div id="footer">content</div>
        	</div> <!-- Wrapper Close -->
        </body>
        </html>
    CSS:

    Code:
            /*Reset */
        html, body, h1, h2, h3, h4, h5, h6, form, input, ul, ol, p, fieldset { padding: 0; margin: 0; }
         
        /* Main CSS */
        #wrapper{
            width:990px;
            height:auto;
            margin: 0 auto;
        }
        #header{
            background-image:url('../images/header.png');
            background-color:#000;
            width:990px;
            height:220px;
        }
        
        #leftCol{
            width:190px;
            float:left;
        }
        
        #rightCol{
            width:990px;
            margin:0 0 0 0px;
        }
        /*Menu */
        nav{
            float:left;
            width:190px;
            height:500px;
            margin:0 0 0 0;
            background-image:url('../images/metalnavbg.png');
        
        
        }
         
        nav ul{
            float:left;
            margin:0;
            list-style:none;
            font-size:14px;
            width:190px;
        }
         
        nav li a{
            font-size:14px;
            color:#fff;
            line-height:25px; /*Text Hight On Button */
            text-decoration:none;
            text-indent:25px;
            display:block;
            width:190px;
            height:27px;
            background-image:url('../images/normal.png');
        }
        
        nav ul li ul{
            display:none;
        }
        
        nav ul li:hover ul{
            display:block;
        }
         
        nav a:hover{
            background-image:url('../images/onclick.png');
        }
         
        /*Content */
         
         
        #content{
            width:990px;
        }
         
        #content h1{
            margin: 10px 0 0 0;
            text-indent:25px;
            font-family: 'Josefin Slab', arial, serif;
            font-size:24px;
        }
         
        #content p{
            margin:10px 0 0 0;
            text-indent:26px;
        }
         
        #footer{
            clear:both;
            background:url('../images/footer.png') no-repeat #000;
            width:990px;
            height:60px;
        }
         
        /* Misc*/
         
        #metal{
            float:left;
            margin:160px 0 0 -190px;
            background-image:url('../images/metalnavbg.png');
            height:400px;
            width:190px;
        }
         
        /* Text Formatting */
         
        #companyName{
            text-align:center;
            padding-top:45px;
            font-size:35px;
            color:#f0f0ef;
        }
         
        #companyQuote{
            text-align:center;
            font-size:18px;
            color:#a5a4a2;
        }
         
        /*Forms */
        
        #leftFormCol{
        	float:left;
        	width:100px;
        	border:1px solid gray;
        }
        
        #rightFormCol{
        	float:left;
        	width:150px;
        	margin:0 0 0 75px;
        	border: 1px solid blue;
        }
         
        /*General*/
         
        #validation{
            font-weight:bold;
            color:#ff0101;
        }
        
        form{
            width:100%;
            float:left;
            margin: 0 0 0 25px;
        	border: 1px solid black;
        }
        
        fieldset{
            border:none;
        }
        
        label{
        	width:30px;
        	margin: 0 42px 3px 5px;
        	border: 1px solid green;
        }
        
        input{
            width:130px;
            height:20px;
            margin: 0 42px 3px 5px;
        	border: 1px solid red;
        }
        
        ::-webkit-input-placeholder{
            text-indent:5px;
            color:red;
        }
         
        /*Admin Login */
        #loginForm{
            margin: 0 auto 10px;
            width:150px;
            height:150px;
            background-color:#c5c4c3;
            -moz-border-radius:3px;
            -webkit-border-radius:3px;
        }
        #loginForm label{
            font-weight:bold;
            margin:5px 0 0 15px;
            display:block;
        }
        #loginForm input{
            margin:10px 0 0 15px;
            height:15px;
        }
        #loginForm input[type=submit]{
            margin-top:5px;
            display:block;
        }
        #sales{
            width:150px;
            height:180px;
            margin-left:15px;
            border: 1px solid red;
        }
         
        #sales .thumbnail{
            height:150px;
            width:150px;
        }
         
        #sales .location{
            float:left;
            text-align:center;
            font-weight:bold;
            margin-left:8px;
        }
         
        #sales .price{
            float:left;
            text-align:left;
            font-weight:bold;
            padding-left:5px;
            color:#ff0101;
        }

  2. #2
    Join Date
    Jan 2010
    Location
    Winnipeg, Manitoba, Canada
    Posts
    95
    I have no idea.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center

"

"

X vBulletin 4.2.2 Debug Information

  • Page Generation 0.19701 seconds
  • Memory Usage 2,876KB
  • Queries Executed 15 (?)
More Information
Template Usage (34):
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_global_above_footer
  • (1)ad_global_below_navbar
  • (1)ad_global_header1
  • (1)ad_global_header2
  • (1)ad_navbar_below
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)ad_thread_first_post_content
  • (1)ad_thread_last_post_content
  • (1)bbcode_code
  • (1)bbcode_html
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (2)memberaction_dropdown
  • (1)navbar
  • (4)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (2)postbit
  • (2)postbit_onlinestatus
  • (2)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available (6):
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files (26):
  • ./showthread.php
  • ./global.php
  • ./includes/class_bootstrap.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/functions_navigation.php
  • ./includes/class_friendly_url.php
  • ./includes/class_hook.php
  • ./includes/class_bootstrap_framework.php
  • ./vb/vb.php
  • ./vb/phrase.php
  • ./includes/functions_facebook.php
  • ./includes/functions_calendar.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_notice.php
  • ./packages/vbattach/attach.php
  • ./vb/types.php
  • ./vb/cache.php
  • ./vb/cache/db.php
  • ./vb/cache/observer/db.php
  • ./vb/cache/observer.php 

Hooks Called (73):
  • init_startup
  • friendlyurl_resolve_class
  • init_startup_session_setup_start
  • database_pre_fetch_array
  • database_post_fetch_array
  • init_startup_session_setup_complete
  • global_bootstrap_init_start
  • global_bootstrap_init_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • load_show_variables
  • load_forum_show_variables
  • global_state_check
  • global_bootstrap_complete
  • global_start
  • style_fetch
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • strip_bbcode
  • friendlyurl_clean_fragment
  • friendlyurl_geturl
  • forumjump
  • cache_templates
  • cache_templates_process
  • template_register_var
  • template_render_output
  • fetch_template_start
  • fetch_template_complete
  • parse_templates
  • fetch_musername
  • notices_check_start
  • notices_noticebit
  • process_templates_complete
  • friendlyurl_redirect_canonical
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • memberaction_dropdown
  • tag_fetchbit
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • build_navigation_data
  • build_navigation_array
  • check_navigation_permission
  • process_navigation_links_start
  • process_navigation_links_complete
  • set_navigation_menu_element
  • build_navigation_menudata
  • build_navigation_listdata
  • build_navigation_list
  • set_navigation_tab_main
  • set_navigation_tab_fallback
  • navigation_tab_complete
  • fb_like_button
  • showthread_complete
  • page_templates