Sanjay Mohanty

Greenhorn
+ Follow
since Sep 12, 2009
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Sanjay Mohanty

Thanks a lot.

I will try Ajax option.
11 years ago
JSP
Hi

I am writing a JSP tag that will basically execute certain tasks and update the status in JSP page after completion of each task.

Lets take below example -

I want to verify different softwares like Tomcat/MySql/Java... before doing some operation. In my index.jsp page when I will click on button "Start Verification" at back end the custom tag will keep on verifying the softwares and display the status in same jsp page (which is already loaded)

Below is my tag support class - when its executing below highlighted line, throw error - Stream is closed.

Is there any way to create a separate thread in JSP custom tag ?

@Override
public void doTag() throws JspException
{
try
{
Thread thread = new Thread(new RecoveryLoggerThread(),"RecoveryLoggerThread");
thread.start();
}
catch (Exception e)
{
e.printStackTrace();
}

//return SKIP_BODY;
}

class RecoveryLoggerThread implements Runnable
{

@Override
public void run()
{
try
{
PageContext pageContext = (PageContext) getJspContext();
JspWriter out = pageContext.getOut();

out.println(getLogData("Tomcat", false) +"\t\t");

out.println("OK");

}
catch (Exception e)
{

e.printStackTrace();
}

}

}



11 years ago
JSP
Hi,

I have a image displayed in browser inside div element. Now I want to read the height, width and pixels of that image on click of a button.

Please suggest.

Regards,
Sanjay
13 years ago
Hi,

I am receiving a file from an external system. The file name has some japanese characters. So when I tried to rename that file by prefixing the date, the out put file contains only date_???.txt. The japanese characters get converted to ?. I want to retain those character in Linux environment. It work fine in windows environment.

Regards,
Sanjay
13 years ago
Hi,
I am new to eclipse ant tomcat.
Currently I am developing a web application useing Eclipse Ganymede and tomcat 6.0.20.
But I am facing problem to debug it. Kindly suggest me how to debug it.

Thanks,
Snajay