Jamie Balfour

Welcome to my personal website.

Find out more about me, my personal projects, reviews, courses and much more here.

Official ZPE/YASS documentationDate

Object description

Represents and manipulates dates and times.

Object functions

  • compare_date [1.7.5+]

    The `compare_date` operation for the Date object.

  • convert_to_string [1.7.5+]

    Outputs the date in a specified format to a string.

  • date_diff [1.7.5+]

    Compares this date against another. The format value is optional but if specified it can have one of four values: hours, minutes, seconds or days. This lets the function know what to return the number of. By default the format is days.

  • day [1.7.5+]

    Returns the day value of the date.

  • hour [1.7.5+]

    Returns the hour value of the date.

  • minute [1.7.5+]

    Returns the minute value of the date.

  • month [1.7.5+]

    Returns the month value of the date.

  • second [1.7.5+]

    Returns the second value of the date.

  • set_date [1.7.5+]

    Sets the date stored within the object. The format helps the system to decide what format the date value is in. If the format parameter is omitted, the format becomes yyyy-MM-dd.

  • set_to_now [1.7.5+]

    Sets the date stored within the object to now. It then returns the date as a string.

  • time [1.7.5+]

    Returns a long integer representing the current epoch time. Added in 1.8.7

  • year [1.7.5+]

    Returns the year value of the date.

Comments

There are no comments on this page.

New comment

Comments are welcome and encouraged, including disagreement and critique. However, this is not a space for abuse. Disagreement is welcome; personal attacks, harassment, or hate will be removed instantly. This site reflects personal opinions, not universal truths. If you can’t distinguish between the two, this probably isn’t the place for you. The system temporarily stores IP addresses and browser user agents for the purposes of spam prevention, moderation, and safeguarding. This data is automatically removed after fourteen days. Your email address is stored so that replies can be sent to your email address.

Comments powered by BalfComment

Feedback 👍
Comments are sent via email to me.