PHP Problem: gd_version() crashes script

Status
Not open for further replies.

GG-Xtreme

New Member
Messages
430
Reaction score
0
Points
0
My MyBB image captcha no longer works (it was working when I checked this past Friday). After doing some debugging, I've found that captcha.php crashes at this block:
PHP:
if(gd_version() >= 2)
{
    $im = imagecreatetruecolor($img_width, $img_height);
}
else
{
        $im = imagecreate($img_width, $img_height);
}
gd_version() returns blank and the script doesn't take either case for some reason. Since the script was working fine before and I have reuploaded it to make sure it wasn't modified, I am sure this is an issue on the server end. Can an admin help me fix this?
Edit:
Ok, it's because phpinfo is turned off on Lvl 2. But if I remove the phpinfo line from the script, the captcha becomes impossible to read (white text on a white background with a few colored lines). Can I request lvl 3 to run MyBB, because I never needed it before?
 
Last edited:

Christopher

Retired
Messages
14,659
Reaction score
8
Points
0
Change that block to
PHP:
$im = imagecreatetruecolor($img_width, $img_height);
 
Status
Not open for further replies.
Top