Register Register Member Login Member Login Member Login Forgot Password ??
PHP , ASP , ASP.NET, VB.NET, C#, Java , jQuery , Android , iOS , Windows Phone
 

Registered : 109,028

HOME > PHP Manual > The IntlDateFormatter class





ลองใช้ค้นหาข้อมูล


   
Bookmark.

The IntlDateFormatter class

Introduction

Date Formatter is a concrete class that enables locale-dependent formatting/parsing of dates using pattern strings and/or canned patterns.

This class represents the ICU date formatting functionality. It allows users to display dates in a localized format or to parse strings into PHP date values using pattern strings and/or canned patterns.

Class synopsis

IntlDateFormatter
class IntlDateFormatter {
/* Methods */
__construct ( string $locale , integer $datetype , integer $timetype [, string $timezone [, integer $calendar [, string $pattern ]]] )
static IntlDateFormatter create ( string $locale , integer $datetype , integer $timetype [, string $timezone [, integer $calendar [, string $pattern ]]] )
string format ( mixed $value )
integer getCalendar ( void )
integer getDateType ( void )
integer getErrorCode ( void )
string getErrorMessage ( void )
string getLocale ([ integer $which ] )
string getPattern ( void )
integer getTimeType ( void )
string getTimeZoneId ( void )
boolean isLenient ( void )
array localtime ( string $value [, integer &$position ] )
integer parse ( string $value [, integer &$position ] )
boolean setCalendar ( integer $which )
boolean setLenient ( boolean $lenient )
boolean setPattern ( string $pattern )
boolean setTimeZoneId ( string $zone )
}

Predefined Constants

These constants are used to specify different formats in the constructor for DateType and TimeType.

IntlDateFormatter::NONE (string)
Do not include this element
IntlDateFormatter::FULL (string)
Completely specified style (Tuesday, April 12, 1952 AD or 3:30:42pm PST)
IntlDateFormatter::LONG (string)
Long style (January 12, 1952 or 3:30:32pm)
IntlDateFormatter::MEDIUM (string)
Medium style (Jan 12, 1952)
IntlDateFormatter::SHORT (string)
Most abbreviated style, only essential data (12/13/52 or 3:30pm)

The following int constants are used to specify the calendar. These calendars are all based directly on the Gregorian calendar. Non-Gregorian calendars need to be specified in locale. Examples might include locale="hi@calendar=BUDDHIST".

IntlDateFormatter::TRADITIONAL (string)
Non-Gregorian Calendar
IntlDateFormatter::GREGORIAN (string)
Gregorian Calendar

Table of Contents



ThaiCreate.Com Forum


Comunity Forum Free Web Script
Jobs Freelance Free Uploads
Free Web Hosting Free Tools

สอน PHP ผ่าน Youtube ฟรี
สอน Android การเขียนโปรแกรม Android
สอน Windows Phone การเขียนโปรแกรม Windows Phone 7 และ 8
สอน iOS การเขียนโปรแกรม iPhone, iPad
สอน Java การเขียนโปรแกรม ภาษา Java
สอน Java GUI การเขียนโปรแกรม ภาษา Java GUI
สอน JSP การเขียนโปรแกรม ภาษา Java
สอน jQuery การเขียนโปรแกรม ภาษา jQuery
สอน .Net การเขียนโปรแกรม ภาษา .Net
Free Tutorial
สอน Google Maps Api
สอน Windows Service
สอน Entity Framework
สอน Android
สอน Java เขียน Java
Java GUI Swing
สอน JSP (Web App)
iOS (iPhone,iPad)
Windows Phone
Windows Azure
Windows Store
Laravel Framework
Yii PHP Framework
สอน jQuery
สอน jQuery กับ Ajax
สอน PHP OOP (Vdo)
Ajax Tutorials
SQL Tutorials
สอน SQL (Part 2)
JavaScript Tutorial
Javascript Tips
VBScript Tutorial
VBScript Validation
Microsoft Access
MySQL Tutorials
-- Stored Procedure
MariaDB Database
SQL Server Tutorial
SQL Server 2005
SQL Server 2008
SQL Server 2012
-- Stored Procedure
Oracle Database
-- Stored Procedure
SVN (Subversion)
แนวทางการทำ SEO
ปรับแต่งเว็บให้โหลดเร็ว


Hit Link
   







Load balance : Server 01
ThaiCreate.Com Logo
© www.ThaiCreate.Com. 2003-2024 All Rights Reserved.
ไทยครีเอทบริการ จัดทำดูแลแก้ไข Web Application ทุกรูปแบบ (PHP, .Net Application, VB.Net, C#)
[Conditions Privacy Statement] ติดต่อโฆษณา 081-987-6107 อัตราราคา คลิกที่นี่