{
    "mode": "perldoc",
    "parameter": "Time::CTime",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/Time%3A%3ACTime/json",
    "generated": "2026-06-16T10:29:19Z",
    "synopsis": "use Time::CTime\nprint ctime(time);\nprint asctime(localtime(time));\nprint strftime(template, localtime(time));\nstrftime conversions\n%%      PERCENT\n%a      day of the week abbr\n%A      day of the week\n%b      month abbr\n%B      month\n%c      ctime format: Sat Nov 19 21:05:57 1994\n%d      DD\n%D      MM/DD/YY\n%e      numeric day of the month\n%f      floating point seconds (milliseconds): .314\n%F      floating point seconds (microseconds): .314159\n%h      month abbr\n%H      hour, 24 hour clock, leading 0's)\n%I      hour, 12 hour clock, leading 0's)\n%j      day of the year\n%k      hour\n%l      hour, 12 hour clock\n%m      month number, starting with 1, leading 0's\n%M      minute, leading 0's\n%n      NEWLINE\n%o      ornate day of month -- \"1st\", \"2nd\", \"25th\", etc.\n%p      AM or PM\n%r      time format: 09:05:57 PM\n%R      time format: 21:05\n%S      seconds, leading 0's\n%t      TAB\n%T      time format: 21:05:57\n%U      week number, Sunday as first day of week\n%v      DD-Mon-Year\n%w      day of the week, numerically, Sunday == 0\n%W      week number, Monday as first day of week\n%x      date format: 11/19/94\n%X      time format: 21:05:57\n%y      year (2 digits)\n%Y      year (4 digits)\n%Z      timezone in ascii. eg: PST",
    "sections": {
        "NAME": {
            "content": "Time::CTime -- format times ala POSIX asctime\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "use Time::CTime\nprint ctime(time);\nprint asctime(localtime(time));\nprint strftime(template, localtime(time));\n\nstrftime conversions\n%%      PERCENT\n%a      day of the week abbr\n%A      day of the week\n%b      month abbr\n%B      month\n%c      ctime format: Sat Nov 19 21:05:57 1994\n%d      DD\n%D      MM/DD/YY\n%e      numeric day of the month\n%f      floating point seconds (milliseconds): .314\n%F      floating point seconds (microseconds): .314159\n%h      month abbr\n%H      hour, 24 hour clock, leading 0's)\n%I      hour, 12 hour clock, leading 0's)\n%j      day of the year\n%k      hour\n%l      hour, 12 hour clock\n%m      month number, starting with 1, leading 0's\n%M      minute, leading 0's\n%n      NEWLINE\n%o      ornate day of month -- \"1st\", \"2nd\", \"25th\", etc.\n%p      AM or PM\n%r      time format: 09:05:57 PM\n%R      time format: 21:05\n%S      seconds, leading 0's\n%t      TAB\n%T      time format: 21:05:57\n%U      week number, Sunday as first day of week\n%v      DD-Mon-Year\n%w      day of the week, numerically, Sunday == 0\n%W      week number, Monday as first day of week\n%x      date format: 11/19/94\n%X      time format: 21:05:57\n%y      year (2 digits)\n%Y      year (4 digits)\n%Z      timezone in ascii. eg: PST\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "This module provides routines to format dates. They correspond to the libc routines. &strftime()\nsupports a pretty good set of conversions -- more than most C libraries.\n\nstrftime supports a pretty good set of conversions.\n\nThe POSIX module has very similar functionality. You should consider using it instead if you do\nnot have allergic reactions to system libraries.\n",
            "subsections": []
        },
        "GENESIS": {
            "content": "Written by David Muir Sharnoff <muir@idiom.org>.\n\nThe starting point for this package was a posting by Paul Foley <paul@ascent.com>\n",
            "subsections": []
        },
        "LICENSE": {
            "content": "Copyright (C) 1996-2010 David Muir Sharnoff. Copyright (C) 2011 Google, Inc. License hereby\ngranted for anyone to use, modify or redistribute this module at their own risk. Please feed\nuseful changes back to cpan@dave.sharnoff.org.\n",
            "subsections": []
        }
    },
    "summary": "Time::CTime -- format times ala POSIX asctime",
    "flags": [],
    "examples": [],
    "see_also": []
}