First of all, hi. I'm new at this and I would very much like if you could help me please.
Here's the thing. I have this module on my Zikula CMS called Mediashare, which works as the Image Gallery for it. One of it's nicest features is that you can call a popup window from a button and it will give you a dialog to traverse your albums with such options as 'Paste the thumbnail' or 'Paste the Preview with a link to your album'.
So what I'm looking for is a way to place a button on my CKEditor toolbar, so that I can call the popup, which is at:
index.php?module=mediashare&type=external&func=finditem&url=relative&mode=html
and get the results get into the editing window.
As much as I have tried reading through this forums and the documentation (and many other resources around the web) I still haven't been able to achieve it.
If helps you, here's the code for the Xinha plugin that does the same :
// mediashare plugin for Xinha // developed by sven schomacker (hilope) // // uses some code from pagesetter/Guppy by Jorn Lind-Nielsen (http://www.elfisk.dk) // requires mediashare module, see url above, licensed under GPL // imagefile taken from pagesetter/Guppy // // Distributed under the same terms as xinha itself. // This notice MUST stay intact for use (see license.txt). function Mediashare(editor) { this.editor = editor; var cfg = editor.config; var self = this; cfg.registerButton({ id : "Mediashare", tooltip : "insert mediashare image", image : _editor_url+"plugins/Mediashare/img/ed_mediashare.gif", textMode : false, action : function(editor) { url = document.location.pnbaseURL + document.location.entrypoint + "?module=mediashare&type=external&func=finditem&url=relative&mode=html"; mediashareFindItemHtmlArea30(editor, url); } }) cfg.addToolbarElement("Mediashare", "insertimage", 1); } Mediashare._pluginInfo = { name : "Mediashare for xinha", version : "2.0", developer : "sven schomacker", developer_url : "http://www.schomedia.com/", sponsor : "hilope.de", sponsor_url : "http://www.hilope.de/", license : "htmlArea" };
The result is a button on the toolbar that, once pressed, opens up the Gallery's popup window and lets you select the Image and the way it should be pasted in your content.
So, what do you say? Is it possible? Maybe you can point me to a resource that can help me and point out what would be missing for it to work as I want?
Thank you very much in advance.
P.S.: After having read like a dozen pages on the subject or so just linking me won't be of much help (I know you are ... Sorry
) . It may very well be that the solution is actually pretty simple (go here, copy that, change this line and this one, presto),
Re: Please Help on Mediashare + CKEditor