aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChad Little <clittle@users.sourceforge.net>2004-02-06 18:26:49 +0000
committerChad Little <clittle@users.sourceforge.net>2004-02-06 18:26:49 +0000
commit07effdabb09a9f27198ea0ac3cab678a221c2b44 (patch)
tree976c256aaec3e6c7165874173397c59cd6458816
parentfc55d3e44a3792b991431059505d00248005c1fc (diff)
downloadphpicalendar-07effdabb09a9f27198ea0ac3cab678a221c2b44.tar.gz
phpicalendar-07effdabb09a9f27198ea0ac3cab678a221c2b44.tar.bz2
phpicalendar-07effdabb09a9f27198ea0ac3cab678a221c2b44.zip
Minor rollover tweek for colors and on state.
-rw-r--r--functions/template.php15
-rw-r--r--templates/default/day.tpl6
-rw-r--r--templates/default/default.css4
3 files changed, 17 insertions, 8 deletions
diff --git a/functions/template.php b/functions/template.php
index b3a6c20..b95156c 100644
--- a/functions/template.php
+++ b/functions/template.php
@@ -35,10 +35,22 @@ class Page {
$day_num = date("w", $start_day);
$weekday = $daysofweek_lang[$day_num];
$daylink = date('Ymd', $start_wt);
+ if ($daylink == $getdate) {
+ $row1 = 'rowToday';
+ $row2 = 'rowOn';
+ $row3 = 'rowToday';
+ } else {
+ $row1 = 'rowOff';
+ $row2 = 'rowOn';
+ $row3 = 'rowOff';
+ }
$start_day = strtotime("+1 day", $start_day);
$start_wt = strtotime("+1 day", $start_wt);
$loop_tmp = str_replace('{DAY}', $weekday, $loop_dof);
$loop_tmp = str_replace('{DAYLINK}', $daylink, $loop_tmp);
+ $loop_tmp = str_replace('{ROW1}', $row1, $loop_tmp);
+ $loop_tmp = str_replace('{ROW2}', $row2, $loop_tmp);
+ $loop_tmp = str_replace('{ROW3}', $row3, $loop_tmp);
$weekday_loop .= $loop_tmp;
}
$this->page = ereg_replace('<!-- loop daysofweek on -->(.*)<!-- loop daysofweek off -->', $weekday_loop, $this->page);
@@ -99,9 +111,6 @@ class Page {
$completed = trim($match1[1]);
$important = trim($match2[1]);
$normal = trim($match3[1]);
- $comp_data = '';
- $impt_data = '';
- $norm_data = '';
if (is_array($master_array['-2'])) {
foreach ($master_array['-2'] as $vtodo_times) {
diff --git a/templates/default/day.tpl b/templates/default/day.tpl
index 382de2e..e2a3142 100644
--- a/templates/default/day.tpl
+++ b/templates/default/day.tpl
@@ -26,15 +26,15 @@
<td colspan="2">
<table width="100%" border="0" cellspacing="1" cellpadding="2">
<tr>
- <td align="left" valign="top" width="20" class="rowOff" onmouseover="this.className='rowOn'" onmouseout="this.className='rowOff'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={DAYLINK}'">
+ <td align="left" valign="top" width="20" class="rowOff" onmouseover="this.className='rowOn'" onmouseout="this.className='rowOff'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={PREV_DAY}'">
<span class="V12"><a class="psf" href="day.php?cal={CAL}&amp;getdate={PREV_DAY}">&laquo;</a></span>
</td>
<!-- loop daysofweek on -->
- <td width="14%" align="center" class="rowOff" onmouseover="this.className='rowOn'" onmouseout="this.className='rowOff'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={DAYLINK}'">
+ <td width="14%" align="center" class="{ROW1}" onmouseover="this.className='{ROW2}'" onmouseout="this.className='{ROW3}'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={DAYLINK}'">
<span class="V9BOLD"><a class="ps3" href="day.php?cal={CAL}&amp;getdate={DAYLINK}">{DAY}</a></span>
</td>
<!-- loop daysofweek off -->
- <td align="right" valign="top" width="20" class="rowOff" onmouseover="this.className='rowOn'" onmouseout="this.className='rowOff'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={DAYLINK}'">
+ <td align="right" valign="top" width="20" class="rowOff" onmouseover="this.className='rowOn'" onmouseout="this.className='rowOff'" onclick="window.location.href='day.php?cal={CAL}&amp;getdate={NEXT_DAY}'">
<span class="V12"><a class="psf" href="day.php?cal={CAL}&amp;getdate={NEXT_DAY}">&raquo;</a></span>
</td>
</tr>
diff --git a/templates/default/default.css b/templates/default/default.css
index fc3d54b..63b499d 100644
--- a/templates/default/default.css
+++ b/templates/default/default.css
@@ -15,9 +15,9 @@ table, td {font: 11px Verdana, Arial, sans-serif; color: #000;}
.alldaybg_6 {background: url(images/allday_6.gif) repeat-x; height: 19px; padding-top: 5px; text-align: center;}
.alldaybg_7 {background: url(images/allday_7.gif) repeat-x; height: 19px; padding-top: 5px; text-align: center;}
-.rowOn { background-color: #DFF7F7; }
+.rowOn { background-color: #cfc; }
.rowOff { background-color: #E1E8F1; }
-.rowLent { background-color: #DDDDDD; }
+.rowToday { background-color: #cff; }

© 2014-2024 Faster IT GmbH | imprint | privacy policy