Back to vBulletin 3.0 Add-Ons

Calendar Search and Comments for Events
Mod Version: 1.00, by deathemperor

This modification is in the archives.
vB Version: 3.0.7 Rating: (2 votes - 5.00 average) Installs: 26
Released: 16 Mar 2005 Last Update: 15 Sep 2005 Downloads: 21
Supported DB Changes  

This hack I made was a paid request by , the thread can be found here: index.php?t=74337 . He and I want to release this to public because Lee Wilde believed that there're alot of members looking for this.

*UPDATE: 03/28/2005

If you installed this hack before 03/28/2005, to fix search bugs please rehack the file calendar.php

*UPDATE: 03/23/2005

Fixed 2 table_prefix mistaken, please read this post:

Spoiler (click to open)


OOPS !

my bad mistake, I missed 2 table_prefix.

TO FIX:

IN calendar.php FIND:

PHP Code:
    // calculating which page the comment edited or posted is in
    
$perpage $vboptions['evecomperpage'];
    
$countq $DB_site->query("SELECT * FROM eventcomments WHERE eventid=$e");
    
$evecomcount $DB_site->num_rows($countq);
    
$evepage ceil($evecomcount/$perpage);
    
// query the newest comment
    
$thisevecom $DB_site->query_first("SELECT evecomid FROM eventcomments WHERE evecomtitle = '" addslashes($title) . "' ORDER BY evecomdateline DESC LIMIT 1");
    
$url "calendar.php?$session[sessionurl]do=getinfo&e=$e&page=$evepage#comment$thisevecom[evecomid]";
    eval(
print_standard_redirect('redirect_postthanks'));

REPLACE WITH:

PHP Code:
    // calculating which page the comment edited or posted is in
    
$perpage $vboptions['evecomperpage'];
    
$countq $DB_site->query("SELECT * FROM " TABLE_PREFIX "eventcomments WHERE eventid=$e");
    
$evecomcount $DB_site->num_rows($countq);
    
$evepage ceil($evecomcount/$perpage);
    
// query the newest comment
    
$thisevecom $DB_site->query_first("SELECT evecomid FROM " TABLE_PREFIX "eventcomments WHERE evecomtitle = '" addslashes($title) . "' ORDER BY evecomdateline DESC LIMIT 1");
    
$url "calendar.php?$session[sessionurl]do=getinfo&e=$e&page=$evepage#comment$thisevecom[evecomid]";
    eval(
print_standard_redirect('redirect_postthanks'));

zip updated.

Close


*UPDATE: 03/17/2005 fixed avatar disable problem and a minor wrong in instructions.txt

TO FIX avatar disable:

FIND:

PHP Code:
SELECT eventcomments.*, event.lastevecomdateline,user.*,userfield.*,usertextfield.signature customavatar.dateline AS avatardateline FROM " . TABLE_PREFIX . "eventcomments AS eventcomments 
REPLACE WITH:

PHP Code:
SELECT eventcomments.*, event.lastevecomdateline,user.*,userfield.*,usertextfield.signature " . iif($vboptions['avatarenabled'], "customavatar.dateline AS avatardateline") . " FROM " . TABLE_PREFIX . "eventcomments AS eventcomments 


What does this hack do ?

Give your users ability to search for Events on Calendar.
Ability to add comments for events.

The permission is usergroup based:
  • Viewing permission.
  • Post Comments.
  • Edit Own comments.
  • Edit Others comments.
  • Delete Own comments.
  • Delete Other comments.
  • Search Events.


Files edit: 3
New Template: 7
Templates Edit:1
Database: 1 new table, 2 new column for table 'event'.

Installation time: less than 10 minutes.

Screenshots: (thanks to Lee Wilde).

Search Events:

event_with_quickreply_enabled :
event_with_reply_added :

Credits: The installer I use is from V3 Article with permission from John so the credit goes to him.

Last words: I will try to help with all the problems *in cases* may occur.

Download

This modification is archived and cannot be downloaded.

Similar Mods

Calendar Search and Comments for Events vBulletin 3.5 Add-ons

vblts.ru supports vBulletin®, 2022-2024