mirror of
https://github.com/wintercms/winter.git
synced 2024-06-28 05:33:29 +02:00
Fix two minor media manager bugs
This commit is contained in:
parent
58ace7ee6c
commit
28f265c10a
@ -61,8 +61,11 @@ class MediaLibrary
|
|||||||
{
|
{
|
||||||
$this->storageFolder = self::validatePath(Config::get('cms.storage.media.folder', 'media'), true);
|
$this->storageFolder = self::validatePath(Config::get('cms.storage.media.folder', 'media'), true);
|
||||||
$this->storagePath = rtrim(Config::get('cms.storage.media.path', '/storage/app/media'), '/');
|
$this->storagePath = rtrim(Config::get('cms.storage.media.path', '/storage/app/media'), '/');
|
||||||
|
|
||||||
if (!preg_match("/(\/\/|http|https)/", $this->storagePath)) {
|
if (!preg_match("/(\/\/|http|https)/", $this->storagePath)) {
|
||||||
$this->storagePath = Request::getBasePath() . $this->storagePath;
|
$this->storagePath = Request::getBasePath() . $this->storagePath;
|
||||||
|
} else {
|
||||||
|
$this->storagePath .= '/';
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->ignoreNames = Config::get('cms.storage.media.ignore', $this->defaultIgnoreNames);
|
$this->ignoreNames = Config::get('cms.storage.media.ignore', $this->defaultIgnoreNames);
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<script type="text/template" data-control="video-template">
|
<script type="text/template" data-control="video-template">
|
||||||
<video src="{src}" controls poster="<?= URL::to('modules/cms/Widgets/mediamanager/assets/images/video-poster.png') ?>">
|
<video src="{src}" controls poster="<?= URL::to('modules/cms/widgets/mediamanager/assets/images/video-poster.png') ?>">
|
||||||
<div class="panel media-player-fallback">Your browser doesn't support HTML5 video.</div>
|
<div class="panel media-player-fallback">Your browser doesn't support HTML5 video.</div>
|
||||||
</video>
|
</video>
|
||||||
</script>
|
</script>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user