porting PHRAS-1616 to 4.1

This commit is contained in:
Mike Ng
2018-01-03 17:08:02 +04:00
parent 0d7c2bd52d
commit 82d9ef86a4
2 changed files with 38 additions and 26 deletions

View File

@@ -33,20 +33,20 @@
({% trans with {'%maxFileSizeReadable%' : maxFileSizeReadable} %}maximum : %maxFileSizeReadable%{% endtrans %}) ({% trans with {'%maxFileSizeReadable%' : maxFileSizeReadable} %}maximum : %maxFileSizeReadable%{% endtrans %})
</span> </span>
</td> </td>
<td class='uploader-icon'> {#<td class='uploader-icon'>#}
<img src='/assets/common/images/icons/logo-flash.png' width="32px" heigh="32px" title="{{ 'You are using the Flash uploader.' | trans }}"/> {#<img src='/assets/common/images/icons/logo-flash.png' width="32px" heigh="32px" title="{{ 'You are using the Flash uploader.' | trans }}"/>#}
</td> {#</td>#}
<td class='uploader-info'> {#<td class='uploader-info'>#}
<p> {#<p>#}
{{ 'You are using the Flash uploader.' | trans }} {#{{ 'You are using the Flash uploader.' | trans }}#}
{% if not app['browser'].supportFileAPI() %} {#{% if not app['browser'].supportFileAPI() %}#}
{{ 'This version does not allow you to access all the features offered by the HTML5 uploader' | trans }} {#{{ 'This version does not allow you to access all the features offered by the HTML5 uploader' | trans }}#}
{% endif %} {#{% endif %}#}
</p> {#</p>#}
{% if app['browser'].supportFileAPI() %} {#{% if app['browser'].supportFileAPI() %}#}
<a id="UPLOAD_HTML5_LINK" href="{{ path('upload_html5_form') }}" class="dialog full-dialog">{{ 'Use the HTML5 uploader' | trans }}</a> <a style="display: none" id="UPLOAD_HTML5_LINK" href="{{ path('upload_html5_form') }}" class="dialog full-dialog">{{ 'Use the HTML5 uploader' | trans }}</a>
{% endif %} {#{% endif %}#}
</td> {#</td>#}
</tr> </tr>
</table> </table>
{# settings box #} {# settings box #}
@@ -121,6 +121,12 @@
</div> </div>
</form> </form>
<div>
<select name="upload_type" id="upload_type" class="input-large" style="width: 200px; float:right">
<option value="html">{{ 'Use the HTML5 uploader' | trans }}</option>
<option value="flash" selected>{{ 'Use the Flash uploader' | trans }}</option>
</select>
</div>
</div> </div>
</div> </div>
</div> </div>

View File

@@ -36,18 +36,18 @@
({% trans with {'%maxFileSizeReadable%' : maxFileSizeReadable} %}maximum : %maxFileSizeReadable%{% endtrans %}) ({% trans with {'%maxFileSizeReadable%' : maxFileSizeReadable} %}maximum : %maxFileSizeReadable%{% endtrans %})
</span> </span>
</td> </td>
<td class='uploader-icon'> {#<td class='uploader-icon'>#}
<img src='/assets/common/images/icons/html5-logo.png' width="32px" heigh="32px" title="{{ 'You are using the HTML5 uploader.' | trans }}"/> {#<img src='/assets/common/images/icons/html5-logo.png' width="32px" heigh="32px" title="{{ 'You are using the HTML5 uploader.' | trans }}"/>#}
</td> {#</td>#}
<td class="uploader-infmaxFileSizeo"> {#<td class="uploader-infmaxFileSizeo">#}
<p> {#<p>#}
{{ 'You are using the HTML5 uploader.' | trans }} {#{{ 'You are using the HTML5 uploader.' | trans }}#}
{% if not app['browser'].supportFileAPI() %} {#{% if not app['browser'].supportFileAPI() %}#}
{{ 'Your browser does not support all HTML5 features properly.' | trans }} {#{{ 'Your browser does not support all HTML5 features properly.' | trans }}#}
{% endif %} {#{% endif %}#}
</p> {#</p>#}
<a id="UPLOAD_FLASH_LINK" href="{{ path('upload_flash_form') }}" class="dialog full-dialog">{{ 'Use the Flash uploader' | trans }}</a> <a style="display: none" id="UPLOAD_FLASH_LINK" href="{{ path('upload_flash_form') }}" class="dialog full-dialog">{{ 'Use the Flash uploader' | trans }}</a>
</td> {#</td>#}
</tr> </tr>
</table> </table>
@@ -131,6 +131,12 @@
</div> </div>
</form> </form>
<div>
<select name="upload_type" id="upload_type" class="input-large" style="width: 200px; float:right">
<option value="html" selected>{{ 'Use the HTML5 uploader' | trans }}</option>
<option value="flash">{{ 'Use the Flash uploader' | trans }}</option>
</select>
</div>
{% else %} {% else %}
{{ 'You can not upload files' | trans }} {{ 'You can not upload files' | trans }}
{% endif %} {% endif %}