diff options
author | Andrey Andreev <narf@devilix.net> | 2017-01-06 11:49:47 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-06 11:49:47 +0100 |
commit | 3a2ea0f3a4c203a9f16c99cb994a5f7de1e61bb2 (patch) | |
tree | 58cfbade785981d8c96d386318d9637993dc5b96 /system/helpers | |
parent | bda2efd42e8896c03d6a95591a6d77bcb761ce26 (diff) | |
parent | 6a7a16073aefbc0bff0fb850d97ea11c57d693c1 (diff) |
[ci skip] Merge pull request #4251 from dimitribalazs/patch-2
Added alt attribute functionality to captcha helper
Diffstat (limited to 'system/helpers')
-rw-r--r-- | system/helpers/captcha_helper.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/system/helpers/captcha_helper.php b/system/helpers/captcha_helper.php index 8f44806cc..442a915ef 100644 --- a/system/helpers/captcha_helper.php +++ b/system/helpers/captcha_helper.php @@ -79,7 +79,8 @@ if ( ! function_exists('create_captcha')) 'border' => array(153,102,102), 'text' => array(204,153,153), 'grid' => array(255,182,182) - ) + ), + 'img_alt' => 'captcha' ); foreach ($defaults as $key => $val) @@ -333,7 +334,7 @@ if ( ! function_exists('create_captcha')) return FALSE; } - $img = '<img '.($img_id === '' ? '' : 'id="'.$img_id.'"').' src="'.$img_url.$img_filename.'" style="width: '.$img_width.'; height: '.$img_height .'; border: 0;" alt=" " />'; + $img = '<img '.($img_id === '' ? '' : 'id="'.$img_id.'"').' src="'.$img_url.$img_filename.'" style="width: '.$img_width.'; height: '.$img_height .'; border: 0;" alt="'.$img_alt.'" />'; ImageDestroy($im); return array('word' => $word, 'time' => $now, 'image' => $img, 'filename' => $img_filename); |