izerui / kaptcha

Automatically exported from code.google.com/p/kaptcha
Other
0 stars 0 forks source link

Using Kaptcha in an application #24

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Hello

I'm trying to use Kaptcha in an application I'm developing in NetBeans 
using Tomcat. I've done everything as per the instructions such as putting 
in the reference in web.xml, adding to the form instructions in the JSP:

<form action = "<c:url value = '/createCommunity' />" method = "post">  
<img src="/kaptcha" /> <input type="text" name="kaptcha" value="" /> 
</form>

And placing the relevant code in the servlet which handles the form. I've 
also added the Kaptcha jar file to the projects lib directory.

But I get nothing at runtime. 

Do you have any idea why?

Though when I run: 

http://localhost:8080/kaptcha/KaptchaExample.jsp

Everything is fine.

Thanks

Martin O'Shea.

Original issue reported on code.google.com by oshea.ma...@gmail.com on 27 Aug 2008 at 8:26

GoogleCodeExporter commented 9 years ago
Try removing the / from the start of the image path. That is there depending on 
how you have your context 
setup. I've updated the example documentation to be a bit more clear on this. 
If that doesn't work, then is there 
anything in the logs? What happens if you try to go to that image path directly 
in the browser? What does 
TamperData say about the request/response?

Please re-open issue if this remains a problem, but I suspect it is just a path 
problem.

Original comment by latch...@gmail.com on 27 Aug 2008 at 4:07

GoogleCodeExporter commented 9 years ago
Thanks. That seems to have done the trick.

Martin O'Shea.

Original comment by oshea.ma...@gmail.com on 27 Aug 2008 at 7:43