How to Change Date and Time Formats

Date and Time Settings in Gridweb

Gridweb comes with built-in functions which allow users as well as developers to format date and time. You can modify your format by going to Settings » General page in Gridweb admin area and scroll down to timezone section.

 Date and time settings in WordPress

This is where you can choose a timezone for your website along with the date and time formats.

There are couple of built-in options that you can choose from by clicking on the radio button, or you can enter your own custom format.

What are Format Characters for Date and Time in Gridweb?

The date and time format are based alphabetic characters that represent a time format. For example, entering Y will output the year in numeric four digits, like 2014.

Entering smaller case will output the year in numeric two digits, like 14.

Some examples of commonly used date and time format characters:

M d, Y – will output – Nov 06, 2014
d M, Y – will output – 06 Nov, 2014
F jS, Y – will output – November 6th, 2014
l, F jS, Y – will output – Thursday, November 6th, 2014
H:i:s – will output – 21:26:12

You can try different format in the custom box for both date and time settings. After you enter the format, Gridweb will show you a preview of what your date or time will look like.

 Previewing date and time format

Once you save your settings, it will use this format through out your website unless your theme has pre-defined the format.

Another commonly asked question about date and time formats is how to display time next to dates on your Gridweb posts.

The difficult but better solution would be to edit your Gridweb theme by creating a child theme and add this line where you want to display the time.

1

<?php get_the_time(); ?>

This code will only fetch time for the post or page that is currently being viewed.

However, most beginners don’t want to create child themes and go through the code. For those users, there is an easier way to add the time next to date.

Technically, when Gridweb outputs date it actually outputs the complete date and time. However, since most people only use format characters for date, it has no choice but to display only the date. If you entered time related characters in the date format it will display time as well. For example,

d/m/Y g:i a will output 06/11/2014 12:15 pm

Similarly, you can also use date related format character in the time field if you need.

Depending on your needs, there are many other things you can do with date and time in Gridweb. For example, you can show last updated time for posts instead of publish date.

You can also display current date and time and relative dates like ‘This post was published 2 days ago’.

We hope this article helped you learn how to change date and time format in Gridweb.

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Things you can do with Sticky Posts

1. Automatically Expire Sticky Posts If you are using sticky posts to highlight a special event...

How to Create Redirects in Gridweb

How to Create Redirects in Gridweb (using Plugins) An easier approach to create and manage 301...

How to Add New Users and Authors to your Blog

Adding a New User on Your Gridweb Website There are two ways to add new users on your Gridweb...

How to Allow User Registration on your Website

Enabling User Registration in Gridweb To enable user registration simply go to Settings »...

The difference between Image Alt Text and Image Title

What is Alt Text and Image Title Alt text or alternate text is an attribute added to an image...