Before commit 5c01371daac13d8451272bb2e37e1bdaaceee472:
if rucaptcha_image_tag function is used in place1, place2, place3
it would generate the same src ru_captcha.root_path
and browser would request image only once AND application would set expected code to cache store only once too
After 5c01371daac13d8451272bb2e37e1bdaaceee472:
if rucaptcha_image_tag function is used in place1, place2, place3
it would generate the 3 different src #{ru_captcha.root_path}?t=1111, #{ru_captcha.root_path}?t=2222, #{ru_captcha.root_path}?t=3333
and browser would request image 3 times
application would set expected code to cache store 3 times too AND the last code wins
Now:
if rucaptcha_image_tag function is used in place1, place2, place3
it would generate the same src #{ru_captcha.root_path}?t=1111
and browser would request image once
application would set expected code to cache store once too
…
My previous commit https://github.com/huacnlee/rucaptcha/commit/5c01371daac13d8451272bb2e37e1bdaaceee472 did more harm than use
Before commit 5c01371daac13d8451272bb2e37e1bdaaceee472: if
rucaptcha_image_tag
function is used in place1, place2, place3 it would generate the same srcru_captcha.root_path
and browser would request image only once AND application would set expected code to cache store only once tooAfter 5c01371daac13d8451272bb2e37e1bdaaceee472: if
rucaptcha_image_tag
function is used in place1, place2, place3 it would generate the 3 different src#{ru_captcha.root_path}?t=1111
,#{ru_captcha.root_path}?t=2222
,#{ru_captcha.root_path}?t=3333
and browser would request image 3 times application would set expected code to cache store 3 times too AND the last code winsNow: if
rucaptcha_image_tag
function is used in place1, place2, place3 it would generate the same src#{ru_captcha.root_path}?t=1111
and browser would request image once application would set expected code to cache store once too