When I integrate this code into a html file, it shows nothing, but it works when it is separate with the other html code.
So, could any one kindly teach me how to add it to html code and compare the form input with $chars
?
require_once "/jpgraph/jpgraph_antispam.php";//the location is correct!!
$spam = new AntiSpam();
// saved to $chars for later verification of correct entry
$chars = $spam->Rand(8);
$spam->Stroke() ;
jpgraph returns raw images, you cannot include them in with HTML markup.
instead include the captcha.php as an image in HTML
<img src="captcha.php" />