Java Get Year for Footer/Copyright


/ Published in: Java
Save to your folder(s)

Gets the current year.


Copy this code and paste it in your HTML
  1. <%@ page import="java.text.SimpleDateFormat" %>
  2. <%@ page import="java.util.Date" %>
  3.  
  4. Copyright &copy <%= new SimpleDateFormat("yyyy").format(new Date()) %> Your Website. All Rights Reserved.

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.