Make sure you have a correct value in $prefix.
@takayukister, i correct prefix
$captchaBox = new PWPanelCaptcha();
$prefix = mt_rand();
$word = $this->generate_random_word();
printf(
'<div align="center"><img src="%s" /></div>', PWPANEL__PLUGIN_URL . 'tmp/' . $this->generate_image( $prefix, $word )
);
printf(
'<input type="text" id="pwpanel_captcha" name="pwpanel_captcha" min="6" max="6" minlength="6" maxlength="6" placeholder="%s" required />', __( 'Enter code from above', 'pwpanel' )
);
$captchaBox ->remove( $prefix );
it not remove the generate image. What was i missing?
btw, i use latest WordPress, and with PHP 72
This code has nothing to do with the Really Simple CAPTCHA plugin.