Go Back   vb.org Archive > vBulletin 5 Connect Discussion > vB5 Design and Graphics Discussions

Reply
 
Thread Tools Display Modes
  #1  
Old 02-17-2016, 04:29 PM
Aros12 Aros12 is offline
 
Join Date: Jan 2016
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default How Do I Center my Ad?

I've created an Ad Module towards the top of the main page at: www.hobbysquawk.com that I can't seem to get it to center justify. It defaults to left align...I'm hoping this is an easy fix I am overlooking...

Here's the HTML code in the ad module:

Code:
<center><a href="http://www.motionrc.com/flightlinerc-hawker-sea-fury-1200mm-47-wingspan-pnp/" TARGET="_blank"><img src="http://www.hobbysquawk.com/images/RCG_FlightLineSeaFury2.jpg" target="_blank"></a></img></center>
Here's a screen shot...Any help would be appreciated!
Attached Images
File Type: jpg 1.jpg (64.7 KB, 0 views)
Reply With Quote
  #2  
Old 02-17-2016, 04:34 PM
Aros12 Aros12 is offline
 
Join Date: Jan 2016
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here's what I am looking for the end result to be...Note the margin at the top as well...I would like some space between the light grey top border and the ad itself, while being center aligned.
Attached Images
File Type: jpg 1.jpg (66.4 KB, 0 views)
Reply With Quote
  #3  
Old 02-17-2016, 04:40 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Try adding the following to the template "additional_css.css":

HTML Code:
#widget_158 {
	width: 100% !important;
}
Reply With Quote
Благодарность от:
Aros12
  #4  
Old 02-17-2016, 04:47 PM
Aros12 Aros12 is offline
 
Join Date: Jan 2016
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks Mark! That worked!

Any idea on a top margin? Thanks again!
Reply With Quote
Благодарность от:
MarkFL
  #5  
Old 02-17-2016, 04:57 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Aros12 View Post
Thanks Mark! That worked!

Any idea on a top margin? Thanks again!
Edit the CSS selector I posted to now read:

HTML Code:
#widget_158 {
	width: 100% !important;
	margin-top: 1em;
}
And then you can tweak the "1em" value to get it exactly as you want. For example, if you wanted to double it, then put "2em" instead, or if you wanted to halve it, put "0.5em".
Reply With Quote
  #6  
Old 02-17-2016, 05:04 PM
Aros12 Aros12 is offline
 
Join Date: Jan 2016
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

God bless all you CSS gurus! Thanks man, that's just what I needed!

Now since I am striking gold, I thought I would press my luck and see if you know how to make the banners rotational. Right now if I add more than one banner to the ad module, they stack one on top of the other. NOT the desired effect, lol. Is there code that allows me to put multiple banners in the ad module, rank them and have those simply rotate on page refresh?
Reply With Quote
  #7  
Old 02-17-2016, 05:13 PM
MarkFL's Avatar
MarkFL MarkFL is offline
 
Join Date: Feb 2014
Location: St. Augustine, FL
Posts: 3,853
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Aros12 View Post
God bless all you CSS gurus! Thanks man, that's just what I needed!

Now since I am striking gold, I thought I would press my luck and see if you know how to make the banners rotational. Right now if I add more than one banner to the ad module, they stack one on top of the other. NOT the desired effect, lol. Is there code that allows me to put multiple banners in the ad module, rank them and have those simply rotate on page refresh?
That would likely take some coding. I would do a search here to see if there are any products uploaded to allow rotation of ads. If not, then I would suggest posting a request >>here<< and see if any vB 5.x coders can help you out.
Reply With Quote
  #8  
Old 02-17-2016, 05:27 PM
Aros12 Aros12 is offline
 
Join Date: Jan 2016
Posts: 44
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Awesome, thanks again!
Reply With Quote
  #9  
Old 02-17-2016, 08:35 PM
shimei shimei is offline
 
Join Date: Feb 2015
Posts: 216
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Really like your logo and forum styling Aros12. Keep up the great work!

Shim
Reply With Quote
2 благодарности(ей) от:
Aros12, MarkFL
  #10  
Old 03-03-2016, 10:52 AM
webmastersun's Avatar
webmastersun webmastersun is offline
 
Join Date: Oct 2013
Location: www.webmastersun.com
Posts: 433
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I though your forum was vB4

Code:
#widget_158 {
	width: 100% !important;
	margin-top: 1em;
}
Not ever used this code to align center an image

But seem The OP's question is answered.
Reply With Quote
Reply

Thread Tools
Display Modes

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 12:23 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.04487 seconds
  • Memory Usage 2,280KB
  • 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
  • (2)bbcode_code
  • (2)bbcode_html
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (4)post_thanks_box_bit
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (3)post_thanks_postbit
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (2)postbit_attachment
  • (10)postbit_onlinestatus
  • (10)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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete