How to integrate TinyMce with Zend Framework with Gzipping and Image managers? - zend-framework

I have done some research on this subject, and found out, that Gzipping and adding a new image manager through a plugin would not be as difficult. The only question is the Image manager.
I have seen some quite good ones, like the Image Manager for JCE, which is a Joomla wysiwyg editor, but none for TinyMce for itself.
Could someone show me a good image plugin?
P.S. SwampyFoot is out of question, as it's download links are broken, and PhP Letters Ajax image manager is quite hard to install.
Thanks!
EDIT: I just found Mad File Manager, which seems to work excelently except for a little glitch: An image can be uploaded, but cant be selected... Thats sad...
EDIT2: I've found KCFinder, which seems to be very promising, but I just can't get it to work properly. Somehow, the configuration is quite difficult.

Ok, So I have been able to answer my question myself. So here it goes:
Set up TinyMce with Sozfo solution. The important ting to remember here is, instead of extending your Forms from Zend_Form, you have to extend them from Sozfo_Form. As to the defining your own extendable controller, it didnt work for me, So I put the path defining helpers in my Bootstrap. And if the whole ordeal works, there is a textarea that should have TinyMCE controls, but there aren't any, try checking the comments at Sozfo, or checking if the page is cached or not. It took me a good hour, to find out, that the only reason why no JavaScript was pushed to the header was because of a very persistent cache.
Set up KCFinder. The main problems I faced here were due to wrong paths to corresponding files. When the paths were correct, the only thing to remember is to enable it. There is a boolean to change in configuration file.
The last issue was adding the KCFinder to my Tinymce, and what I ended up doing was, I added the function needed to call KCFinder in TinyMCE.php View helper. ( Due to some glitch I seem to be unable to post the code here). Once you have set up your paths correctly, everything should work splendidly.
All in all, it took me about 3 days to figure this whole thing out. Talk about steep learning curve...

Have you looked at MCImageManager - its not free but its an option if you're happy to pay for it

Not really a suggest as you've got it but swampy foot download does work
As you're already using zend framework, why not use dojo, set up the dojo form and call the editor element and integrate this http://docs.dojocampus.org/dijit/_editor/plugins/LinkDialog into it?

Related

Can I use TYPO3's RTE in a front end plugin?

I have a custom extension, and i need to use some form of text editor in the front-end. According to the documentation, it should be possible, but the documentation and tutorials seem to be deprecated. I think this is not available in typo3 7.6 :
require_once(t3lib_extMgm::extPath('rtehtmlarea').'pi2/class.tx_rtehtmlarea_pi2.php');
Can it be done somehow or do i need to install another extension for this, maybe just a viewhelper? Thank you in advance.
I did lots of researches trying to use the rtehtmlarea in the FE, but failed. Then, I realized I could use any RTE, as they are nothing but js+css. All I need is to render the contents with RTE.FE, like how the BE does, and save the result into the database, which is all I want. I have already done this in many sites, using standalone tinymce, and it works great. So, I think maybe you could try this solution.
To be honest, that feature worked only in theory and never in reality. Use an RTE like ckeditor or whatever fits best

Can Emmet Be Used to Create FXML?

I have a scalaFX app that currently has its views created programmatically. I am wondering if I can use the Emmet tool to create FXML (particularly ScalaFXML) because I want to recreate my views in ScalaFXML to separate my views from my controllers more effectively. I have searched the internet and cannot find out if this is possible. So far I have only used Emmet for HTML. Thanks in advance for the help!
I have been looking around for something for PrimeFaces; I had trouble finding anything. I guess maybe it's because people who are using it are actually writing "normal" HTML with JS frameworks.
The good news is, it's completely (and easily!) customizable: just find the installation directory, and edit the "snippets.json" file, or create a new one called (for example) snippets-scalaFX.json. Mine on a Windows 10 machine, installed as a plugin for NPP, was C:\Program Files (x86)\Notepad++\plugins\EmmetNPP\emmet\snippets.json.
It's pretty obvious once you get in there, but inside the "snippets" object just add some more fields for yourself. For example, to make a PrimeFaces commandButton tag I added:
"pc": "p:commandButton"
You can use $0 or ${<placeholder text>} to define tabstops for expanded snippets, and | to define the caret starting point.
Full docs on editing snippets are here.

Umbraco Richtext Editor not loading

I've been scratchign my head on this one, hopefully someone can provide some feedback.
Umbraco Version: 4.7.2
Problem
A solution I developed for a company is having problem loading the rich text editor. They have a virtual IP solution acting as a proxy for their servers. After debugging on the client we noticed that the editor (tiny mce) was not loading because for some reason it is requesting the script and icons via the IP and not the URL. Obviously the IP is not hardcoded anywhere...
Need Help...
The client's IT department insists the configuration is ok; I think they are right, everything else in Umbraco seems to be working correctly. So I need help...
Is there anyway I can force the editor to be loaded from a specific URL?
I have experimented with changing the JS on umbraco_client, but the changes do not show when I load the editor. they appear to be cached somewhere (processed by the compressor), I've re-started the app and cleared my cache with no luck. How can I make my JS Changes be picked up?
What I've Tried
Setting the document.domain="my-url". No luck.
Setting the document_base_url on tinyMceConfig.config. Of course this is for links within the editor, so.. no luck
All other changes I've tried are on the JS files on /umbraco_client/tinymce3/, but I can't get them to show.
Any pointers?
Thanks,
-Covo
Is the RTE not rendering within umbraco it self or is the content not rendering on the front end?
This is a very good question - have you tried removing the property and adding again?
Other than what you've tried so far I'm out of suggestions other than the above sorry.

How to define custom wicket tag

I could not find a wicket tag like wicket:include? Can anyone suggest me anything? I want to include/inject raw source into html files? If there is no such utility, any suggestions to develop it?
update
i am looking for sth like jsp:include. this inclusion is expected to be handled on the server side.
To do this, you'll need to implement your own IComponentResolver.
This blog article shows an example somewhat resembling what you're after.
Is it raw markup that you want to include, or Wicket content?
If it's raw markup, even a simple Label can do that for you. If you call setEscapeModelStrings( false), the string value of the model will be copied straight in the markup. (Watch out for potential XSS attacks though.)
"Including" Wicket markup is done via Panels (or occasionally Fragments)
Update: If you add more detail about the actual problem you need to solve, there's a good chance that we can find a more "wickety" solution, after all, JSP and Wicket are two different worlds and the mindset of one doesn't work very well in the other.

GWT Lazy Loading

I want to develop a GWT application. The application contains 8 modules and all the modules run in a single page.
I have links for all the 7 options on the top.
When the page loads I want only the home content to be loaded and displayed.
Only when the user clicks the menu options, the menu content should load.
Can anyone suggest the best way to achieve this.
This has been addressed in GWT 2.0... First you'll remove the separate entry points you have for each module - since they're all on the same page, you only need one entry point per page.
Then you can use the GWT.runAsync() method at each point that you feel can be a split... it automatically cuts up the code into chunks that are downloaded as and when necessary.
Look here for the docs.
AFAIK, lazily loaded (or pluggable) modules can't be done in GWT. Partly this is due to the way the GWT compiler works - it likes to import all the code that it is ever going to see and then optimises and prunes it as viciously as possible (to make the resulting JS files as small and lead as possible). If it doesn't have access to all the source code up front, it might make optimisations that will break the pluggable modules (especially since nothing in the "core" application may reference the classes that the lazily-loaded modules need to work properly - the GWT compiler would prune those "unused" classes in the core module).
This stackoverflow question from May 09 asks the same thing and has the same answer - it can't be done.
I searched high and low about six months ago for an answer to this problem, because I really wanted to do what I believe you're asking for. Never found a solution.
(I haven't used GWT 2.0 - it might have addressed the issue)
Thank you for your answer. You are right that the whole Javascript code gets downloaded.
But there must be a way like say on of module is View Profile. Only when the user clicks the view Profile link, the widgets related to displaying my profile needs to be created. is this not possible.