Re: Issue with servlet:

Chong, Kenn Min a écrit :
> Hi there!
> 
>             I’ve setup the org.w3c.css.servlet.CssValidator.*class* as a 
> servlet in Jetty properly. Then when I try to feed in the following text:
> [...]
> 
>             HttpClient client = *new* HttpClient();    
> 
>             PostMethod post = *new* 
> PostMethod("http://10.0.2.249:9093/validate");
> 
>             post.setParameter("text", str);
> 
>             System./out/.println(client.executeMethod(post));
> [...]
> 
> I always get this:
> 
> 500
> 
> Indicating that the validator thinks I’m trying to validate with a file 
> versus a blob of text. What am I doing wrong??
> 

Hi,

I think that POST is only used to upload a file. If you want to use the 
text paramater you'll have to do a GET.

Regards,
Jean-Gui

Received on Thursday, 6 March 2008 09:59:05 UTC