Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 09-11-2011, 08:06 AM
Eltu Eltu is offline
 
Join Date: Jun 2011
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Adding image to CMS layout?

I run a forum using vB 4 with CMS, and would like to add an informational banner at the top of the main page, in the form of a png image. As in, a part of the CMS layout and below the normal banner.

I've managed to make the CMS layout work for this (see the dark yellow space above, where I can add a widget):



But so far, I haven't found a way to actually add a static image to a layout slot instead of a widget. Is this possible?

Eltu
Reply With Quote
  #2  
Old 09-11-2011, 09:37 AM
setishock setishock is offline
 
Join Date: Feb 2008
Location: Houma, La.
Posts: 1,177
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The layout is just for the widgets. Where they get parked on the page.
Pop this in your additional.css and adjust as needed.
Code:
/* Seti added: Background color and image */
.vbcms_content {
	margin:0.5em 0 1em;
	width: 100%;
	float: {vb:stylevar left};
background: #000033;
background-image: url(path/to/your/image);
background-repeat:no-repeat;
background-position:center top;
}
This may not work as it sits but it'll give you a starting point.
Reply With Quote
  #3  
Old 09-11-2011, 09:46 AM
Eltu Eltu is offline
 
Join Date: Jun 2011
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I got the image added and working (thanks! ) - however, the middle section of the CMS needs to be moved down for it not to overlap - how can I accomplish this?

EDIT: I managed to move the section down - however, I got one last problem - I want the image to be aligned left according to the middle section of my CMS grid - right now, if I align it left it aligns with the very edge of the page, making it overlap with the left widgets. How can I solve this?
Reply With Quote
  #4  
Old 09-11-2011, 10:54 AM
Dead Eddie's Avatar
Dead Eddie Dead Eddie is offline
 
Join Date: Apr 2004
Location: at Home...
Posts: 196
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Why not just use a static HTML widget. This is kind of what they're there for...
Reply With Quote
  #5  
Old 09-11-2011, 11:24 AM
Eltu Eltu is offline
 
Join Date: Jun 2011
Posts: 4
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks for the suggestion - I almost solved it now, by making a custom HTML widget containing a simple <img> tag. The only remaining problem I have, is that I wish to move the entire middle section of the CMS page higher up. Right now it's lower down than the widgets on the side, with a lot of empty space above.

I can move it higher up by editing the vbcms_header_margin stylevar, but then my new image widget doesn't get moved, causing everything to overlap. Attaching images describing the issue. The "Next meeting" text is the image I added with the widget, and as you can see there's a lot of blank space above it - I'd like to move the entire middle section up.
Attached Images
File Type: jpg Untitled-5.jpg (56.2 KB, 0 views)
File Type: jpg 1.jpg (32.7 KB, 0 views)
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 04:54 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.11813 seconds
  • Memory Usage 2,216KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (5)post_thanks_box
  • (5)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (5)post_thanks_postbit_info
  • (5)postbit
  • (2)postbit_attachment
  • (5)postbit_onlinestatus
  • (5)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_attachment
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete