LiveZilla Live Help

Our Online Blog

We have put together this blog to help, inform and inlight users regarding the internet, development and design. We also post all our network updates here to make sure you keep up to date with whats going on around you.

Search Blog

Posts Tagged ‘Copyright date’

Coldfusion DateFormat

Tuesday, June 16th, 2009

The Coldfusion dateformat works in the same sort of fashion as the ASP.NET and the PHP date time function. As our team mainly works in Coldfusion we can expand alot more on this function that ASP.NET / PHP.

The code: (Use this code within a <cfoutput></cfoutput> tag)

#DateFormat(Now(), "YYYY")#

About the code:

As you can see all we start with DateFormat which states will want to have a date format (You can use TimeFormat to work with times). Next we are getting the current date with the Now() and then we have the formatting of the date, as we only want the year we are using ‘YYYY’ (Displays: 2009) or you can use ‘YY’ (Displays: 09)

Enjoy!

ASP.NET DateTime

Tuesday, June 16th, 2009

As you might have seen we posted a small post about PHP date formatting to help keeping your websites copyright year up to date.

Well as our development team has started working with ASP.NET we will be starting to add ASP.NET tutorials and articles for you to read. We do offer custom Windows hosting with both Coldfusion and ASP.NET. If you are interested please contact us.

Now for the code!

ASP.NET is easy to pick up as some of the basics are like PHP in some ways but sorry to say not at all like the Coldfusion coding.

Date and Time:

<%= DateTime.Now %>

The year for copyright:

<%= DateTime.Now.Year %>

Enjoy!