]> source.dussan.org Git - nextcloud-server.git/commitdiff
Merge pull request #4838 from owncloud/refactor_upload_js
authorThomas Müller <thomas.mueller@tmit.eu>
Mon, 16 Sep 2013 08:06:24 +0000 (01:06 -0700)
committerThomas Müller <thomas.mueller@tmit.eu>
Mon, 16 Sep 2013 08:06:24 +0000 (01:06 -0700)
refactor upload js & html to always use only js to fill form data

1  2 
apps/files/templates/index.php

index 09e351d4ea83b2fba1a8faec9c9bb9c0b5c3916f,e481f89beb8b059ed2ead701d89b281e9c676be2..bd991c3fcb04f0f27df4d50079b82bde457b9716
                                        <input type="hidden" class="max_human_file_size"
                                                   value="(max <?php p($_['uploadMaxHumanFilesize']); ?>)">
                                        <input type="hidden" name="dir" value="<?php p($_['dir']) ?>" id="dir">
-                                       <input type="file" id="file_upload_start" name='files[]'/>
+                                       <input type="file" id="file_upload_start" name='files[]'
+                                                  data-url="<?php print_unescaped(OCP\Util::linkTo('files', 'ajax/upload.php')); ?>" />
                                        <a href="#" class="svg"></a>
-                               </form>
                        </div>
                        <?php if ($_['trash'] ): ?>
 -                      <input id="trash" type="button" value="<?php p($l->t('Deleted files'));?>" class="button" <?php $_['trashEmpty'] ? p('disabled') : '' ?>></input>
 +                              <div id="trash" class="button" <?php $_['trashEmpty'] ? p('disabled') : '' ?>>
 +                                      <a><?php p($l->t('Deleted files'));?></a>
 +                              </div>
                        <?php endif; ?>
                        <div id="uploadprogresswrapper">
                                <div id="uploadprogressbar"></div>