Results 1 to 11 of 11

Thread: Is it possible to have 2 background images?

  1. #1
    Join Date
    Aug 2003
    Glasgow, Scotland

    Is it possible to have 2 background images?

    I ditched frames in favour of putting an image across the top of the page (a logo). I did this as a background image aligned to the top of the page then set a margin to place the text below it.

    The problem that I have now, is that I'd like to put a different backgroung image in the centre of each page as well.

    I'm not too sure if this is even possible! Does anyone know if it is possible?

    My CSS knowledge is far from perfect. I've got the title in an external style sheet. I thought the second image could go in as an inline style?

    Any ideas/pointers would be appreciated!

  2. #2
    Join Date
    Nov 2002
    XYZZY - UK
    No it is not possible to place two images on the canvas using CSS unless you give a URL of the page in question it's hard to tell exactly what you are after.

  3. #3
    Join Date
    Aug 2003
    Glasgow, Scotland
    I'm writing the 'bare bones' of an Intranet, so it's not on the web!

    To be honest I didn't think it could be done, but people on this forum know way more than I do (or probably ever will....but hey I can try!!)

    What I'm trying to acheive...without the use of frames, is a heading (company logo). Some of the pages are going to have downloads of training manuals we've got for things like word, excel and bespoke software for our users. Some of the pages go quite far down so I thought it might be a good idea to stick an image in the background that says 'Excel Notes' (or whatever) so that the user is always aware of the page that they're on.

    I'm more than a bit confused by the whole CSS positioning, I've read some stuff, but aaargh, quite hard to get your head round it!

    I'm sure I'll come up with something!

    Thanks anyway!

  4. #4
    Join Date
    Nov 2002
    I would have to see more of what you actually trying to do, but from what playing around I have done trying to get two background-images at once, I don't think it would work. I tried using two classes, and then a class and a id and it still only used the last one defined. I'm guessing here, but if all you want is an image to always be showing as a person scrolls down then you should use a background image with a fixed position.


  5. #5
    Join Date
    Nov 2002

    Scroll down and the background image stays in the middle. I think that's what you were looking for.

  6. #6
    Join Date
    Nov 2002
    More thinking, check out the link below and look how they use a background image within the <h1> tag and then you could use the <body> tag for the other background image.


  7. #7
    Join Date
    Nov 2003
    Jerryville, Tejas
    Here's a very simple example of a "page" background overlayed with a "content" background. Narrow your browser window up enough to force vertical scrolling to see the effect of the fixed content background but don't expect that to work with IE.

  8. #8
    Join Date
    Aug 2003
    Glasgow, Scotland
    Thanks to all of you, I should be able to get it fixed with the examples you've given.

  9. #9
    Join Date
    Feb 2003
    Wales, UK
    one of my latest sites www.williamsons-oldham.co.uk uses a similar technique. Basically you just nest a few divs and apply the backgrounds to them.
    Last edited by DaveSW; 01-13-2004 at 06:21 AM.
    In a world without walls and fences - who needs Windows and Gates?! - Unknown Author
    "And there's Bill Gates, the...most...famous...man in the...ah...Microsoft." -- A TV commentator for the 2000 Olympics.

    Web Design Faq? | W3C | Validator | Accessibility testing | Speed up your PC | Wura | Box Model Research

  10. #10
    Join Date
    Nov 2002
    XYZZY - UK
    I know what you were after now a fixed position div as a header to simulate a frame and a fixed central image in the lower pseudo frame.

    Much like with the Mozilla test suite.

  11. #11
    Join Date
    Aug 2003
    Glasgow, Scotland
    Yes, that's it exactly......you're explanation of what I'm looking for is so much better than mine!!!

    I've not actually had a chance to have a go at changing it yet, but I've no doubt that thanks to the suggestions here I'll get it!

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