Test Ar-PHP Functionality Online

header line!
Test PHP Function










Ar-PHP Manual

method en2ar [line 345]

string en2ar( string $str)

Translate English date/time terms into Arabic langauge



Tags:

return:  Date/time string using Arabic terms
author:  Khaled Al-Sham'aa <khaled@ar-php.org>
access:  protected


Parameters:

string   $str   Date/time string using English terms

Example
  1.    date_default_timezone_set('UTC');
  2.    $time = time();
  3.  
  4.    echo date('l dS F Y h:i:s A'$time);
  5.    echo '<br /><br />';
  6.  
  7.    include('./I18N/Arabic.php');
  8.    $obj new I18N_Arabic('Date');
  9.  
  10.    echo $obj->date('l dS F Y h:i:s A'$time);
  11.    echo '<br /><br />';
  12.  
  13.    $obj->setMode(2);
  14.    echo $obj->date('l dS F Y h:i:s A'$time);
  15.    echo '<br /><br />';
  16.  
  17.    $obj->setMode(3);
  18.    echo $obj->date('l dS F Y h:i:s A'$time);
  19.    echo '<br /><br />';
  20.  
  21.    $obj->setMode(4);
  22.    echo $obj->date('l dS F Y h:i:s A'$time);
Popular
Recent
Links
Ads!
footer line!

No Software Patents! General Public License

Home | Twitter | Blog | Contact

Copyright © 2006 - 2016 Khaled Al-Sham'aa