please help me captcha image on the web I do not want to appear and which arises is this message PHP Warning: imagefontwidth() expects parameter 1 to be long, string given in /home/hidecom/public_html/includes/libs/animatedcaptcha.class.php on line 236 ,272 and 274 and this line236, 272 and 274 error reply line 236 $y = ($height-imagefontheight($random_font))/2; line 272 $offset_x += (imagefontwidth($random_font) * $this->font_size / 8) + $this->text_space; line 274 $offset_x += (imagefontwidth($random_font) * $this->font_size / 8) + ceil($this->text_space * 0.5); please help me
can you post the line that sets the $random_font variable? Without knowing what that is, there's no way to make a suggestion.
Yup as jestep said, it seems $random_font has a string length limitation to certain character or either its not being passed into that variable at all... So look into it, try echoing that variable and see what it outputs..
I don't think you want to echo or vardump it. If it is a font file, it's going to be a huge mess of characters. Seeing how the variable is set should clear up some of the confusion.
and this line236, 272 and 274 error reply line 236 $y = ($height-imagefontheight($random_font))/2; line 272 $offset_x += (imagefontwidth($random_font) * $this->font_size / 8) + $this->text_space; line 274 $offset_x += (imagefontwidth($random_font) * $this->font_size / 8) + ceil($this->text_space * 0.5);
thanks for help I was able to overcome the above but I still run into obstacles I can not view the first loogin although admin username and password are correct please help
This error message appears [04-Dec-2011 09:37:36] PHP Fatal error: Call to undefined method animated_captcha::animatedcaptcha_fonts() in /home/hidecom/public_html/includes/libs/animatedcaptcha.class.php on line 270
I can not view the first loogin admin by using captcha code and i want to remove the captcha code please help me remove the captcha code and this admin loogin.php <?php if (!defined('IN_SCRIPT')) { exit('NOT IN SCRIPT'); } require(DIR.'includes/scripts/admin-login.php'); ?> <form method="post" action="admin.php?do=admin-login"> <input type="hidden" name="go" value="1"/> <table cellpadding="5" cellspacing="0"> <tr><td>Username <span class="error">*</span></td><td>:</td><td><input type="text" name="username" value="<?php echo2($username); ?>" /></td></tr> <tr><td>Password <span class="error">*</span></td><td>:</td><td><input type="password" name="password" value="" /></td></tr> <?php if (get_config('image_verification_admin_login')) : ?> <tr valign="top"> <td colspan="2"> </td><td><img width="200" height="70" alt="Captcha" src="animatedcaptcha.<?php echo_if_rewrite_url('gif', 'php'); ?>?r=<?php echo md5(microtime()); ?>" id="idCaptcha" onclick="refreshCaptcha('idCaptcha', 'animatedcaptcha.gif')" class="hand" /> <div>Enter <b>3 - 4 letters</b> that you see above.</div> <div class="refreshCaptcha"> <a href="javascript:refreshCaptcha('idCaptcha', 'animatedcaptcha.<?php echo_if_rewrite_url('gif', 'php'); ?>')">Click the image</a> to refresh </div> </td> </tr> <tr valign="top"> <td>Security Code <span class="error">*</span></td><td>:</td><td><input type="text" name="c" value="" size="10" style="text-transform:uppercase" /></td> </tr> <?php endif; ?> <tr><td colspan="2"> </td><td><input type="submit" value="Login" class="submit" /></td></tr> </table> </form> <?php echo $scriptMessage; ?>