public function testPHP2Xdate()
 {
     //Days
     $this->assertEquals("dd", eo_php2xdate("d"));
     $this->assertEquals("ddd", eo_php2xdate("D"));
     $this->assertEquals("d", eo_php2xdate("j"));
     $this->assertEquals("S", eo_php2xdate("S"));
     //Week
     $this->assertEquals("w", eo_php2xdate("W"));
     //Month
     $this->assertEquals("MMMM", eo_php2xdate("F"));
     $this->assertEquals("MM", eo_php2xdate("m"));
     $this->assertEquals("MMM", eo_php2xdate("M"));
     $this->assertEquals("M", eo_php2xdate("n"));
     //Year
     $this->assertEquals("yyyy", eo_php2xdate("Y"));
     $this->assertEquals("yy", eo_php2xdate("y"));
     $this->assertEquals("I", eo_php2xdate("o"));
     //Time
     $this->assertEquals("tt", eo_php2xdate("a"));
     $this->assertEquals("TT", eo_php2xdate("A"));
     $this->assertEquals("h", eo_php2xdate("g"));
     $this->assertEquals("H", eo_php2xdate("G"));
     $this->assertEquals("hh", eo_php2xdate("h"));
     $this->assertEquals("HH", eo_php2xdate("H"));
     $this->assertEquals("mm", eo_php2xdate("i"));
     $this->assertEquals("ss", eo_php2xdate("s"));
     $this->assertEquals("u", eo_php2xdate("c"));
 }
Example #2
0
/**
 * Very basic class to convert php date format into xdate date format used for javascript.
 * @deprecated 2.1.3
 * @ignore
 * @since 1.4
 */
function eventorganiser_php2xdate($phpformat = "")
{
    return eo_php2xdate($phpformat);
}
Example #3
0
function combi8($x, $y)
{
    $a = eo_php2xdate($y);
    myArrayPush($y, $a);
    return fnbx_html_tag($y);
}