Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
Details »»

Version: , by wajones wajones is offline
Developer Last Online: Apr 2014 Show Printable Version Email this Page

Version: 2.2.x Rating:
Released: 11-02-2001 Last Update: Never Installs: 50
 
No support by the author.

As requested, here is the small calendar from vbPortal.
I want to also give credit to one of my users "rabidmoogle" for help in optimizing my original hack.

It's a standalone file, with the template included for testing.
1. Create a new template called "small_calendar"
2. Cut and paste the included template from the script into the new template.
3. rename the cal.php.txt to cal.php and copy it to your forums directory and run to test.
4. Cut and paste the code between the <?php and ?> to the location of your choice to use in another script.

Show Your Support

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

Comments
  #22  
Old 11-08-2001, 12:09 AM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i don't know about that .shtml page thing.

so it doesn't show a link for birthdays right now? mine does... i think. www.macsubculture.com/dev/
Reply With Quote
  #23  
Old 11-08-2001, 12:10 AM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

9th and 11th on my calendar... but i think those were put in manually by those people. i have birthdays disabled.
Reply With Quote
  #24  
Old 11-08-2001, 04:14 AM
JJR512's Avatar
JJR512 JJR512 is offline
 
Join Date: Oct 2001
Location: Glen Burnie, MD, USA
Posts: 710
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've discovered a problem on my board that was solved after disabling this hack. I'd like someone else to confirm or deny that they have the same problem.

One of my users told me that after saving changes to her profile, her birthday showed up in her edit profile screen as Nov 31, 2001. Now that is an invalid date to begin with. When looking at her profile, it shows up as Dec. 1 (no year). She can go back to her profile and change it, but after saving it, the changes to do not remain, they don't stick. Now if I edit the database directly, the changes there do stick, so I rules out a database problem and determined it had to be a script problem somewhere.

The problem went away when I removed the include 'cal.php'; statement from the phpinclude template.
Reply With Quote
  #25  
Old 11-08-2001, 03:49 PM
Alien's Avatar
Alien Alien is offline
 
Join Date: Oct 2001
Posts: 827
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Heya!

Yeah they were put in manually, that's why it's triggering the link.. I want it to also trigger the link if their are no events but their ARE birthdays.

Well, hopefully someone can help on that one sometime.. Now I gotta figure out how to get this to work on a php include on a .shtml page.. <sigh>

Quote:
Originally posted by Jakeman
9th and 11th on my calendar... but i think those were put in manually by those people. i have birthdays disabled.
Reply With Quote
  #26  
Old 11-08-2001, 04:39 PM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i can confirm the birthday submit bug. i don't use birthdays though so it doesn't really matter for me.
Reply With Quote
  #27  
Old 11-09-2001, 03:12 AM
jarvis jarvis is offline
 
Join Date: Nov 2001
Posts: 96
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I'm trying to play around with the small_calendar template, but am not having any luck trying to narrow down the size of the mini-calendar.

I've tried changing the table width, but it still seems to look the same every time. I'm no HTML guru, but any help would be greatly appreciated.

Thanks!!
Reply With Quote
  #28  
Old 11-28-2001, 05:56 AM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i am attempting to add a condition that displays the text "No Events Today" if there are no events on that day. When i added the else to this block of code it worked for showing no events for the day but it had the side effect of only showing a max of one event for the day even if there are more than one. i'm referring to the $todaysevents var. i am not sure of the logic i should use here. any help?

Code:
while ($event=$DB_site->fetch_array($events)) {
  if ($event[eventdate]==vbdate("Y-m-d",time())) {
    $eventsubject=htmlspecialchars($event[subject]);
    $todaysevents="
		<li><smallfont><b><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\">$eventsubject</a></b></smallfont></li>";
  } else {
    $todaysevents="<li><smallfont><b>No Events Today</b></smallfont></li>";
    }
}
Reply With Quote
  #29  
Old 12-02-2001, 05:15 PM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i also noticed a problem on the evening of Nov 30. it seems that the month rotation is based on the server time without accounting for the user's time offset. but then the linked days are for whatever month it is after taking the time offset into account. so then when you click on days it takes you to the next month instead of the previous month. dunno if this makes sense.

wajones, i think you aren't taking the user's time offset into consideration for all parts of the calendar.

...still didn't get that 'No events today' condition working.
Reply With Quote
  #30  
Old 12-05-2001, 06:58 AM
Jakeman's Avatar
Jakeman Jakeman is offline
 
Join Date: Nov 2001
Posts: 273
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i got the 'No Events Today' condition working. instructions for those that want to add this:

find:

Code:
while ($event=$DB_site->fetch_array($events)) {
  if ($event[eventdate]==vbdate("Y-m-d",time())) {
    $eventsubject=htmlspecialchars($event[subject]);
    $todaysevents.="
		<li><smallfont><b><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\">$eventsubject</a></b></smallfont></li>";
  }
}
after it add this:

Code:
if (!$todaysevents) {
    $todaysevents="<li><smallfont><b>No Events Today</b></smallfont></li>";
    }
i did it all by myself! woo woo!
Reply With Quote
  #31  
Old 01-27-2002, 12:00 PM
Craig Antill Craig Antill is offline
 
Join Date: Nov 2001
Posts: 24
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How do I include this on a non vB .php page ??

I get the following error:

Quote:
Warning: Failed opening 'global.php' for inclusion (include_path='.:/usr/local/lib/php') in /usr/www/craig/craigantill/html/forum/cal.php on line 4

Fatal error: Call to undefined function: vbdate() in /usr/www/craig/craigantill/html/forum/cal.php on line 9
Reply With Quote
Reply

Thread Tools

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:44 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.05148 seconds
  • Memory Usage 2,303KB
  • 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
  • (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