Using Froala
editor in Laravel5
project. Have included all the .js and .css files to properly open the image toolbar plugin.
I can browse images that are already on my machine, but when I try to upload, it errors out with "Something went wrong. Please try again" which I am assuming is a canned response. I displayed the error thrown and it was connected to something went wrong during the upload.
Below is my script for calling the editor:
<script>
$(function() {
$('#body').froalaEditor({
imageUploadURL: '/uploadpageimages/{!! $page->pgeID !!}',
imageUploadParam: 'file',
imageManagerLoadURL: '/viewpageimages/{!! $page->pgeID !!}',
toolbarButtons: ['undo','|','bold','italic','underline','strikeThrough','subscript','superscript','|','paragraphFormat','align','formatOL','formatUL','indent','outdent','|','insertTable','-','fontFamily','fontSize','color','|','insertImage','insertLink','insertFile','insertVideo','|','html']
})
});
</script>
Like I say, when I load the imageManager
, all works fine, but when I try to upload, I am not even getting to my upload URL. I have set debugging stops within the code, but it never makes it there before the error is thrown.
Anyone work with Froala 2
in a php
framework and have this working?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire