Solved

Modify Coldfusion cftextarea richtext yes modify toolbar inline

Posted on 2013-01-21
7
983 Views
Last Modified: 2013-02-06
Hi,

I have a function that the experts  helped me solve where it loops through the cftext areas and validates that the length does not exceed what is in the database (http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Jquery/Q_28000781.html).

I try to pull some of the buttons off the editor with this javascript, and it breaks the function that the experts developed.  Any thoughts on how to modify the toolbar without breaking the javascript developed in the previous question?

<script>
function FCKeditor_OnComplete(editorInstance)
{
 editorInstance.Config["ToolbarSets"]["MyToolBar"] = [
 ['SpecialChar','Bold','Italic','Underline','Subscript','Superscript','SpellCheck','Link']
 ];
editorInstance.EditorWindow.parent.FCK.ToolbarSet.Load('MyToolBar' ) ;
}
</script>
0
Comment
Question by:atljarman
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 

Author Comment

by:atljarman
ID: 38804184
I get an exception thrown and not caught from the cfajax file.
0
 
LVL 52

Expert Comment

by:_agx_
ID: 38805337
It works with CF10. All I did was added that function inside the existing <script> tags from the other example.  

Can you post the error and an example that triggers the error? Maybe you're doing something different or perhaps its a version problem? There's probably different version of the editor shipped w/CF7-10, so maybe that syntax isn't supported in your version? That's just a guess though...
0
 

Author Comment

by:atljarman
ID: 38809742
It happens on line 90 of the cfajax file attached.  It says exception thrown but not caught.\

I don't have access to the server files, but I could ask the server folks to create the custom toolbar so that i can just reference. That would likely solve the problem as the script is just stripping away all the icons but what is listed from the full list.
cfajax-1-.txt
0
Webinar: MongoDB® Index Types

Join Percona’s Senior Technical Services Engineer, Adamo Tonete as he presents “MongoDB Index Types, How, When and Where Should They be Used?” on Wednesday, July 12, 2017 at 11:00 am PDT / 2:00 pm EDT (UTC-7).

 
LVL 52

Accepted Solution

by:
_agx_ earned 500 total points
ID: 38810276
Hard to say what's causing it without seeing the error message from the ajax logs/debugger (or your code if it's different). But it works perfectly w/CF10.  What CF version are you running?

Yeah, a custom toolbar would work too or you might be able to do it yourself.
0
 

Author Comment

by:atljarman
ID: 38810304
CF9.  I've put the request in and I will see what they say.
0
 
LVL 52

Expert Comment

by:_agx_
ID: 38810407
Sounds good.
0
 

Author Closing Comment

by:atljarman
ID: 38859914
I created a separate folder and referenced the in the cftextarea. Thanks for your help.  Now if I could get the characters remining to display at the bottom of the cftextarea that would be great!
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There’s a good reason for why it’s called a homepage – it closely resembles that of a physical house and the only real difference is that it’s online. Your website’s homepage is where people come to visit you. It’s the family room of your website wh…
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

628 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question