question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Add ability to use local image upload in wysiwyg editor

See original GitHub issue

I was able to hack it in by modifying wysiwyg additional options property and fooling keystone to think it’s using cloudinary images but it would be great to have a native way to do that. We’d probably need a destination and flag to decide if we want to hash the name or retain original filename. Can’t come up with easy way to link the images to the document that would use it unless we extended field’s schema to also include additional field for storing image references if user have chosen to use wysiwyg local images (or whatever it would be called) that would get updated if image is added, removed or would be used to remove images if entry is removed.

Had to create custom api endpoint to handle the uploads - if anybody needed that for the time being let me know. And there goes the hack 😃

keystone.init({
  ...
  'cloudinary config': { cloud_name: 'not', api_key: 'really', api_secret: 'used' },
  'wysiwyg cloudinary images': true,
  'wysiwyg additional options': {
    'uploadimage_form_url': '/api/admin/upload-image'
  }
});

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Reactions:3
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
christroutnercommented, Jan 12, 2017

@quadrifoliumclover you should check out ConnextCMS. It’s built on top of KeystoneJS and it allows inserting of localy hosted images with the TinyMCE editor.

You can view the source code on GitHub. I ended up having to write a new plugin for TinyMCE.

0reactions
VoronV48commented, Aug 30, 2022

in answer set header

`

res.setHeader(‘Content-Type’, ‘text/html; charset=utf-8’); res.send({“image”:{“url”:“url you picture”}}); `

Read more comments on GitHub >

github_iconTop Results From Across the Web

asp.net mvc - Image upload from local computer in wysiwyg
What´s the best way how can I add image upload from local computer to TinyMCE? I found IMCE but it is just for...
Read more >
Add image uploading to WYSIWYGs through editor.module
1) Type some stuff into the WYSIWYG editor. 2) Try and add a picture. ... 4) Close the dialog, scroll *up* to "Image"...
Read more >
Upload Image | Image Concepts
Image is a plugin for the editor and the image.min.js file must be included before being able to use it. Set the editor's...
Read more >
WYSIWYG Editing and Drag-and-Drop Image Upload with ...
This controller sets up a basic create action that we can POST to via JavaScript. If the image saving is successful, it then...
Read more >
New local upload simplifies adding images to TinyMCE
When you configure the images_upload_url config option, the new tab will automatically appear. To add this functionality to your TinyMCE ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found