How can I change CAPTCHA colours?
Permalink 5 users found helpful
Is it possible to edit the way my CAPTCHA looks??
Regards.
Regards.
that WAS pretty easy! worked a treat. thanks very much for that.
theres some awesome photos on that inner optics site!
theres some awesome photos on that inner optics site!
thanks :-)
@Tony: Helpers currently cannot be overridden. They can only be extended.
good tip. thx.
Great tip, but when I tried it it did not work. I had to edit the helper instead. Maybe something has changed in recent update?
I think so, I´ve tried it too, but doesen´t work. But I don´t like the standard Captcha-look. Can anyone help?
I just edited the core php file at concrete5/concrete/helpers/validation/captcha.php
But make sure you keep a backup first, and note the changes you make as the file will likely be replaced with concrete updates. Look at around lines 47-57, it's pretty easy to change the RGB colour ranges, turn off multicolour text (true/false), change the number of lines.
But make sure you keep a backup first, and note the changes you make as the file will likely be replaced with concrete updates. Look at around lines 47-57, it's pretty easy to change the RGB colour ranges, turn off multicolour text (true/false), change the number of lines.
$this->securimage->image_bg_color = new Securimage_Color(227, 218, 237); $this->securimage->line_color = new Securimage_Color(51, 51, 51); $this->securimage->num_lines = 5; $this->securimage->use_multi_text = true; $this->securimage->multi_text_color = array( new Securimage_Color(184, 4, 50), new Securimage_Color(12, 67, 157), new Securimage_Color(244, 49, 11) ); $this->securimage->text_color = new Securimage_Color(184, 4, 50);
I'm trying to change my captcha colors using this idea but my captcha.php file doesn't have that many lines... it only has the following code:
Am I looking in the wrong file?
<?php defined('C5_EXECUTE') or die("Access Denied."); class ValidationCaptchaHelper { public function __construct() { Loader::model('system/captcha/library'); Loader::model('system/captcha/controller'); $captcha = SystemCaptchaLibrary::getActive(); $this->controller = $captcha->getController(); } public function __call($nm, $args) { if (method_exists($this->controller, $nm)) { return call_user_func_array(array($this->controller, $nm), $args); } } }
Am I looking in the wrong file?
i figure it too, it was for 5.4.x
Anybody know how to change the captcha colors in version 5.5.0?
concrete/models/system/captcha/types/secureimage/controller.php
perfect! thanks for the tip.
I would strongly recommend using reCaptcha instead of the default concrete5 one. It has been compromised on many sites (including this one).
http://www.concrete5.org/community/forums/block_requests/recaptcha-...
Search for "Attachment"
http://www.concrete5.org/community/forums/block_requests/recaptcha-...
Search for "Attachment"
(btw, i tried to override the captcha helper to do it through there, but something funky was happening with overrides there)