captcha image not loading in server |
captcha image not loading in server
****************************** view file ******** <div id="imgdiv" style="display: inline;"><img id="img" src="<?= base_url() ?>login/getcapachaimage" /></div><img id="reload" src="<?= base_url() ?>img/reload.png" />
Help us help you ... what error message or unexpected behavior are you getting?
Do your files exist? You are requesting the images "BASE_URL/login/getcapachaiumage", which sounds like a controller referencem=, and BASE_URL/img/reload.png. Is the second one showing up?
Assuming you are using CodeIgniter Catpcha helper.
You have to use generated image URL instead of hardcoded URL. Controller: PHP Code: $cap = create_captcha($captcha_options); View: Code: <?= $cap['image'] ?> The image attribute already holds full img tag. More in the manual: https://www.codeigniter.com/user_guide/h...elper.html (07-13-2018, 08:10 AM)Pertti Wrote: Assuming you are using CodeIgniter Catpcha helper.I try with this solution,but not get it I attached both file also please make a correction |
Welcome Guest, Not a member yet? Register Sign In |