Welcome Guest, Not a member yet? Register   Sign In
Captcha Fail...
#1

[eluser]Medikal[/eluser]
I'm really struggling with the captcha helper, even after reading the documentation. The function has one name, the sample code uses another, though I figured out the proper way. What I don't understand just getting started is this:

Granted these aren't correct values:
Code:
$vals = array(
    'word'     => 'Random word',
    'img_path'     => './captcha/',
    'img_url'     => 'http://example.com/captcha/',
    'font_path'     => './path/to/fonts/texb.ttf',
    'img_width'     => '150',
    'img_height' => 30,
    'expiration' => 7200
    );

$cap = create_captcha($vals);

echo "Array:<pre>";
var_dump($cap);
echo "</pre>";

The var_dump should return an array according to the documentation that says what it returns. Instead it returns a bool false.

Any thoughts?




Theme © iAndrew 2016 - Forum software by © MyBB