Results 1 to 5 of 5

Thread: Home Page Background Color Quandary

  1. #1
    Join Date
    Dec 2002

    Question Home Page Background Color Quandary

    My site is created in MS Publisher, which does not allow for multiple background page colors, which I am trying to accomplish. I would like my home page to have a black background; & all the others a white background. WYSIWYG I know...HTML I do not (well...some.)

    I thought I had accomplished this by framing the home page with a picture box; & then flood filling that frame with black (after layering all my graphics & text forward.) When I previewed the site in my browser (IE), it looked great. I converted the site to HTML & uploaded to my server; & what is happening with the home page is: when the site is logged onto, the page background is white for a moment; & then becomes black, which doesn't look very professional.

    My question is: If I remove the black flood fill from my home page; & then, for that page, follow the standard rule, which I believe would be BGCOLOR=black (in the BODY tag between the entries BODY & >), will that work? Or is there something else I am missing?

    Thanks in advance,


  2. #2
    Join Date
    Nov 2002
    Originally posted by Dave Clark

    though it is possible some smart@$$ may come along and say that you should specify your colors via CSS styles -- not in the BODY tag's attributes.

    Dave [/B]
    Of cource dope heads still living in the 1990ies are obvously not familear with that you can specify CSS inline as a "BODY tag attribute".

    <body style="background:black; color:white">

    Which method you end up using pretty much depends on if you would like to learn how people USED to code webpages or how to do it in the future.
    Currently we are at a crosspoint in time where people are slowly moving from the old way to the new way so either method will work just fine.
    // Stefan Huszics

  3. #3
    Join Date
    Dec 2002



    Thanks much. Question, tho: Why the entry for text directly after the entry for bgcolor?


    Thanks much. Question, tho: Why the entry for color (white) directly after the entry for background (black)?

    Question for both you guys (without starting a major ruckus):

    Which system (structured code vs. styles) is better? Or is it...I've always understood that ideally it's a combination of the two...straight code for standard formatting & css for aesthetic design. How about browser compatibility?

    Thanks in advance,


  4. #4
    Join Date
    Dec 2002


    At the risk of sounding like a total homer...I must tell you:


    First of all, Publisher must generate in css, because I found this entry just below <title>:

    <style type="text/css"><!--

    (I have this feeling I should have known this already.)

    The <BODY> tag was below the </style> tag, near the middle of the page; & below all the headings (which incidently, from Publisher, look like:

    #NormalP {
    text-align: left;
    margin-top: 0.0pt;
    margin-bottom: 0.0pt;

    #PubSt1F {
    PublisherStyleName: PubSt1;
    font-family: Times New Roman;
    font-size: 4.0pt;
    color: #000000;

    (as opposed to: <H1>) That's weird. Is that what is meant by "bloating" the code?

    The entry was: <body bgcolor="#FFFFFF" link="#0066ff" vlink="#cc3366" text="#000000" topmargin=0 leftmargin=0>, which I changed to: #000000, per your recommendation [& I had also found it last night in Elizabeth Castro's book (HTML4.)]

    Now, I have to find the code generated by the flood filled frame I created in the damn WYSIWYG app to get my black page in the first place...& delete it.

    In the future, I'll leave all my pages standard white in the editor & just change the code. I'm also going to make a honest effort to learn HTML. I like WYSIWYG, for the aesthetic freedom associated with visual page layout, but there's just no substitute for understanding the structure behind it all.

    Thanks again,


  5. #5
    Join Date
    Nov 2002

    Re: Fellas,

    Originally posted by mark4man
    Why the entry for color (white) directly after the entry for background (black)?
    I was providing the equivalent of the code posted by Dave and just as he said the important thing here is to provide a contrasting color.
    Some visitors might be using custom colors for text and background and if you just specify 1 of them it might turn the page unreadable for them.

    Which system (structured code vs. styles) is better?
    In your very simple example the 2 codes are pretty much equal.
    However the real benefit of CSS is that you can compleatly separate the webpage content from the style & formating by placing all style code in an externally linked file.
    This means that you can controll every detail of your entire site from 1 single file.
    If you eg have 10 pages and want to change the background from black to grey, you just change 1 value in this 1 file and each of the 10 pages is instantly updated.
    It saves a lot of time when making your website as well as maintaining it and additionally you neve risk forgetting to update 1 of the pages.

    Also, since you don't need to provide the same style and formating information on each page of your site, the entire site will also be quicker for visitors to download and require less bandwidth.

    There are other benefits with using CSS too, but the above is usually more then enough to make people realize that they really want to use CSS.

    How about browser compatibility?
    Simple things like text and backgrounds work quite well even in old browsers like NS 4 and IE 4.
    The newer the browser the more advanced stuff you can do with CSS.
    With eg Opera 7beta, IE6 and Mozilla (NS 7) you can easily replicate in just a few lines of code what used to require large DHTML scripts, eg like popup menus.
    Last edited by Stefan; 12-19-2002 at 12:41 AM.
    // Stefan Huszics

Thread Information

Users Browsing this Thread

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

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.09203 seconds
  • Memory Usage 2,877KB
  • Queries Executed 13 (?)
More Information
Template Usage (33):
  • (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
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (5)memberaction_dropdown
  • (1)navbar
  • (4)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (5)postbit
  • (5)postbit_onlinestatus
  • (5)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 (70):
  • 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_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_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