|
Add Videos & Photos to Calendar Events Linked to Threads
I couldn't come up with a short, descriptive name for this that was catchy but here is what this does:
The end user can link events from the calendar to an active thread or auto-generate a new thread and then add videos from Youtube and photos from your albums. The plugin also provides a sponsor box that can be edited to include adsense or other advertisements. Notes:
Important vBulletin 4.0 Notice I am giving this code to the community and would like someone to convert it to 4.0.x Installation: 1) File Edits: ----------- In file admincp/admincalendar.php Find: print_yes_no_row($vbphrase['allow_smilies'], 'options[allowsmilies]', $calendar['allowsmilies']); Add after: print_forum_chooser($vbphrase['autothreadforumid'], 'calendar[autothreadforumid]', $calendar['autothreadforumid'], $vbphrase['none']); 2) Template edits: --------------- calendar_showeventsbit Find: <div>$eventinfo[event]</div> Replace with: <table style="width:100%;" cellpadding="$stylevar[cellpadding]" border="0"> <tr> <td valign="top" colspan="2" style="width:50%;">$eventinfo[event]</td> <td valign="top" colspan="2" style="width:50%;">$results</td> <td valign="top" colspan="2"><if condition="$results || $videos || $photos"><div style="width:200px;height:120px;border:1px solid #000000;">Sponsor Box...</div></if></td> </tr> <tr> <td valign="top" colspan="3" style="width:50%;">$videos</td> <td valign="top" colspan="3" style="width:50%;">$photos</td> </tr> </table> Find: </form> Add after: $discussion Find: <td class="tcat">$eventinfo[title]</td> Replace with: <td class="tcat"><if condition="THIS_SCRIPT=='showthread'">$vbphrase[linked_event]: </if><a href="calendar.php?do=getinfo&e=$eventinfo[eventid]">$eventinfo[title]</a></td> calendar_edit Find: $disablesmiliesoption Add after: <label for="cb_makethread"><input type="checkbox" name="makethread" value="1" id="cb_makethread" tabindex="1" checked="checked" />$vbphrase[auto_generate_discussion_thread]</label> album_picture_upload and album_edit Find the last occurrence of: <input type="hidden" name="s" value="$session[sessionhash]" /> Add after: <input type="hidden" name="eventid" value="$eventid" /> SHOWTHREAD Find: $poll Add after: $event newthread Find: <input type="hidden" name="posthash" value="$posthash" /> Add after: <input type="hidden" name="eventid" value="$eventid" /> 3) Upload kce-newthread.php to forums/includes/cron Download
|
|||||||||