2011-08-25 22:50:59 +02:00
|
|
|
{% block captcha_widget %}
|
2012-12-04 12:20:23 +01:00
|
|
|
{% if is_human %}
|
|
|
|
-
|
|
|
|
{% else %}
|
2011-09-08 17:07:04 +02:00
|
|
|
{% spaceless %}
|
2015-05-25 11:41:13 +02:00
|
|
|
<img id="{{ image_id }}" src="{{ captcha_code }}" alt="" title="captcha" width="{{ captcha_width }}" height="{{ captcha_height }}" />
|
2012-12-25 20:07:00 +01:00
|
|
|
{% if reload %}
|
|
|
|
<script type="text/javascript">
|
2013-01-04 08:31:59 +01:00
|
|
|
function reload_{{ image_id }}() {
|
|
|
|
var img = document.getElementById('{{ image_id }}');
|
2012-12-25 20:07:00 +01:00
|
|
|
img.src = '{{ captcha_code }}?n=' + (new Date()).getTime();
|
|
|
|
}
|
|
|
|
</script>
|
2013-01-04 08:31:59 +01:00
|
|
|
<a class="captcha_reload" href="javascript:reload_{{ image_id }}();">{{ 'Renew'|trans({}, 'gregwar_captcha') }}</a>
|
2012-12-25 20:07:00 +01:00
|
|
|
{% endif %}
|
2011-08-25 22:50:59 +02:00
|
|
|
{{ form_widget(form) }}
|
2011-09-08 17:07:04 +02:00
|
|
|
{% endspaceless %}
|
2012-12-04 12:20:23 +01:00
|
|
|
{% endif %}
|
2011-08-25 22:50:59 +02:00
|
|
|
{% endblock %}
|