5450 Posts in 1672 Topics by 1197 members
|Go to End|
30 August 2010 at 2:40pm
I'm new to SS.
I've got 2.4.1 installed.
1. Can I have different tinymce settings for different roles? (If yes, how is that accomplished?)
2. What do I need to change in order to get tinymce to allow the following code:
<a href="http://www.google.com/recaptcha/mailhide/d?k=01iEAR52Ac2Nww-Kte4m_RHQ==&c=40xscf07XuDYgxvFJrVEdOiQ2jC_KyA2dbtJh-WOJIs=" onclick="window.open('http://www.google.com/recaptcha/mailhide/d?k\07501iEAR52Ac2Nww-Kte4m_RHQ\75\75\46c\07540xscf07XuDYgxvFJrVEdOiQ2jC_KyA2dbtJh-WOJIs\075', '', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=300'); return false;" title="Reveal this e-mail address">email me</a>
The tinymce filter strips the onclick=window.open portion of the code.
I've reviewed the instructions at doc.silverstripe.org/htmleditorconfig I would prefer not to turn off all validation.
30 August 2010 at 7:28pm
Hi and welcome to SilverStripe
1) I also tried this once. This thread might help you: http://ssorg.bigbird.silverstripe.com/general-questions/show/280243
There are several ways around that issue though.
A) Create a custom shortcode for popup-windows. The user can then enter the URL and the desired window-size. These docs can help you getting started with sortcodes: http://doc.silverstripe.org/shortcodes, http://ssbits.com/2-4-using-short-codes-to-embed-a-youtube-video/
B) Use jQuery to open some links in a popup window. You could create a special CSS class (eg. "popup") in typography.css which you can then assign in the WYSWYG Editor. Load jQuery in your page and the following Script, and you're set:
All links that have the "popup" class applied will then open in a popup.
|Go to Top|