2014-09-30 17:23:16 +04:00
|
|
|
<?php
|
2016-10-28 22:46:28 +03:00
|
|
|
/** @var $l \OCP\IL10N */
|
2014-10-15 13:58:44 +04:00
|
|
|
/** @var $_ array */
|
2014-09-30 17:23:16 +04:00
|
|
|
?>
|
2014-10-15 13:58:44 +04:00
|
|
|
|
2015-03-16 13:18:25 +03:00
|
|
|
<?php if ($_['previewSupported']): /* This enables preview images for links (e.g. on Facebook, Google+, ...)*/?>
|
2016-07-22 17:13:26 +03:00
|
|
|
<link rel="image_src" href="<?php p($_['previewImage']); ?>" />
|
2014-05-19 21:53:27 +04:00
|
|
|
<?php endif; ?>
|
|
|
|
|
2013-06-25 14:24:14 +04:00
|
|
|
<div id="notification-container">
|
2013-07-05 17:07:05 +04:00
|
|
|
<div id="notification" style="display: none;"></div>
|
2013-06-25 14:24:14 +04:00
|
|
|
</div>
|
|
|
|
|
2016-06-09 13:05:02 +03:00
|
|
|
<input type="hidden" id="sharingUserId" value="<?php p($_['owner']) ?>">
|
2013-10-08 19:19:58 +04:00
|
|
|
<input type="hidden" id="filesApp" name="filesApp" value="1">
|
2013-10-07 18:59:57 +04:00
|
|
|
<input type="hidden" id="isPublic" name="isPublic" value="1">
|
2013-02-28 00:37:14 +04:00
|
|
|
<input type="hidden" name="dir" value="<?php p($_['dir']) ?>" id="dir">
|
|
|
|
<input type="hidden" name="downloadURL" value="<?php p($_['downloadURL']) ?>" id="downloadURL">
|
2017-11-01 16:49:52 +03:00
|
|
|
<input type="hidden" name="previewURL" value="<?php p($_['previewURL']) ?>" id="previewURL">
|
2013-11-15 19:27:41 +04:00
|
|
|
<input type="hidden" name="sharingToken" value="<?php p($_['sharingToken']) ?>" id="sharingToken">
|
2013-02-28 00:37:14 +04:00
|
|
|
<input type="hidden" name="filename" value="<?php p($_['filename']) ?>" id="filename">
|
|
|
|
<input type="hidden" name="mimetype" value="<?php p($_['mimetype']) ?>" id="mimetype">
|
2015-03-16 13:18:25 +03:00
|
|
|
<input type="hidden" name="previewSupported" value="<?php p($_['previewSupported'] ? 'true' : 'false'); ?>" id="previewSupported">
|
2015-12-18 16:00:20 +03:00
|
|
|
<input type="hidden" name="mimetypeIcon" value="<?php p(\OC::$server->getMimeTypeDetector()->mimeTypeIcon($_['mimetype'])); ?>" id="mimetypeIcon">
|
2016-06-09 22:44:54 +03:00
|
|
|
<?php
|
|
|
|
$upload_max_filesize = OC::$server->getIniWrapper()->getBytes('upload_max_filesize');
|
|
|
|
$post_max_size = OC::$server->getIniWrapper()->getBytes('post_max_size');
|
|
|
|
$maxUploadFilesize = min($upload_max_filesize, $post_max_size);
|
|
|
|
?>
|
|
|
|
<input type="hidden" name="maxFilesizeUpload" value="<?php p($maxUploadFilesize); ?>" id="maxFilesizeUpload">
|
|
|
|
|
2016-06-09 18:45:16 +03:00
|
|
|
<?php if (!isset($_['hideFileList']) || (isset($_['hideFileList']) && $_['hideFileList'] === false)): ?>
|
|
|
|
<input type="hidden" name="filesize" value="<?php p($_['nonHumanFileSize']); ?>" id="filesize">
|
|
|
|
<?php endif; ?>
|
2015-01-17 14:11:52 +03:00
|
|
|
<input type="hidden" name="maxSizeAnimateGif" value="<?php p($_['maxSizeAnimateGif']); ?>" id="maxSizeAnimateGif">
|
2014-09-30 17:23:16 +04:00
|
|
|
|
|
|
|
|
2014-05-23 16:15:36 +04:00
|
|
|
<header><div id="header" class="<?php p((isset($_['folder']) ? 'share-folder' : 'share-file')) ?>">
|
2017-07-31 13:19:19 +03:00
|
|
|
<div class="header-left">
|
2017-07-21 19:28:36 +03:00
|
|
|
<span id="nextcloud">
|
2017-06-07 17:06:19 +03:00
|
|
|
<div class="logo logo-icon svg"></div>
|
2017-01-16 22:45:10 +03:00
|
|
|
<h1 class="header-appname">
|
2017-07-21 19:28:36 +03:00
|
|
|
<?php p($_['filename']); ?>
|
2017-01-16 22:45:10 +03:00
|
|
|
</h1>
|
2017-07-21 19:28:36 +03:00
|
|
|
<div class="header-shared-by">
|
|
|
|
<?php echo p($l->t('shared by %s', [$_['displayName']])); ?>
|
|
|
|
</div>
|
|
|
|
</span>
|
2015-05-22 01:04:47 +03:00
|
|
|
</div>
|
|
|
|
|
2017-07-31 13:19:19 +03:00
|
|
|
<div class="header-right">
|
2017-08-12 16:14:59 +03:00
|
|
|
<?php if (!isset($_['hideFileList']) || (isset($_['hideFileList']) && $_['hideFileList'] === false)) { ?>
|
2017-09-29 19:02:14 +03:00
|
|
|
<a href="#" id="share-menutoggle" class="menutoggle icon-more-white"><span class="share-menutoggle-text"><?php p($l->t('Download')) ?></span></a>
|
2017-11-01 14:06:04 +03:00
|
|
|
<div id="share-menu" class="popovermenu menu">
|
2017-08-12 16:14:59 +03:00
|
|
|
<ul>
|
|
|
|
<li>
|
|
|
|
<a href="<?php p($_['downloadURL']); ?>" id="download">
|
|
|
|
<span class="icon icon-download"></span>
|
2017-09-26 15:09:09 +03:00
|
|
|
<?php p($l->t('Download'))?> <span class="download-size">(<?php p($_['fileSize']) ?>)</span>
|
2017-08-12 16:14:59 +03:00
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
<li>
|
2017-11-01 16:12:04 +03:00
|
|
|
<a href="#" id="directLink-container">
|
2017-08-12 16:14:59 +03:00
|
|
|
<span class="icon icon-public"></span>
|
|
|
|
<label for="directLink"><?php p($l->t('Direct link')) ?></label>
|
2017-11-01 16:12:04 +03:00
|
|
|
<input id="directLink" type="text" readonly value="<?php p($_['previewURL']); ?>">
|
2017-08-12 16:14:59 +03:00
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
<?php if ($_['server2serversharing']) { ?>
|
|
|
|
<li>
|
|
|
|
<a href="#" id="save" data-protected="<?php p($_['protected']) ?>"
|
|
|
|
data-owner-display-name="<?php p($_['displayName']) ?>" data-owner="<?php p($_['owner']) ?>" data-name="<?php p($_['filename']) ?>">
|
|
|
|
<span class="icon icon-external"></span>
|
|
|
|
<span id="save-button"><?php p($l->t('Add to your Nextcloud')) ?></span>
|
|
|
|
<form class="save-form hidden" action="#">
|
|
|
|
<input type="text" id="remote_address" placeholder="user@yourNextcloud.org"/>
|
|
|
|
<button id="save-button-confirm" class="icon-confirm svg" disabled></button>
|
|
|
|
</form>
|
|
|
|
</a>
|
|
|
|
</li>
|
|
|
|
<?php } ?>
|
|
|
|
</ul>
|
|
|
|
</div>
|
2017-01-16 22:30:38 +03:00
|
|
|
<?php } ?>
|
2013-07-05 17:07:05 +04:00
|
|
|
</div>
|
2016-06-07 13:28:02 +03:00
|
|
|
</div></header>
|
2016-06-09 19:12:58 +03:00
|
|
|
<div id="content-wrapper">
|
2016-06-09 18:45:16 +03:00
|
|
|
<?php if (!isset($_['hideFileList']) || (isset($_['hideFileList']) && $_['hideFileList'] === false)) { ?>
|
2016-06-09 19:12:58 +03:00
|
|
|
<div id="content">
|
|
|
|
<div id="preview">
|
2015-10-06 17:17:25 +03:00
|
|
|
<?php if (isset($_['folder'])): ?>
|
|
|
|
<?php print_unescaped($_['folder']); ?>
|
2014-01-23 23:15:10 +04:00
|
|
|
<?php else: ?>
|
2017-05-10 15:16:22 +03:00
|
|
|
<?php if ($_['previewEnabled'] && substr($_['mimetype'], 0, strpos($_['mimetype'], '/')) === 'video'): ?>
|
2015-10-06 17:17:25 +03:00
|
|
|
<div id="imgframe">
|
2016-05-24 13:34:37 +03:00
|
|
|
<video tabindex="0" controls="" preload="none" style="max-width: <?php p($_['previewMaxX']); ?>px; max-height: <?php p($_['previewMaxY']); ?>px">
|
2015-10-06 17:17:25 +03:00
|
|
|
<source src="<?php p($_['downloadURL']); ?>" type="<?php p($_['mimetype']); ?>" />
|
|
|
|
</video>
|
|
|
|
</div>
|
|
|
|
<?php else: ?>
|
|
|
|
<!-- Preview frame is filled via JS to support SVG images for modern browsers -->
|
|
|
|
<div id="imgframe"></div>
|
|
|
|
<?php endif; ?>
|
2017-08-12 16:14:59 +03:00
|
|
|
<?php if ($_['previewURL'] === $_['downloadURL']): ?>
|
2015-10-06 17:17:25 +03:00
|
|
|
<div class="directDownload">
|
2017-05-16 21:47:52 +03:00
|
|
|
<a href="<?php p($_['downloadURL']); ?>" id="downloadFile" class="button">
|
2017-01-22 19:32:51 +03:00
|
|
|
<span class="icon icon-download"></span>
|
2015-10-06 17:17:25 +03:00
|
|
|
<?php p($l->t('Download %s', array($_['filename'])))?> (<?php p($_['fileSize']) ?>)
|
|
|
|
</a>
|
|
|
|
</div>
|
2017-08-12 16:14:59 +03:00
|
|
|
<?php endif; ?>
|
2013-07-05 17:07:05 +04:00
|
|
|
<?php endif; ?>
|
2015-10-06 17:17:25 +03:00
|
|
|
</div>
|
2016-07-20 19:34:32 +03:00
|
|
|
</div>
|
2016-06-07 13:28:02 +03:00
|
|
|
<?php } else { ?>
|
2016-06-09 18:45:16 +03:00
|
|
|
<input type="hidden" id="upload-only-interface" value="1"/>
|
|
|
|
<div id="public-upload">
|
2016-09-08 10:13:59 +03:00
|
|
|
<div id="emptycontent" class="<?php if (!empty($_['disclaimer'])) { ?>has-disclaimer<?php } ?>">
|
2016-06-09 13:05:02 +03:00
|
|
|
<div id="displayavatar"><div class="avatardiv"></div></div>
|
|
|
|
<h2><?php p($l->t('Upload files to %s', [$_['shareOwner']])) ?></h2>
|
|
|
|
<p><span class="icon-folder"></span> <?php p($_['filename']) ?></p>
|
2016-09-08 10:13:59 +03:00
|
|
|
<?php if (!empty($_['disclaimer'])) { ?>
|
|
|
|
<p class="disclaimer"><?php p($_['disclaimer']); ?></p>
|
|
|
|
<?php } ?>
|
2016-06-09 18:45:16 +03:00
|
|
|
<input type="file" name="files[]" class="hidden" multiple>
|
|
|
|
|
2016-06-10 15:47:40 +03:00
|
|
|
<a href="#" class="button icon-upload"><?php p($l->t('Select or drop files')) ?></a>
|
|
|
|
<div id="drop-upload-progress-indicator" style="padding-top: 25px;" class="hidden"><?php p($l->t('Uploading files…')) ?></div>
|
|
|
|
<div id="drop-upload-done-indicator" style="padding-top: 25px;" class="hidden"><?php p($l->t('Uploaded files:')) ?></div>
|
2016-06-09 18:45:16 +03:00
|
|
|
<ul>
|
|
|
|
</ul>
|
2016-06-09 13:05:02 +03:00
|
|
|
</div>
|
2016-06-07 13:28:02 +03:00
|
|
|
</div>
|
|
|
|
<?php } ?>
|
2016-06-09 13:05:02 +03:00
|
|
|
<?php if (!isset($_['hideFileList']) || (isset($_['hideFileList']) && $_['hideFileList'] !== true)): ?>
|
2016-06-07 13:28:02 +03:00
|
|
|
<input type="hidden" name="dir" id="dir" value="" />
|
|
|
|
<div class="hiddenuploadfield">
|
|
|
|
<input type="file" id="file_upload_start" class="hiddenuploadfield" name="files[]"
|
2017-03-16 17:01:50 +03:00
|
|
|
data-url="<?php p(OCP\Util::linkTo('files', 'ajax/upload.php')); ?>" />
|
2013-07-05 17:07:05 +04:00
|
|
|
</div>
|
2016-06-07 13:28:02 +03:00
|
|
|
<?php endif; ?>
|
2015-10-06 17:17:25 +03:00
|
|
|
<footer>
|
|
|
|
<p class="info">
|
|
|
|
<?php print_unescaped($theme->getLongFooter()); ?>
|
|
|
|
</p>
|
|
|
|
</footer>
|
2014-01-23 23:15:10 +04:00
|
|
|
</div>
|