Joy Rex Posted February 28, 2020 Posted February 28, 2020 I'm trying to use the official Media Embed plugin from CKEditor: https://ckeditor.com/cke4/addon/embed The plugin installs fine, but when I attempt to paste in a URL, it fails - a dialog pops up saying it "failed to fetch content for the given URL". I've tried lots of URLs, both that use OEmbed (which I know is required) and those who do not, but nothing works. Any ideas? Related, I am trying to create a custom button that will accept multiple values - I seem to remember being able to do this with the old custom BBCode options in 3.4.x, but the custom editor button only allows {option} and {content}. Any ideas/suggestions are greatly appreciated.
bfarber Posted March 2, 2020 Posted March 2, 2020 For #1 I'd probably inspect the browser developer tools to see what's happening. Unfortunately I couldn't say why it isn't working offhand. For #2 - {option} is not meant to be a literal value, but rather represent the option the user chose. So for instance, if you have a button that accepts an option and a content, it might in effect create something like <font color='{option}'>{content}</font> where {optino} could be red, blue, green, etc.
Joy Rex Posted March 2, 2020 Author Posted March 2, 2020 1 hour ago, bfarber said: For #1 I'd probably inspect the browser developer tools to see what's happening. Unfortunately I couldn't say why it isn't working offhand. For #2 - {option} is not meant to be a literal value, but rather represent the option the user chose. So for instance, if you have a button that accepts an option and a content, it might in effect create something like <font color='{option}'>{content}</font> where {optino} could be red, blue, green, etc. I'll inspect and see what's going on with the embed plugin and why it's not working, thanks. Regarding the {option} value - I know how to use it; my issue was having more than one {option} available, so if several values were required (e.g., {$1} and {$2} for width and height for example) the user could enter them. It was possible with the old custom BBCode feature in 3.4.x - how can I achieve this in 4.x?
bfarber Posted March 3, 2020 Posted March 3, 2020 I don't recall supporting more than one option with custom bbcode in 3.4.x but you're talking a decade ago. There's no built in manner of accepting more than one option.
Joy Rex Posted March 3, 2020 Author Posted March 3, 2020 5 hours ago, bfarber said: I don't recall supporting more than one option with custom bbcode in 3.4.x but you're talking a decade ago. There's no built in manner of accepting more than one option. Yeah, it did (I was on 3.4.x until the middle of last year). Thanks!
Recommended Posts
Archived
This topic is now archived and is closed to further replies.