What syntax to use

2002-05-01 Thread Tom Kochanowicz
I am reading Hall's more servlets & JSP book. When going through the code he uses mainly directive, declarations, scriplets and expressions that are not xml based. I plan on taking my scwcd exam and was wondering if anyone knew if both types of syntax is being used in the test? I think tha

Re: Converting date to int

2002-05-01 Thread Kesav, Ramesh
USE JAVA SCRIPT at the end of your html page selectDate(); and the script would be in the head tag function selectDate() { var date = new Date(); var month = date.getMonth()+1; var day = date.getDate(); var year = date.getYear(); for(i=0;i

Re: Response has already been committed

2002-05-01 Thread Vikramjit Singh
u are including a file where it is not needed and doing response.sendRedirect(). Regards, Vikramjit Singh, Systems Engineer, GTL Ltd. Ph. 7612929-1031 -Original Message- From: subbu [mailto:[EMAIL PROTECTED]] Sent: Wednesday, May 01, 2002 9:10 PM To: [EMAIL PROTECTED] Subject: Re: Resp

Re: Response has already been committed

2002-05-01 Thread subbu
Hai,Vaishali I think you are using response.sendRedirect in a wrong place. if that is the case try jsp:forward subramanian.s IonIdea Enterprise Solutio

Re: Converting date to int

2002-05-01 Thread Smita Kotnis
Yes, Calender would be the good soln. In one of my aplication, I was supposed to compare the months, I had used the same concept. And it works fine. Smita Mike Shoemaker <[EMAIL PROTECTED]>: > Could you use the Calendar object? > > i.e. > > Calendar c = Calendar.getInstance(); > System.

Re: Converting date to int

2002-05-01 Thread Mike Shoemaker
Could you use the Calendar object? i.e. Calendar c = Calendar.getInstance(); System.out.println(c.get(Calendar.MONTH)); System.out.println(c.get(Calendar.DAY_OF_MONTH)); System.out.println(c.get(Calendar.YEAR)); Note. Month starts with January as 0 so you should add 1 to the result. - Or

ANN: Web Components Toolkit, a Swing-like programming library for Servlet development

2002-05-01 Thread Juliano Viana
Hi, I'm pleased to announce the first public release of WCT - Web Components Toolkit. WCT is a component library for servlet development, which supports an API similar to the Java language's Swing library. Using WCT one can write servlets like that: import org.wct.*; public class MyApp e

Re: Any idea of how to draw a line or a square on top of an image?

2002-05-01 Thread Peter Dolukhanov
The code should read: // Get existing image URL theURL = new URL("http://path.to/your/image.gif";); BufferedImage buffImage = (PlanarImage)JAI.create("url",theURL).getAsBufferedImage(); // Create a new graphics object

Re: Any idea of how to draw a line or a square on top of an image?

2002-05-01 Thread Peter Dolukhanov
This answer applies to both "Richie Bab A. Boyboy" and " Villén Pizarro": The answer you are looking for lies most probably in using a Servlet combined with the Java Advanced Imaging (JAI), available from java.sun.com. There are codecs to produce JPEGs and other formats, however if you are looki

Converting date to int

2002-05-01 Thread Gading
I have jsp page wich shows select item for day , month , year. I need to have current date is selected by default, how to obtain that? Im trying to use SimpleDateFormat df = new SimpleDateFormat("d"); but it return string and can not convert to int.