Reference site When implementing an editor for blog articles, etc., CKEditor! Even more convenient, cool and easy to use! There is a sample source
<textarea id="ckeditor" name="pageBody"></textarea>
{{-- CKEditor --}}
<script src="//cdn.ckeditor.com/4.15.0/full/ckeditor.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<script src="js/ckeditor.js"></script>
$(function () {
//Apply settings to the editor
CKEDITOR.replace("ckeditor", {
uiColor: "#EEEEEE",
height: 400,
//Spell check function OFF
scayt_autoStartup: false,
//Insert line break tag when pressing Enter
enterMode: CKEDITOR.ENTER_BR,
// Shift+Insert paragraph tag when pressing Enter
shiftEnterMode: CKEDITOR.ENTER_P,
//Allow id and class to be specified
allowedContent: true,
//File manager related
filebrowserImageBrowseUrl: "/laravel-filemanager?type=Images",
filebrowserImageUploadUrl:
"/laravel-filemanager/upload?type=Images&_token=",
filebrowserBrowseUrl: "/laravel-filemanager?type=Files",
filebrowserUploadUrl: "/laravel-filemanager/upload?type=Files&_token=",
//When inserting pre code
format_pre: {
element: "pre",
attributes: {
class: "code",
},
},
//Delete tag breadcrumb trail
removePlugins: "elementspath",
//Make plain text paste even when copying and pasting from the web
forcePasteAsPlainText: true,
//Do not insert spaces automatically
fillEmptyBlocks: false,
//Disable tab input
tabSpaces: 0,
});
};
Reference site Laravel's file management library Laravel File Manager
composer require unisharp/laravel-filemanager
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for unisharp/laravel-filemanager ^2.2 -> satisfiable by unisharp/laravel-filemanager[v2.2.0].
- unisharp/laravel-filemanager v2.2.0 requires ext-exif * -> the requested PHP extension exif is missing from your system.
--It seems that you need an EXIF module to get EXIF information from images in PHP
Reference site Enable EXIF with PHP on docker
RUN docker-php-ext-install exif
RUN docker-php-ext-configure exif \
--enable-exif
composer require unisharp/laravel-filemanager
Recommended Posts