INTLCALENDAR.GETFIRSTDAYOFWEEK(3) 1 INTLCALENDAR.GETFIRSTDAYOFWEEK(3)IntlCalendar::getFirstDayOfWeek - Get the first day of the week for the calendars locale
Object oriented style
SYNOPSIS
public int IntlCalendar::getFirstDayOfWeek (void )
DESCRIPTION
Procedural style
int intlcal_get_first_day_of_week (IntlCalendar $cal)
The week day deemed to start a week, either the default value for this locale or the value set with IntlCalendar.setFirstDayOfWeek(3).
PARAMETERS
o $cal
- The IntlCalendar resource.
RETURN VALUES
One of the constants IntlCalendar::DOW_SUNDAY, IntlCalendar::DOW_MONDAY, , IntlCalendar::DOW_SATURDAY or FALSE on failure.
EXAMPLES
Example #1
IntlCalendar.getFirstDayOfWeek(3)
<?php
ini_set('date.timezone', 'UTC');
$cal1 = IntlCalendar::createInstance(NULL, 'es_ES');
var_dump($cal1->getFirstDayOfWeek()); // Monday
$cal1->set(2013, 1 /* February */, 3); // a Sunday
var_dump($cal1->get(IntlCalendar::FIELD_WEEK_OF_YEAR)); // 5
$cal2 = IntlCalendar::createInstance(NULL, 'en_US');
var_dump($cal2->getFirstDayOfWeek()); // Sunday
$cal2->set(2013, 1 /* February */, 3); // a Sunday
var_dump($cal2->get(IntlCalendar::FIELD_WEEK_OF_YEAR)); // 6
The above example will output:
int(2)int(5)int(1)int(6)SEE ALSO
IntlCalendar::setFirstDayOfWeek.
PHP Documentation Group INTLCALENDAR.GETFIRSTDAYOFWEEK(3)
Check Out this Related Man Page
INTLCALENDAR.GETWEEKENDTRANSITION(3) 1 INTLCALENDAR.GETWEEKENDTRANSITION(3)IntlCalendar::getWeekendTransition - Get time of the day at which weekend begins or ends
Object oriented style
SYNOPSIS
public int IntlCalendar::getWeekendTransition (string $dayOfWeek)
DESCRIPTION
Procedural style
int intlcal_get_weekend_transition (IntlCalendar $cal, string $dayOfWeek)
Returns the number of milliseconds after midnight at which the weekend begins or ends.
This is only applicable for days of the week for which IntlCalendar.getDayOfWeekType(3) returns either IntlCalendar::DOW_TYPE_WEEKEND_OFF-
SET or IntlCalendar::DOW_TYPE_WEEKEND_CEASE. Calling this function for other days of the week is an error condition.
This function requires ICU 4.4 or later.
PARAMETERS
o $cal
- The IntlCalendar resource.
o $dayOfWeek
- One of the constants IntlCalendar::DOW_SUNDAY, IntlCalendar::DOW_MONDAY, , IntlCalendar::DOW_SATURDAY.
RETURN VALUES
The number of milliseconds into the day at which the weekend begins or ends or FALSE on failure.
EXAMPLES
See example on IntlCalendar.getDayOfWeekType(3).
PHP Documentation Group INTLCALENDAR.GETWEEKENDTRANSITION(3)
Hi ,
I am working at Unix system,using c lang.
I need c fun which return the day of the week .
For example :
0- Sunday.
1- Monday.
....
10x. (4 Replies)
Hi All,
I have to kick off a script on every Monday to get some data from database for last week (Sunday thru Saturday).
If its Monday (12/12/2005)
Begin date will be Sunday - 12/4/2005
End date will be Saturday - 12/10/2005
The script might not kick off on some Mondays.
So my... (2 Replies)
Hi all, I am trying to get dow from cal using below script
#! /bin/bash
YEAR=`echo $1 | cut -c 1-4`
MONTH=`echo $1 | cut -c 5-6`
DAY=`echo $1 | cut -c 7-8`
for i in 1 2 3 4 5 6 7
do
dayofweek=`cal $MONTH $YEAR | awk '$i == $DAY {printf("%s","$i")}'`
echo $dayofweek... (4 Replies)
Hi All,
I have a requirement in my project where a batch runs on any day of a week. The input files will land to the server every Sunday. I need to read these files based on the current BUS_DAY (which falls any day of the week).
For e.g : if the BUS_DAY is 20120308, we need to derive the... (3 Replies)
2013 Academy Awards
The nominees for the 2013 Academy Awards have been revealed in Los Angeles.
The ceremony will take place at the Dolby Theatre in Hollywood, Los Angeles on 24th February.
Best film
Amour
Argo
Beasts Of The Southern Wild
Django Unchained
Les Miserables... (0 Replies)
Consider i have the below data in my log file.
i want to grep using "Monday" and "Working"
So the only output i expect is
Can you help me with the grep query for Sun Sparc ?
Usage: grep -hblcnsviw pattern file . . . (8 Replies)