Thread: Miscellaneous Hacks - Banner Rotator (Definitive Mod) **UPDATED**
View Single Post
  #71  
Old 03-24-2007, 01:22 PM
andrefedalto andrefedalto is offline
 
Join Date: Dec 2005
Location: Brazil
Posts: 81
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Spika View Post
Great work!
Works fine in 3.6.5!
My banners are now clickable, and I Have put I forumhome template below $navbar
but I have another question: How I can open the link in a new Window? Where I have put the code?
Thanks in advanced.
If you did the changes WarLion pointed, find:
Code:
} else {
        $banner =     "<a href='".$ban['link']."'><img src='" . $vbulletin->options[bburl] . $defaultdir . "/" . $ban['name'] . "' alt='" . $ban['alt'] . "' width='".$ban['width']."' height='".$ban['height']."' border='0'></a>";            
    }
and replace to
Code:
} else {
        $banner =     "<a href='".$ban['link']."' target='_blank'><img src='" . $vbulletin->options[bburl] . $defaultdir . "/" . $ban['name'] . "' alt='" . $ban['alt'] . "' width='".$ban['width']."' height='".$ban['height']."' border='0'></a>";            
    }
Quote:
Originally Posted by php4ever View Post
I honestly dont see where you add banners. I've searched every single area of the admin cp and cant find a single place to upload images for the banners.
Check attached image.

Quote:
Originally Posted by brvheart View Post
I did that and now I get a DB error

MySQL Error : Unknown column 'link' in 'field list'
Error Number : 1054
After making the changes pointed by WarLion you have to reinstall the modification with the changed xml.

Quote:
Originally Posted by mescalin View Post
Its a perfect mod thank you..!

I would liketo see code rotating options (for bannerexchanges etc.) in the future releases..
Can you explain more please?



And to WarLion: Thanks for helping out
Just one thing: there were no need to create a new field in database (link), since i already had set the 'url' field for future releases. But if it works fine, leave as it is. Thanks a lot for adding the feature
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01495 seconds
  • Memory Usage 1,780KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code
  • (4)bbcode_quote
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.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_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • 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
  • showpost_complete