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

Reply
 
Thread Tools
Mini-Calendar in Header by BOP5 (VB 4.x.x) Details »»
Mini-Calendar in Header by BOP5 (VB 4.x.x)
Version: 1.1.1, by BirdOPrey5 (Senior Member) BirdOPrey5 is offline
Developer Last Online: Aug 2023 Show Printable Version Email this Page

Category: Miscellaneous Hacks - Version: 4.x.x Rating:
Released: 06-23-2012 Last Update: 07-04-2012 Installs: 40
Supported Uses Plugins Auto-Templates
Re-useable Code Additional Files Translations  

Brought to you by BirdOPrey5
www.Qapla.com





Live Demo: Mini-Calendar at Qapla.com

This mod adds a small "mini-calendar" on the header of every page, next to the logo image.

It uses the built in "ad location" called global_header1. If you use an ad in that spot (most people don't) you will need to move it prior to enabling this mod else it will not show.

If the Calendar doesn't show and you're on a custom style it is likely the style does not have the ad location coded in. See post #15 in this thread for a fix

There are settings but it is setup to work immediately after installing. Most settings should only be adjusted by advanced users. The font sizes and locations are setup for English day and month names- you may need to manually edit the headcalendar_bop5 template manually for it to look right in other languages.

You can use it as a link to the default vBulletin calendar (default behavior) or not. Also you can choose to disable it in specific styles if need be. Finally you can choose whether it displays the date based off the server's timezone or the user's timezone. (Default is user's timezone.)

New in Version 1.1 - Option to disable the display of the mini-calendar by usergroup. (Primary or secondary will work.)

I don't anticipate there will be much further development on this mod, it was just a simple thing I put together for one of my forums I figured like sharing- it already does everything I can think it needs to do, but if you have a suggestion that adds to the value I will consider it.

Each <div> has a unique id so you can use additional.css to make changes as needed.

You can see the default calendar is "blue" on top. Various other alternative color options are included in the download (red, green, yellow, and more...)

Tested as far back as VB 4.0.8 and as recent as 4.2.0 and expected to work on all 4.x versions.

Please "Mark as Installed" if you use this.
Donations Always Appreciated. :up:

Download Now

File Type: zip Header Calendar by BOP5 VB4 v1.1.1.zip (26.5 KB, 197 views)

Screenshots

File Type: jpg vb4_calendarmini_1.jpg (92.6 KB, 0 views)
File Type: jpg vb4_calendarmini_2.jpg (47.2 KB, 0 views)
File Type: jpg vb4_calendarmini_settings.jpg (115.9 KB, 0 views)

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.
Благодарность от:
TheLastSuperman

Comments
  #22  
Old 06-29-2012, 11:19 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Mr_Running View Post
User Group Permissions


I am drooling :up: with every passing day.
LOL... Here you go, version 1.1 released. :up:
Reply With Quote
  #23  
Old 06-30-2012, 12:31 AM
Mr_Running Mr_Running is offline
 
Join Date: May 2010
Posts: 536
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank You for release 1.1
Works but maybe one slight adjustment if a user is part of more than one usergroup who does not have permission it will not display.

How about using the Primary Users group?
Reply With Quote
  #24  
Old 06-30-2012, 12:42 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

To switch it to use primary groups go to Admin CP -> Plugin Manager

Edit the TWO plugins Calendar Setup and Cache Header Calendar...

In BOTH find the line:

Code:
!is_member_of($vbulletin->userinfo, explode(",", $vbulletin->options['bop5hc_groups'])) AND
and change them to:

Code:
!in_array($vbulletin->userinfo['usergroupid'], explode(",", $vbulletin->options['bop5hc_groups'])) AND
Then save the plugins.
Reply With Quote
  #25  
Old 06-30-2012, 02:02 AM
Mr_Running Mr_Running is offline
 
Join Date: May 2010
Posts: 536
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cheers,
Reply With Quote
Благодарность от:
BirdOPrey5
  #26  
Old 07-11-2012, 10:07 AM
WendM's Avatar
WendM WendM is offline
 
Join Date: Apr 2010
Location: DisUnited Kingdom
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

this is excellent, Joe!

How can I enlarge it , please?
Reply With Quote
  #27  
Old 07-11-2012, 11:04 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

The calendar background image is 60 x 60 pixels so enlarging it will show distortions in the image- and this was never designed to be enlarged.

But if you want to try it can all be done by adding code to additional.css - for example add this:

Code:
#bop5headcalmain {
  height:90px !important;
  width:90px !important;
  background-size: 100%;
}
That will make the calendar background image 90x90 instead of 60x60, but you will still need to do custom code for each of the text lines including the new custom widths and new font sizes, and new spacing in pixels (top values in CSS.)
Reply With Quote
  #28  
Old 07-11-2012, 11:10 AM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here is the complete code to go to 80x80... you can customize the font sizes as you want.

Code:
#bop5headcalmain {
  height:80px !important;
  width:80px !important;
  background-size: 100%;
}
#bop5headcalmonth {
  top:18px !important;
  width:80px !important;
  font-size: 8pt !important;
}
#bop5headcalweek {
  top:33px !important;
  width:80px !important;
  font-size: 8pt !important;
}
#bop5headcalday {
  top:45px !important;
  width:80px !important;
}
Reply With Quote
Благодарность от:
WendM
  #29  
Old 07-11-2012, 12:02 PM
WendM's Avatar
WendM WendM is offline
 
Join Date: Apr 2010
Location: DisUnited Kingdom
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

many thanks, Joe! One more thing...how can I move it down a notch, please?
Reply With Quote
  #30  
Old 07-11-2012, 01:45 PM
WendM's Avatar
WendM WendM is offline
 
Join Date: Apr 2010
Location: DisUnited Kingdom
Posts: 51
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK, for those who want to know how to push the image down to their own height, then do this:

Open Template: headcalendar_bop5

find: position:relative;

then next to it place this: top:20px;

adjust the number to suit your own position!

demo here:
http://www.hottopowners.co.uk/forum.php
Reply With Quote
Благодарность от:
BirdOPrey5
  #31  
Old 07-11-2012, 03:08 PM
BirdOPrey5's Avatar
BirdOPrey5 BirdOPrey5 is offline
Senior Member
 
Join Date: Jun 2008
Location: New York
Posts: 10,610
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WendM View Post
OK, for those who want to know how to push the image down to their own height, then do this:

Open Template: headcalendar_bop5

find: position:relative;

then next to it place this: top:20px;

adjust the number to suit your own position!

demo here:
http://www.hottopowners.co.uk/forum.php
You can also add it to additional.css so you don't have to edit the template if you want:

Code:
#bop5headcalmain {
  top:20px;
}
In general it's good to avoid editing templates because they will need to be reverted if the mod is ever upgraded and changes made to the template.
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 08:45 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.05357 seconds
  • Memory Usage 2,353KB
  • Queries Executed 26 (?)
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
  • (5)bbcode_code
  • (2)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
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (4)post_thanks_box_bit
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (4)post_thanks_postbit
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (4)postbit_attachment
  • (11)postbit_onlinestatus
  • (11)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