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 ‘copyight date year’

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!

PHP Date

Friday, May 1st, 2009

We have had a few emails asking about simple PHP dates for copyright footers and having the date as part of a navigation so we thought we would post a little info pack about PHP dates.

Adding the year as part of the copyright is a great idea as it makes one less thing you have to change each year of your website. 1 more thing of the “To do List”

The simple way of getting the date and outputing it to the screen is using the example provided from PHP.NET shown below:

Source PHP.NET

<?php
$today
= getdate();
print_r($today);
?>
To do a year only for copyright footers like we have on our website you can use:
<?php echo date(‘Y’); ?>
Hope you find this tiny bit of code handy for your website.