18.226.28.197 |    

Navigation

Google Advertisement

This function convert a rfc2822 date format (e.g. Thu, 30 Aug 2012 14:28:25 +0200) into a iso8601 date format (e.g. 2012-08-30T14:28:25+02:00).

rfc2822Toiso8601
  1. /**
  2.  * This function convert a rfc2822 date format (e.g. Thu, 30 Aug 2012 14:28:25 +0200)
  3.  * into a iso8601 date format (e.g. 2012-08-30T14:28:25+02:00).
  4.  *
  5.  * @param string $date - The date sting
  6.  * @return string
  7.  */
  8. function rfc2822Toiso8601($date) {
  9.  
  10. return date(DATE_ATOM, strtotime ($date));
  11.  
  12. }
Parsed in 0.010 seconds at 29.58 KB/s

Search
 
Full text search by name and content of a snippet.

User online
There are 1 users online.

Tags Cloud

Latest snippets
str2seconds
(Bash::Function)
is_integer
(Bash::Function)
file_rotate
(Bash::Function)
confirm
(Bash::Function)
is_workingtime
(Bash::Function)
last day of last month
(Bash::Snippets)
crypt_apr1_md5
(PHP::Function)
crypt_apr1_md5
(Perl::Function)
transparent
(CSS)
rfc2822Toiso8601
(PHP::Function)