vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Mini Calendar from vbPortal (https://vborg.vbsupport.ru/showthread.php?t=32087)

catocom2 03-21-2003 09:46 PM

Well,
it seems I do have some other problems. :(
I'm gonna have to backup through the stagged backups
I've made, and see if I can see where the other problems
are coming from.

pdatoon 05-07-2003 03:26 PM

Quote:

10-23-02 at 09:32 AM SpankMe said this in Post #59
Just installed this hack on my newly started Kiwi Biker forums . It going to be an excellent tool for help users keep track of current and furture motorbike events.

Hazaar to wajones :D


Hi man,

I have seen that you had Event today and Coming events listed at the bottom of the small calendar. Could you tell me how you do that? Mine just have the calendar :surprised:

pdatoon 05-08-2003 09:11 AM

Anyone? :(

gmarik 05-24-2003 08:39 AM

Guys, how is it with 2.3?

CatholicSin 06-15-2003 03:24 PM

I am curious, what does this error message mean (what did I do wrong with my install?) if anyone can help it would be great.


Quote:

Fatal error: Call to undefined function: vbdate() in /home/lochlain/domainname/docs/TMP3lgljgj6wr.php on line 141

mbowers 06-30-2003 03:33 AM

Just installed this (w/ myvbindex) - pretty cool hack. Just wondering, where it shows today's event underneath the calendar, is it possible to have that text change when you rollover other dates that have events posted? Like, let's say it's Thursday, and Thursday is user BoBo's birthday. On Friday, someone has posted a calendar event for BoBo's birthday party. If you rollover Friday's date, the text changes from "Today's Events: BoBo's Birthday!" to "Events for Friday, June 27th: BoBo's Birthday Party"...

...you get the idea..

Mbow

bosix 08-02-2003 11:34 PM

Quote:

01-31-02 at 10:18 PM sccr410 said this in Post #31
Do you have it in the 'forum' directory? I just installed this hack ( http://www.sandiegopegasus.com ) and it worked perfectly.


puff anyone help me

I showing my calender non-vbpage like http://www.sandiegopegasus.com site.

my calender showing cal.php www.electronicafe.com/forum/cal.php

and future events show smp: in 15 days birthdays & public events


Sorry My english bad :(

Russ_T 12-18-2003 08:45 PM

Ok its been working fine with myvbindex for a while now but I would like to change it so instead of showing todays events, it shows upcoming events (and I specify in my php say the next fortnight).

I've tried to do this myself but to no avail, anyone fancy working with me on it? I think it would be a good change to the mod (if wajones is too busy to help of course).

Thanks for the mod wajones!

WeBBy 12-19-2003 04:43 AM

I installed this calendar on a site I am building and I love it! :D It was just the ticket I needed....

But, I did notice that many of my errors (doin allot of mods), all have this "// End of vbPortal calendar script" showing up, even though the script may not even be called at the time. Anyway, that I can live with and so I forgot about it.

You can check it out by simply going to http://www.basementsystems.com/dealerarea/. You get an error because the index.php file needs a specific template in order to work. The actual error is no template for the index.php to use, so blank page. But why the cal script end comment????

Now, I installed the OakGalley hack and I cannot upload any images. The reason seems to be the cal.php script. This is the error I am getting:

Warning: Cannot modify header information - headers already sent by (output started at /home3/www/basementsystems/dealerarea/cal.php:121) in /home3/www/basementsystems/dealerarea/gallery/upload_handle.php on line 108

So, it would seem that cal.php is running in the background or something. I also noticed, about the time I installed the script, that pages will not auto-redirect anymore (haven't tried to fix that yet), but now I am thinking that maybe this is all inter-related.

Any ideas? Any help?

Thanx

EDIT: IGNORE THIS POST (I really should just delete this post but maybe someone is as stupid as I am and will be helped by it). Removing the end comment "<-- End of vbPortal calendar script" solved the whole problem. What a dumb ass .. lol :O

Russ_T 12-26-2003 11:10 PM

Ok heres my little contribution. It's a quick and dirty fix but it's the only way I could think to do it using the current structure and not knowing any sql didn't help. I really need a book.

Ok in index.php replace

Quote:

// vbPortal mini calendar - by wajones
if ($showcalendar) {
$year = date('Y');
$doublemonth = vbdate('m',time());
$month = date('n');
$day = '1';
$today = vbdate('m-d',time());
$events=$DB_site->query("SELECT eventdate,subject,eventid,public FROM calendar_events WHERE eventdate LIKE '$year-$doublemonth-%' AND ((userid='$bbuserinfo[userid]' AND public='0') OR (public='1'))");
while ($event=$DB_site->fetch_array($events)) {
if ($showtodaysevents AND $event[eventdate]==vbdate('Y-m-d',time())) {
$eventsubject = htmlspecialchars($event['subject']);
if ($event['public']=='1') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calpubliccolor}\">$eventsubject</smallfont></a></li>";
}
if ($event['public']=='0') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calprivatecolor}\">$eventsubject</smallfont></a></li>";
}
eval("\$eventstoday = \"".gettemplate('index_calendar_todaysevents')."\" ;");
}
}
if (!$bbuserinfo['startofweek']) {
$bbuserinfo['startofweek'] = '1';
}

with


Quote:

if ($showcalendar) {
$year = date('Y');
$doublemonth = vbdate('m',time());
$month = date('n');
$day = '1';
$today = vbdate('m-d',time());
$events=$DB_site->query("SELECT eventdate,subject,eventid,public FROM calendar_events WHERE eventdate LIKE '$year-$doublemonth-%' AND ((userid='$bbuserinfo[userid]' AND public='0') OR (public='1')) ORDER BY eventdate");
while ($event=$DB_site->fetch_array($events)) {
$thetime = time();
for ($i = 0; $i < 14; $i++) {
if ($showtodaysevents AND $event[eventdate]==vbdate('Y-m-d',$thetime)) {
$eventsubject = htmlspecialchars($event['subject']);
if ($event['public']=='1') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calpubliccolor}\">$eventsubject</smallfont></a></li>";
}
if ($event['public']=='0') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calprivatecolor}\">$eventsubject</smallfont></a></li>";
}
eval("\$eventstoday = \"".gettemplate('index_calendar_todaysevents')."\" ;");
}
$thetime = $thetime + 86400;
}
}
if (!$bbuserinfo['startofweek']) {
$bbuserinfo['startofweek'] = '1';
}

$enddate = time() + 1209600;
$doublemonth = vbdate('m',$enddate);
$year = vbdate('Y',$enddate);

$events=$DB_site->query("SELECT eventdate,subject,eventid,public FROM calendar_events WHERE eventdate LIKE '$year-$doublemonth-%' AND ((userid='$bbuserinfo[userid]' AND public='0') OR (public='1')) ORDER BY eventdate");
while ($event=$DB_site->fetch_array($events)) {
$thetime = time();
for ($i = 0; $i < 14; $i++) {
if ($showtodaysevents AND $event[eventdate]==vbdate('Y-m-d',$thetime)) {
$eventsubject = htmlspecialchars($event['subject']);
if ($event['public']=='1') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calpubliccolor}\">$eventsubject</smallfont></a></li>";
}
if ($event['public']=='0') {
$todaysevents .= "<li><a href=\"$bburl/calendar.php?s=$session[sessionhash]&action=getinfo&eventid=$event[eventid]\"><smallfont color=\"{calprivatecolor}\">$eventsubject</smallfont></a></li>";
}
eval("\$eventstoday = \"".gettemplate('index_calendar_todaysevents')."\" ;");
}
$thetime = $thetime + 86400;
}
}

if (!$bbuserinfo['startofweek']) {
$bbuserinfo['startofweek'] = '1';
}

$year = date('Y');
$doublemonth = vbdate('m',time());
$events=$DB_site->query("SELECT eventdate,subject,eventid,public FROM calendar_events WHERE eventdate LIKE '$year-$doublemonth-%' AND ((userid='$bbuserinfo[userid]' AND public='0') OR (public='1')) ORDER BY eventdate");
while ($event=$DB_site->fetch_array($events)) {}
Then just alter the index_calendar_todaysevents template to read something like

Next fortnight's events

instead of

Today's events


And that should work fine.

BUT this horrid work around adds two more queries to your home page and is generally horrid. Now can someone with some skill and time turn that code into something pretty please?

All credit to wajones for the original code for me to hack about though. Thank you.


(working demo at http://www.zclub.net :) )


All times are GMT. The time now is 12:04 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01871 seconds
  • Memory Usage 1,760KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete