Changeset 1249
- Timestamp:
- 2008-11-07 10:08:40 (2 months ago)
- Files:
-
- trunk/test/helpers/zazen_test.rb (modified) (1 diff)
- trunk/vendor/plugins/zena_captcha/patch/application_helper.rb (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/test/helpers/zazen_test.rb
r1248 r1249 211 211 assert current_site.update_attributes(:d_mail_hide_priv => '1234', :d_mail_hide_pub => '3456') 212 212 @node = secure!(Node) { nodes(:status) } 213 assert_match %r{ mailhide.recaptcha.net/d\?k=3456&.*window.open}m, zazen("This is an email [email]bob@example.com[/email].")213 assert_match %r{<a href.*mailhide.recaptcha.net/d\?k=3456&.*window.open}m, zazen("This is an email [email]bob@example.com[/email].") 214 214 end 215 215 end trunk/vendor/plugins/zena_captcha/patch/application_helper.rb
r1248 r1249 21 21 enciphered = k.encrypt(address) 22 22 uri = "http://mailhide.recaptcha.net/d?k=#{pub_key}&c=#{enciphered}" 23 t =<<-EOF 24 <a href="#{uri}" 25 onclick="window.open('#{uri}', '', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=300'); return false;" title="#{_('Reveal this e-mail address')}">#{contents}</a> 26 EOF 23 %{<a href="#{uri}" onclick="window.open('#{uri}', '', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=300'); return false;" title="#{_('Reveal this e-mail address')}">#{contents}</a>} 27 24 end 28 25
