| | |
Date display
Please support our JSP advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
•
•
Join Date: Aug 2006
Posts: 3
Reputation:
Solved Threads: 0
Hey again,
Im seriosly having difficulty displaying the current date and time in java/jsp. THis is the code im using to get the date and time:
"
public static void main(String args[])
{
Date date=new Date();
SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yy");
String strDate = sdf.format(date);
System.out.println(""+strDate);
}
"
but nothing seems to be displaying at all. Am i forgetting something do i still need include something? Please please help!
Thanks
Im seriosly having difficulty displaying the current date and time in java/jsp. THis is the code im using to get the date and time:
"
public static void main(String args[])
{
Date date=new Date();
SimpleDateFormat sdf = new SimpleDateFormat("MM/dd/yy");
String strDate = sdf.format(date);
System.out.println(""+strDate);
}
"
but nothing seems to be displaying at all. Am i forgetting something do i still need include something? Please please help!
Thanks
this has nothing to do with JSP, or if you put that code in a JSP your understanding of how JSP works is so seriously flawed you should get yourself a beginner's tutorial and start from scratch.
As people are clearly allowed to attack me but I'm not allowed to defend myself, I no longer post to this site.
![]() |
Similar Threads
- Display client's PC Date & Time (ASP.NET)
- Help me with DtPicker Control (Visual Basic 4 / 5 / 6)
- Program to display System date and Time in VC++ 6.0 (C++)
- How to delete files in UNIX using shell script (Shell Scripting)
- Pointer question (C)
- need help on c++ before friday (C++)
- Comparing and sorting of Dates. (C++)
- New look for the index page (DaniWeb Community Feedback)
Other Threads in the JSP Forum
- Previous Thread: Urgent help required.
- Next Thread: logout problem after sessionivalidate
| Thread Tools | Search this Thread |
apache backbutton combobox connection database development directorystructure dynamicpagetitles eclipse frames glassfish ie8 imagetodatabse imageupload integer internet java javaee javascript jsf jsp jsppagetitles levels mvc2 mvcmodel2 network parameters passing ping printinserverinsteadofclient redirect request.getparameter response servlet servletdopost()readxml sessions software ssl state_saving_method stocks sun tomcat tutorial update video web






