Go Back   vb.org Archive > vBulletin Modifications > vBulletin 4.x Modifications > vBulletin 4.x Template Modifications
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Add Banner Rotator Widget To CMS Details »»
Add Banner Rotator Widget To CMS
Version: 1.00, by metalguy639 metalguy639 is offline
Developer Last Online: Jan 2014 Show Printable Version Email this Page

Category: Miscellaneous Hacks - Version: 4.1.3 Rating:
Released: 10-24-2011 Last Update: Never Installs: 43
Template Edits
 
No support by the author.

THIS TEMPLATE EDIT BROUGHT TO YOU BY:


www.skinsnstyles.com

First if you plan on using this hack you must download & install y2Ksw's Banner Rotator hack found here: https://vborg.vbsupport.ru/showthread.php?t=188328. This little mod is only for use with that hack.

CLICK INSTALLED TO GET SUPPORT FOR THIS ADD-ON. IF YOU DO NOT CLICK INSTALLED I CANNOT HELP YOU.

Here is a simple way to add your banners in a CMS widget.

You will need to create a PHP Execution by doing the following:

Step 1:

1. In the admincp go to vBulletin CMS>Widgets
2. Click on "Create New Widget" at the bottom.
3. Choose "PHP Direct Execution" in the Widget Type drop down at the top.
4. Give your widget a title - do not make it too long as your box will be whatever size you have in your CMS.
5. Now click the "Save" button.

Step 2:

1. Go to vBulletin CMS>Widgets and select the widget you just made.
2. Click on the "Configure" link all the way to the right.
3. Delete all the test inside the box when it pops up.
4. Place this code in the box:

Code:
$templater = vB_Template::create('banner_sidebar');
$output = $templater->render();
5. Now click the "Save" button.

Step 3:

1. Go to Styles & Templates>Style Manager click the drop down box on the right side and choose "Add New Template".
2. In the "Title" box put "banner_sidebar" without the quotes.
3. Now in the large box below place your code for your banners like you would any other template. For instance I put this:

vBSEO ONLY!!!

Code:
<div align="center">@vbbanners:4@</div><br />
<div align="center">@vbbanners:5@</div><br />
<div align="center">@vbbanners:6@</div><br />
<div align="center">@vbbanners:7@</div><br />
<div align="center">@vbbanners:8@</div><br />
<div align="center">@vbbanners:9@</div>
I'm using vBSEO so that is why it may look different from yours.

If you are not using vBSEO it will look like this:

NOT USING vBSEO!!!!

Code:
<div align="center"><!--@vbbanners:4@--></div><br />
<div align="center"><!--@vbbanners:5@--></div><br />
<div align="center"><!--@vbbanners:6@--></div><br />
<div align="center"><!--@vbbanners:7@--></div><br />
<div align="center"><!--@vbbanners:8@--></div><br />
<div align="center"><!--@vbbanners:9@--></div>
4. Now click the "Save" button.

Step 4:

1. Enter your banner info using the positions that you put code to in your new template and save the banners.

Screenshots

File Type: png cmsbanners.png (9.1 KB, 0 views)

Supporters / CoAuthors

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
2 благодарности(ей) от:
fxdigi-cash, RichieBoy67

Comments
  #2  
Old 12-31-2011, 10:55 PM
macrocamaleon macrocamaleon is offline
 
Join Date: Dec 2008
Posts: 5
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Working great in 4.1.9

Thx for share...

Regards
Reply With Quote
  #3  
Old 04-06-2012, 04:43 PM
Tri@de's Avatar
Tri@de Tri@de is offline
 
Join Date: Sep 2003
Posts: 168
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Correction:
you wrote:
<div align="center">@vbbanners:4@</div><br />
is wrong.
have to be <div align="center"><!--@vbbanners:4@--></div><br />
Reply With Quote
  #4  
Old 04-09-2012, 03:50 AM
metalguy639 metalguy639 is offline
 
Join Date: Dec 2008
Posts: 501
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Tri@de View Post
Correction:
you wrote:
<div align="center">@vbbanners:4@</div><br />
is wrong.
have to be <div align="center"><!--@vbbanners:4@--></div><br />
Nope that is right if you are using vBSEO. As I said in the first post if you had read it all that code would be somewhat different for some than what I put there. But I will edit the original post and put that in there.
Reply With Quote
  #5  
Old 04-09-2012, 08:24 AM
Tri@de's Avatar
Tri@de Tri@de is offline
 
Join Date: Sep 2003
Posts: 168
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm not using vbseo.
Perhaps some other hack could change...
Reply With Quote
  #6  
Old 04-09-2012, 08:55 PM
metalguy639 metalguy639 is offline
 
Join Date: Dec 2008
Posts: 501
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Tri@de View Post
I'm not using vbseo.
Perhaps some other hack could change...

???? I changed the original instructions to reflect members not using vBSEO.
Reply With Quote
  #7  
Old 04-10-2012, 04:28 AM
Tri@de's Avatar
Tri@de Tri@de is offline
 
Join Date: Sep 2003
Posts: 168
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok, but you are using it now?
Reply With Quote
  #8  
Old 04-10-2012, 12:30 PM
metalguy639 metalguy639 is offline
 
Join Date: Dec 2008
Posts: 501
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Tri@de View Post
ok, but you are using it now?
Not sure what that has to do with anything. The site I had it on is no longer available. But it did work just fine. If you are having an issue with it working properly let me know what problem you are having and I can help.
Reply With Quote
  #9  
Old 05-16-2012, 02:19 AM
diyautoftw diyautoftw is offline
 
Join Date: Feb 2012
Posts: 19
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hey, I have a question.
I want to specify what ads go where by CMS section or catagory. Like if I have articles in the Food section I can specify articles to go there. Is this capable of doing that? Thanks!
Reply With Quote
  #10  
Old 05-17-2012, 11:03 PM
metalguy639 metalguy639 is offline
 
Join Date: Dec 2008
Posts: 501
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by diyautoftw View Post
Hey, I have a question.
I want to specify what ads go where by CMS section or catagory. Like if I have articles in the Food section I can specify articles to go there. Is this capable of doing that? Thanks!
Sorry for the late reply. I suppose you could do that with the positions and several widgets. But it does not do it automatically.
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 02:54 PM.


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.04416 seconds
  • Memory Usage 2,323KB
  • Queries Executed 25 (?)
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
  • (3)bbcode_code
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (4)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (2)post_thanks_box_bit
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (10)post_thanks_postbit_info
  • (9)postbit
  • (1)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
  • 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
  • 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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete