diff options
| author | Max Kremmel <xing@synapse.plus.com> | 2005-08-21 12:38:05 +0000 |
|---|---|---|
| committer | Max Kremmel <xing@synapse.plus.com> | 2005-08-21 12:38:05 +0000 |
| commit | 59a461a3e5a76b10b1b154975544a9eefa617e02 (patch) | |
| tree | acd415360aba73d9557d514ece690e346164b9a1 /modules | |
| parent | f0a51ae92c7b47cd637a9fa17f768cb494fac222 (diff) | |
| download | calendar-59a461a3e5a76b10b1b154975544a9eefa617e02.tar.gz calendar-59a461a3e5a76b10b1b154975544a9eefa617e02.tar.bz2 calendar-59a461a3e5a76b10b1b154975544a9eefa617e02.zip | |
fix module calendar and other minor stuff
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/mod_calendar.php | 14 | ||||
| -rw-r--r-- | modules/mod_calendar.tpl | 32 |
2 files changed, 21 insertions, 25 deletions
diff --git a/modules/mod_calendar.php b/modules/mod_calendar.php index 1e93e0a..a89ca9d 100644 --- a/modules/mod_calendar.php +++ b/modules/mod_calendar.php @@ -20,13 +20,13 @@ $calHash = array( // set up daynames for the calendar $dayNames = array( - tra( "Mon" ), - tra( "Tue" ), - tra( "Wed" ), - tra( "Thu" ), - tra( "Fri" ), - tra( "Sat" ), - tra( "Sun" ), + tra( "Monday" ), + tra( "Tuesday" ), + tra( "Wednesday" ), + tra( "Thursday" ), + tra( "Friday" ), + tra( "Saturday" ), + tra( "Sunday" ), ); // depending on what day we want to view first, we need to adjust the dayNames array diff --git a/modules/mod_calendar.tpl b/modules/mod_calendar.tpl index 837acd5..0606d37 100644 --- a/modules/mod_calendar.tpl +++ b/modules/mod_calendar.tpl @@ -1,49 +1,45 @@ {bitmodule title="$moduleTitle" name="calendar"} - <table> - <caption>{$modCalNavigation.focus_date|date_format:"%B"}</caption> + <table class="caltable"> + <caption>{$modCalNavigation.focus_date|date_format:"%B %Y"}</caption> <tr> <td style="text-align:left;"> - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$navigation.before.month}&{$url_string}" title="{$navigation.before.month|bit_long_date}">«{tr}m{/tr}</a><br /> + <a href="{$smarty.server.PHP_SELF}?todate={$modCalNavigation.before.year}&{$url_string}" title="{$modCalNavigation.before.year|bit_long_date}">«{tr}y{/tr}</a> </td> <td style="text-align:left;"> - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$navigation.before.year}&{$url_string}" title="{$navigation.before.year|bit_long_date}">«{tr}y{/tr}</a> + <a href="{$smarty.server.PHP_SELF}?todate={$modCalNavigation.before.month}&{$url_string}" title="{$modCalNavigation.before.month|bit_long_date}">«{tr}m{/tr}</a><br /> </td> <td colspan="3" style="text-align:center;"> - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$smarty.now}&{$url_string}" title="{$smarty.now|bit_long_date}">{tr}Today{/tr}</a> + <a href="{$smarty.server.PHP_SELF}?todate={$smarty.now}&{$url_string}" title="{$smarty.now|bit_long_date}">{tr}Today{/tr}</a> </td> <td style="text-align:right;"> - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$navigation.after.month}&{$url_string}" title="{$navigation.after.month|bit_long_date}">{tr}m{/tr}»</a><br /> + <a href="{$smarty.server.PHP_SELF}?todate={$modCalNavigation.after.month}&{$url_string}" title="{$modCalNavigation.after.month|bit_long_date}">{tr}m{/tr}»</a><br /> </td> <td style="text-align:right;"> - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$navigation.after.year}&{$url_string}" title="{$navigation.after.year|bit_long_date}">{tr}y{/tr}»</a> + <a href="{$smarty.server.PHP_SELF}?todate={$modCalNavigation.after.year}&{$url_string}" title="{$modCalNavigation.after.year|bit_long_date}">{tr}y{/tr}»</a> </td> </tr> <tr> {foreach from=$dayNames item=name} - <th width="14%">{$name}</th> + <th width="14%">{$name|truncate:"1":""}</th> {/foreach} </tr> - {foreach from=$modCalMonth key=week_num item=week} + {foreach from=$modCalMonth item=week} <tr> {foreach from=$week item=day} - {if $smarty.session.calendar.view_mode eq "month"} - {if $day.day|date_format:"%m" eq $modCalNavigation.focus_month} - {cycle values="odd,even" print=false advance=false} - {else} - {cycle values="notmonth" print=false advance=false} - {/if} - {else} + {if $day.day|date_format:"%m" eq $modCalNavigation.focus_month} {cycle values="odd,even" print=false advance=false} + {else} + {cycle values="notmonth" print=false advance=false} {/if} <td class="{cycle}" style="text-align:right;"> - {if $day.day|date_format:"%m" eq $modCalNavigation.focus_month or $smarty.session.calendar.view_mode eq "week"} + {if $day.day|date_format:"%m" eq $modCalNavigation.focus_month} {if $day.day eq $modCalNavigation.focus_date}<strong>{/if} - <a href="{$gBitLoc.CALENDAR_PKG_URL}index.php?todate={$day.day}&{$url_string}">{$day.day|date_format:"%d"}</a> + <a href="{$smarty.const.CALENDAR_PKG_URL}index.php?todate={$day.day}&{$url_string}">{$day.day|date_format:"%d"}</a> {if $day.day eq $modCalNavigation.focus_date}</strong>{/if} {else} |
