Back to vBulletin 3.7 Template Modifications

Upcoming Events at top of forumhome
Mod Version: 1.00, by dismas

This modification is in the archives.
vB Version: 3.7.x Rating: (2 votes - 3.00 average) Installs: 21
Released: 09 Dec 2008 Last Update: Never Downloads: 1
Not Supported Template Edits  

If your site uses the calendar feature, you may want to better publicize events on the forumhome. The default location of the "What's going on?" box is all the way at the bottom of forumhome and is pretty easy to never even see.

So, if you'd like to put another copy of the upcoming events and the day's birthdays at the top of the forums:

First, find your FORUMHOME template.

Go to:
AdminCP > Styles & Templates > Search in Templates > input FORUMHOME & search titles only > edit

Find:
Code:
<!-- / guest welcome message -->
<br />
</if>
Just below that add:
Code:
<!-- what's going on box -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<if condition="$show['birthdays']">
<!-- today's birthdays -->
<tbody>
	<tr>
		<td class="thead" colspan="2">
			<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_birthdays')"><img id="collapseimg_forumhome_birthdays" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_birthdays].gif" alt="" border="0" /></a>
			$vbphrase[todays_birthdays]
		</td>
	</tr>
</tbody>
<tbody id="collapseobj_forumhome_birthdays" style="$vbcollapse[collapseobj_forumhome_birthdays]">
	<tr>
		<td class="alt2"><a href="calendar.php?$session[sessionurl]do=getday&amp;day=$today&amp;sb=1"><img src="$stylevar[imgdir_misc]/birthday.gif" alt="$vbphrase[view_birthdays]" border="0" /></a></td>
		<td class="alt1" width="100%"><div class="smallfont">$birthdays</div></td>
	</tr>
</tbody>
<!-- end today's birthdays -->
</if>
<if condition="$show['upcomingevents']">
<tbody>
	<tr>
		<td class="thead" colspan="2">
			<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_events')"><img id="collapseimg_forumhome_events" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_events].gif" alt="" border="0" /></a>
			<if condition="$show['todaysevents']">$vbphrase[todays_events]<else /><phrase 1="$vboptions[showevents]">$vbphrase[upcoming_events_for_the_next_x_days]</phrase></if>
		</td>
	</tr>
</tbody>
<tbody id="collapseobj_forumhome_events" style="$vbcollapse[collapseobj_forumhome_events]">
	<tr>
		<td class="alt2"><a href="calendar.php$session[sessionurl_q]"><img src="$stylevar[imgdir_misc]/calendar.gif" alt="$vbphrase[calendar]" border="0" /></a></td>
		<td class="alt1" width="100%"><div class="smallfont">$upcomingevents</div></td>
	</tr>
</tbody>
</if>
</table>
<!-- end what's going on box -->
<br />


If want just the upcoming events without the birthdays, then use this:
Code:
<!-- what's going on box -->
<if condition="$show['upcomingevents']">
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<tbody>
	<tr>
		<td class="thead" colspan="2">
			<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_events')"><img id="collapseimg_forumhome_events" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_events].gif" alt="" border="0" /></a>
			<if condition="$show['todaysevents']">$vbphrase[todays_events]<else /><phrase 1="$vboptions[showevents]">$vbphrase[upcoming_events_for_the_next_x_days]</phrase></if>
		</td>
	</tr>
</tbody>
<tbody id="collapseobj_forumhome_events" style="$vbcollapse[collapseobj_forumhome_events]">
	<tr>
		<td class="alt2"><a href="calendar.php$session[sessionurl_q]"><img src="$stylevar[imgdir_misc]/calendar.gif" alt="$vbphrase[calendar]" border="0" /></a></td>
		<td class="alt1" width="100%"><div class="smallfont">$upcomingevents</div></td>
	</tr>
</tbody>
</table>
</if>
<!-- end what's going on box -->
<br />


In both of these examples, I've removed the header that says "What's Going On?". If you'd rather have that, then do this:

After:
Code:
<!-- what's going on box -->
Put:
Code:
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center">
<thead>
	<tr>
		<td class="tcat" colspan="2">$vbphrase[whats_going_on]</td>
	</tr>
</thead>
Save the template and you're done.

Download

No files for download.

Screenshots

Click image for larger version
Name:	events.jpg
Views:	829
Size:	22.2 KB
ID:	90373  


vblts.ru supports vBulletin®, 2022-2024