Java tutorial
//package com.java2s; import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.Locale; import java.util.TimeZone; public class Main { public static String getTodayDate() { TimeZone currZone = TimeZone.getTimeZone("Asia/Singapore"); Calendar myCal = Calendar.getInstance(currZone, new Locale("en")); SimpleDateFormat sdf = new SimpleDateFormat(); sdf.applyPattern("yyyy-MM-dd"); return (sdf.format(myCal.getTime())); } }