Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Mini Calendar Details »»
Mini Calendar
Version: 1.00, by Colin F Colin F is offline
Developer Last Online: Apr 2014 Show Printable Version Email this Page

Version: 3.0.3 Rating:
Released: 08-07-2004 Last Update: Never Installs: 38
Re-useable Code Translations  
No support by the author.

Mini Calendar

What it does:
The Mini Calendar is just what it's name says. It allows you to add a small calendar to any or all vBulletin page(s). It links back to the month, next and previous month as well as any days with an event.

Is it complicated?
Installation is easy. Just include the cal.php file on any page that you want it shown, make one new template and insert $smallcalendar at the exact place you want it shown. Look at the instructions below.

Changes:
New files (1):
cal.php

Changed files(0-1):
depending on where it should be shown

New database fields/tables(0):
none

New templates(1):
small_calendar

Changed templates(1-2):
wherever mini calendar should be shown
(phpinclude_start, if shown on all pages)

New phrases(0):
none

Screenshots:
see attachmentsInstructions:
  • Backup all your files as well as your database.
    For help backing up your database, look here: http://www.vbulletin.com/docs/html/m...atabase_backup
  • Upload cal.php (attachment) to your forum home directory
  • Make a new template with the name small_calendar and insert the contents of template.txt (attachment) into it
  • Decide if you want to have your mini calendar on specific pages or on all your pages
    • If you decide to have the mini calendar on all your pages (for example in a sidebar) edit your phpinclude_start template and add
      PHP Code:
      include ("cal.php"); 
      to the end of it.
    • If you only want the mini calendar on specific pages, open the php file that makes that page and under
      PHP Code:
      require_once('./global.php'); 
      add
      PHP Code:
      include ("cal.php"); 
  • edit the template that shows the area in which you want to insert your mini calendar and add $smallcalendar to the exact spot where your mini calendar should be shown.
Donations: This hack will always be free, however your donations are kindly accepted and will help towards further development. If you donate, please leave me some info (either your forum site or username at vB.org) so that I can thank you.

Install:
Don't feel like donating, but still want to thank me for my work? Click the install button to show your appreciation. As a great side effect, you'll get an email update once there is a bigger update or important security fix!

Updates:
10.08.2004: Updated cal.php to fix (hopefully) the events being on the wrong day with far out timezones.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 08-12-2004, 04:50 PM
PUPSTAHS PUPSTAHS is offline
 
Join Date: Jul 2004
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Colin F
I also don't use ranged events on my calendar

But I'll look into it aswell when I get home this evening.
Hehe... yea, it'd just be a cool feature to have. Also having the preview text for the day's events when you hover over the link would be damn cool.

If you don't get around to it I might give it a shot down the line.
Reply With Quote
  #23  
Old 08-12-2004, 05:27 PM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Can you try it with this file?

I did something for the ranged events...

Eventpreview is kind of complicated. What should I do if there are 5 events? which one is the first?
Reply With Quote
  #24  
Old 08-12-2004, 06:32 PM
PUPSTAHS PUPSTAHS is offline
 
Join Date: Jul 2004
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'd say ignore the ordering... it's more of a nice small feature than anything that should be robust, in my opinion... so just grab the events so people can see what's going on.

As for the ranged events... very close to working. The one bug I have seems to be related to timezone offset. Since I'm PST (-8), any event 4pm or after is showing up for the next day instead.
Reply With Quote
  #25  
Old 08-12-2004, 07:03 PM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Any event that starts 4pm or after is showing up for the next day....

Can you check if this is only for ranged events or also for recurring events?
If so, then it's most probably the utc field in the database...
Reply With Quote
  #26  
Old 08-12-2004, 07:10 PM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Here's an updated file, try this and tell me if it works please...
Reply With Quote
  #27  
Old 08-12-2004, 08:43 PM
PUPSTAHS PUPSTAHS is offline
 
Join Date: Jul 2004
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm, that just seems to have pushed the threshold back an hour, to 5pm. The bug happens with any event that allows you to schedule a time.

Anytime that's 5pm or after appears for the next day. So if I have a single-day ranged event from 9pm-11pm on August 10th, the link will appear on August 11th.
Reply With Quote
  #28  
Old 08-13-2004, 04:17 AM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by PUPSTAHS
Hmm, that just seems to have pushed the threshold back an hour, to 5pm. The bug happens with any event that allows you to schedule a time.

Anytime that's 5pm or after appears for the next day. So if I have a single-day ranged event from 9pm-11pm on August 10th, the link will appear on August 11th.
Now that's unusual... I have no idea why it should push it back only 1 hour...
Reply With Quote
  #29  
Old 08-13-2004, 05:46 AM
spence2 spence2 is offline
 
Join Date: Jun 2002
Location: usa
Posts: 284
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Daylight Savings Time?
Reply With Quote
  #30  
Old 08-13-2004, 10:12 AM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I don't see how it can be daylight savings time, as I "actually" didn't touch anything that has to do with that. Thanks for the input though...

Why dont you try changing the three occurences of $theday = date( to $theday = gmdate(

I'll also look into changing the thing checking the date, if that doesn't solve the problem.
Reply With Quote
  #31  
Old 08-13-2004, 07:44 PM
PUPSTAHS PUPSTAHS is offline
 
Join Date: Jul 2004
Posts: 15
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok it has to be a time-zone bug. Because when you enter calendar event data it allows you to choose the timezone, so vbulletin must be doing some additional calculations based on the user's own timezone selection, and the timezone for which the event was added.

Pacific Time (for both event and user setting):
August 14th 8am - 4:30pm ---works fine
August 14th 8am - 5:00pm ---links the 15th as well
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 01:45 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.04300 seconds
  • Memory Usage 2,316KB
  • 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_php
  • (2)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (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
  • 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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete