PDA

View Full Version : First day in calendar


shketuljko
05-13-2008, 12:25 PM
You can start with Saturday as first day in your calendar.

Open VIVVO_ROOT/lib/vivvo/box/vivvo_box.php and try to find this code
(around 654 line):


$day_of_week = date ('w', mktime(0, 0, 0, $month, 1, $year));


replace that code with this:


$day_of_week = date ('w', mktime(0, 0, 0, $month, 2, $year));


After that you need to reorder
day of week in
VIVVO_ROOT/VIVVO_TEMPLATE_DIR/system/box_default/box_calendar.tpl

Just replace this code:


<td><strong><vte:value select="{LNG_SU}" /></strong></td>
<td><strong><vte:value select="{LNG_MO}" /></strong></td>
<td><strong><vte:value select="{LNG_TU}" /></strong></td>
<td><strong><vte:value select="{LNG_WE}" /></strong></td>
<td><strong><vte:value select="{LNG_TH}" /></strong></td>
<td><strong><vte:value select="{LNG_FR}" /></strong></td>
<td><strong><vte:value select="{LNG_SA}" /></strong></td>


with this:


<td><strong><vte:value select="{LNG_SA}" /></strong></td>
<td><strong><vte:value select="{LNG_SU}" /></strong></td>
<td><strong><vte:value select="{LNG_MO}" /></strong></td>
<td><strong><vte:value select="{LNG_TU}" /></strong></td>
<td><strong><vte:value select="{LNG_WE}" /></strong></td>
<td><strong><vte:value select="{LNG_TH}" /></strong></td>
<td><strong><vte:value select="{LNG_FR}" /></strong></td>

TheLastMen
05-13-2008, 03:00 PM
Many Thankx

Impaler
03-10-2009, 04:16 PM
thnx too, it worked.

Mahmoud
07-22-2009, 07:23 PM
I changed files but it is not work in new version of vivvo :(

shketuljko
07-23-2009, 08:12 AM
As @TheLastMen and @Impaler said it works. Also it works for me.
Could you tell me what's your Vivvo version?

Mahmoud
07-23-2009, 08:38 AM
My version is 4.1.5.1 .

I check it and change but show me Sunday in first day .
$day_of_week = date ('w', mktime(0, 0, 0, $month, 1, $year));
change to
$day_of_week = date ('w', mktime(0, 0, 0, $month, 2, $year));
is not on line 654 , it is in line 737
and i change :
VIVVO_ROOT/VIVVO_TEMPLATE_DIR/system/box_default/box_calendar.tpl , (all box_calendar.tpl ) too


<td><strong><vte:value select="{LNG_SA}" /></strong></td>
<td><strong><vte:value select="{LNG_SU}" /></strong></td>
<td><strong><vte:value select="{LNG_MO}" /></strong></td>
<td><strong><vte:value select="{LNG_TU}" /></strong></td>
<td><strong><vte:value select="{LNG_WE}" /></strong></td>
<td><strong><vte:value select="{LNG_TH}" /></strong></td>
<td><strong><vte:value select="{LNG_FR}" /></strong></td>


But shom me Sunday in first day . :confused:
Su Mo Tu We Th Fr Sa
I want
Sa Su Mo Tu We Th Fr


Do you test it in version 4.1.5.1 ?:(