Change embed file directory
This commit is contained in:
parent
df6b311cc4
commit
9a80b94e18
3 changed files with 6 additions and 4 deletions
2
.gitignore
vendored
2
.gitignore
vendored
|
@ -2,6 +2,8 @@
|
|||
/public/build
|
||||
/public/hot
|
||||
/public/storage
|
||||
/public/videos
|
||||
/public/audio
|
||||
/storage/*.key
|
||||
/vendor
|
||||
.env
|
||||
|
|
|
@ -9,12 +9,12 @@
|
|||
@if(preg_match("/\[\[([^\]]+)\]\]/", $checkin->note, $filepath))
|
||||
@if(preg_match("/\.webm/", $filepath[1]))
|
||||
<video controls>
|
||||
<source src="/{{ $filepath[1] }}" type="video/webm">
|
||||
<source src="/video/{{ $filepath[1] }}" type="video/webm">
|
||||
<p>Your browser doesn't support HTML video. Here is a <a href="/{{ $filepath[1] }}">link to the video</a> instead.</p>
|
||||
</video>
|
||||
@elseif(preg_match("/\.ogg/", $filepath[1]))
|
||||
<audio controls>
|
||||
<source src="/{{ $filepath[1] }}" type="audio/off">
|
||||
<source src="/audio/{{ $filepath[1] }}" type="audio/ogg">
|
||||
<p>Download <a href="/{{ $filepath[1] }}">OGG</a> audio.</p>
|
||||
</audio>
|
||||
@endif
|
||||
|
|
|
@ -94,7 +94,7 @@
|
|||
@if(preg_match("/\[\[([^\]]+)\]\]/", $checkin->note, $filepath))
|
||||
@if(preg_match("/\.webm/", $filepath[1]))
|
||||
@php
|
||||
$popupContent = '<video controls><source src="/';
|
||||
$popupContent = '<video controls><source src="/videos/';
|
||||
$popupContent .= $filepath[1];
|
||||
$popupContent .= '" type="video/webm">';
|
||||
$popupContent .= '<p>Your browser doesn\'t support HTML video. Here is a <a href="/';
|
||||
|
@ -103,7 +103,7 @@
|
|||
@endphp
|
||||
@elseif(preg_match("/\.ogg/", $filepath[1]))
|
||||
@php
|
||||
$popupContent = '<audio controls><source src="/';
|
||||
$popupContent = '<audio controls><source src="/audio/';
|
||||
$popupContent .= $filepath[1];
|
||||
$popupContent .= '" type="audio/ogg">';
|
||||
$popupContent .= '<p>Download <a href="/';
|
||||
|
|
Loading…
Reference in a new issue