<div class="btn-group attach-file-uploader"
     {% if arguments.tempTag %} data-temptag="{{ arguments.tempTag }}"{% endif %}>
  <noscript>
    <span class="alert alert-danger alert-error">{{ _t('ACTIVATE_JS_TO_UPLOAD_FILES') }}.</span>
  </noscript>
  <div class="qq-uploader">
    <div class="qq-upload-button btn btn-default" title="{{ _t('UPLOAD_A_FILE') }}">
      <i class="fa fa-upload icon-upload"></i>
      <span>{{ _t('UPLOAD_A_FILE_SHORT') }}</span>
    </div>
    <ul class="qq-upload-list"></ul>
  </div>

  {# Template to display uploads, will be injected inside qq-upload-list #}
  <div class="sample-upload-list hide">
    <li>
      <span class="qq-upload-file"></span>
      <span class="qq-upload-spinner"></span>
      <span class="qq-upload-size"></span>
      <a class="qq-upload-cancel" href="#">{{ _t('ATTACH_CANCEL') }}</a>
      <span class="qq-upload-failed-text">{{ _t('FAILED') }}</span>
    </li>
  </div>
</div>

<script>
  var imagesExtensions = {{ config['attach_config']['ext_images']|split('|')|json_encode|raw }};
</script>

{{ include_javascript('tools/attach/presentation/javascripts/qq.js') }}
{{ include_javascript('tools/attach/presentation/javascripts/file-upload-button.js') }}