Character Counter for a Rich Text Editor

Version  4.1.1.00.23
Hello,
I'm hoping that someone has a solution for a character counter/validation to use on the Rich Text Editor.
Thanks,
Joe

Hi,
Happy New Year.
Ok.
Well, I'm not expert on this, but this peace of code might help you get started.
Code should go to page JavaScript -> Execute when Page Loads
var lEditor=CKEDITOR.instances.Px_YOUR_EDITOR;
lEditor.on('contentDom', function() {
lEditor.document.on('keyup', function(e) {
var len=lEditor.getData().replace(/<[^>]*>|\s/g, '').length;
  /* do here something. JavaScript valiable "len" holds editor text length e.g. */
/* alert(len); */
Replace Px_YOUR_EDITOR with your editor name.
I do not have any idea does it work on all browser. I did test with Firefox.
Regards,
Jari

Similar Messages

  • Display instantly the length of the text entered in the rich text editor

    Hi everybody,
    I'm developing an apex application with apex 4.1.1 and Oracle 11.2.
    I have a page in which I have a form that allows to create a new message on the database.
    A message has a title, description, text and date.
    For the text I use the item "rich editor text". The problem is that item doesn't show the length of characters entered (character counter for the textarea). In the database the corresponding column is varchar2(2000). What I do is a validation after submit that checks if the limit 2000 was exceeded or not.
    But what I want to do more is to display instantly the length of the text entered in the editor. I have tried to do that through a dynamic action. But the event "onChange" for the item "rich text editor" didn't work.
    Has anyone any idea about that issue?
    Thanks for helping.
    Kind regards,
    Edited by: Khadija Khalfallah on Apr 25, 2013 4:06 AM

    sorry about that, I missed that tidbit in your OP... well I think there is a good reason why there isn't a count character option -- due to the hidden "html" characters responsible for the "richness" (bold/color, etc) applied to the text would be difficult to count true characters.. if I was bent on doing this, I'd continue using the item you are using, but have a HIDDEN text area that is updated via javascript onkeyup for each keystroke (again, keeping in mind you'd have to filter certain keys) and then that intelligence could be used. I would probably dig through the javascript responsible for the rich text editor (is it still fckeditor??) -- there might already be code in there that isn't clearly visible to you that does this already.. alas, I see now the validity of your challenge.

  • WYSIWYG online Rich text editor

    Hi
    Apologies if this has been asked before, (I'm new to jsp.). I'm looking for a rich text editor for a JSP website like freetextbox for asp.net.
    I'm sure there are loads out there for jsp or something we can integrate, could anyone point me in the direction of something they've used, heard of or just know about. Any details on how good they might be would be helpful

    You can use any existing rich text editor. Those kind of editors are usually entirely clientside (HTML/CSS/JS) and doesn't have any dependency on JSP nor ASP. The only point where JSP/Servlet comes into action is when the user submits the form with the text to the server.

  • Database Column Type for Rich Text Editor

    Hi,
    I have a page item as Rich Text Editor. Now I want to store the data in tables in the same format as user entered in the page item.
    What would be the database column type for that?
    Thanks,
    Mehabub

    Mehabub Sheikh wrote:
    I have a page item as Rich Text Editor. Now I want to store the data in tables in the same format as user entered in the page item.
    What would be the database column type for that?As usual, the answer is "It depends".
    In this case it depends on the nature and size of the content. For content up to 4000 bytes in length, use VARCHAR2 or NVARCHAR2 (depending on the DB character set and globalization requirements), for content of longer length use CLOB or NCLOB (again depending on DB characterset and your globalization requirements).
    Note the effect of DB character set on the number of characters you can store in a VARCHAR2 or NVARCHAR2 column, and the overhead of HTML tags generated by formatting in the Rich Text Editor.

  • Using rich text editor (RTE) for custom applications

    Our users enter texts on two places:
    1) In Oracle Portal in text-items using the Rich Text Editor.
    2) In text-fields in a custom application using html-tags <textarea>blabla</textarea>. For formatting the users currently have to type in html-tags themselves. Now we want to provide them an html-editor.
    We would prefer to use the Rich Text Editor also for the custom application. However, that is integrated in Portal and the java-scripts are not easy to follow.
    Have you tried something similar? So, did you use the Rich Text Editor for your own application? If yes, how?
    If not, a very good alternative would be the qwebeditor (see http://www.qwebeditor.com). Did anybody replace the standard Portal rich text editor with the qwebeditor? In the Portal guides there are instructions about replacing the Portal rich text editor by another editor, but it is not clear if this will also work with the qwebeditor.
    Thanks for your respons !
    Best regards, Jan Willem Vermeer

    Hi Jan,
    I have configured FCKeditor in a few clients, and the process it's pretty straight forward, you can use the steps in the document (http://www.oracle.com/technology/products/ias/portal/pdf/cm_rte_1014_features.pdf) .
    Basically you download FCKeditor and put it in your apache server (you can put it unde rthe htdocs folder) after that, all you need to do is modify $ORACLE_HOME/portal/images/webword/buildUIHTML.html to reference the FCKeditor JS and CSS, and you can do the same type of reference for your custom apps.
    Regards,
    Juan

  • Rich Text Editor Option for Custom Metadata

    Hi,
    We have created custom profiles for our clients. In one such profile which was created for news updates, client wants to have rich text editor in case of certain custom metadata fields such as description similar to comments.
    As far i as i understand this can be achieved by creating region defintion which gives the option to create a web asset which can edited using site studio api. But is it possible to bring in rich text editor features for custom metadata fields in profiles ?
    Regards,
    Boopathy P

    I'd suggest looking into the profile rule's "Use custom include" option.
    You need to build the new control on your own, but you'll be able to plug it in via the "Use custom include" profile rule option. It's on the "Edit Rule Field" page.
    You can also override the template, but I believe that's a lil' too hardcoded for best practices. This way, you can create a ckeditor textarea and apply it to any metadata you wish (of course, it's up to you to make sure the datatypes match).
    Let us know if this helps!
    -ryan

  • Rich Text Editor for Content Editor WPs (MOSS 2007) disappears using Office 2013/Win7/IE 11

    We've upgraded our computers to Win7/IE 11 but now when I try to edit our MOSS 2007 Content Editor Web Parts, the option to choose either the Rich Text Editor or Source Editor is gone, and all I get is a tiny HTML window. What do I need to do to get back
    the Rich Text edit option?

    Glad that it worked. One thing you need to be aware of Compatibility View is that it adds the entire domain to the View not just the URL. So if your website is
    http://sample.mycompany.com it adds entire mycompany.com to the list.
    This implies if you have another site in the same domain http://onemoresite.mycompany.com , then Compatibility View is applicable even for that site. This might cause issues if your other 'breaks' when
    rendered in Compatibility Mode.

  • Rich Text Editor functionality for a DIV tag in a publishing page in SharePoint online

    Hi,
    We are having a requirement where we need RTE behavior of SharePoint 2013 Rich Html Field for a custom DIV. The scenario goes like this:
    1. I have a publishing page
    2. I dropped the content editor web part and to that content editor web part I will point to an HTML file that needs to be rendered in that content editor web part
    3. I have one DIV in the above mentioned HTML files and I want that div to be editable and I need to RTE options for that DIV.
    How to accomplish the above behavior?

    Hi,
    According to your post, my understanding is that you wanted to create html rich text editor for a DIV tag in a publishing page in SharePoint online.
    You can create your own Rich Text Editor.
    Here are some great blogs for your reference:
    An Example to Use HTML Rich Text Editor
    Example: Using the Editor's instance
    Rich Text Editor control in SharePoint 2010
    Regarding SharePoint Online, for quick and accurate answers to your questions, it is recommended that you initial a new thread in Office 365 forum.
    Office 365 forum
    http://community.office365.com/en-us/forums/default.aspx
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • JHS setting for the Display Type of Rich Text Editor

    In the "Display Type" settings for an item, there is no option in the JHS Definition Editor to choose a "Rich Text Editor" type. Is that intentional or an oversight?
    Thanks,
    Gary

    Gary,
    don't know why it's left out, but you can implement a rich text editor with a custom template (that's the answer I got when I asked the question several months ago). Here's the template code I use for implementing a rich text editor in a table:
    #macro (EDITOR_POPUP)
    <af:popup id="${JHS.current.item.bindingName}Popup" contentDelivery="lazyUncached" eventContext="launcher">
    <af:dialog modal="true" resize="on" title="#TEXT_EDITOR_TITLE()" id="${JHS.current.item.bindingName}Dialog">
    <af:richTextEditor rows="10" columns="100" #ITEM_VALUE_IN_FORM()
    simple="true" id="${JHS.current.item.bindingName}EditorText"/>
    </af:dialog>
    </af:popup>
    #end
    #set ($popupId = ${JHS.page.addPopup("${JHS.current.item.bindingName}Popup","${JHS.engine.fullNamingContainerPath}","#EDITOR_POPUP()")})
    #set ($popupDialogId = ${popupId.replaceAll("Popup","Dialog")})
    <af:panelLabelAndMessage #ITEM_RENDERED_IN_TABLE() #ITEM_PARTIAL_TRIGGERS() #ITEM_HINT()>
    <af:richTextEditor #ITEM_ID_IN_TABLE() #ITEM_VALUE_IN_TABLE() #ITEM_PROMPT_IN_TABLE()
    #ITEM_REQUIRED_IN_TABLE() #ITEM_ROWS() #ITEM_COLUMNS()
    #ITEM_READ_ONLY_IN_TABLE() #ITEM_ADDITIONAL_PROPERTIES()
    #ITEM_DISABLED_IN_TABLE() #DEPENDS_ON_ITEM_PROPS_TABLE()
    simple="true" partialTriggers="${JHS.current.item.bindingName}EditorLink ${popupDialogId}">
    #REGULAR_EXPRESSION_VALIDATOR()
    #VALIDATOR_BINDING_IN_TABLE()
    #NUMBER_CONVERTER()
    </af:richTextEditor>
    <af:commandLink id="${JHS.current.item.bindingName}EditorLink"
    #JHS_PROP("rendered" $JHS.current.item.renderEditorLinkInTable)
    immediate="true" partialSubmit="true">
    <af:showPopupBehavior popupId="${popupId}"/>
    <af:image source="/jheadstart/images/editor.gif" id="${JHS.current.item.bindingName}Icon"
    clientComponent="true"/>
    </af:commandLink>
    </af:panelLabelAndMessage>
    #ITEMS_DISPLAYED_AT_RIGHT_IN_TABLE()

  • I use Juno for my email. How do I turn on the Rich Text Editor and how do I forward messages inline rather than having everything go as an attachment?

    Using Juno I find no way to turn on the Rich Text Editor. How do I turn it on?
    When I forward a message in Juno, everything goes as an attachment. How do I get messages to go inline?

    Another thing to remember is the phone is actually usable for 911 calls and maybe others. Not a real good idea. Especially for a child.
    It would depend however on the age of the child.
    Good Luck

  • How to customize the Rich Text Editor task flow in the doc lib?

    Dear Experts in WCP forum,
    You know that webcenter portal has a feature is called customizing task flow.. so we have client request to customize the Rich Text Editor task flow of the Document library. Such as disable the Format, Font, Size drop down menu of the richtext editor UI.   But after I open the editHTML.jsff of the oracle.webcenter.doclib. the code is like this:
                        <f:facet name="richtext">
                               <af:panelGroupLayout layout="scroll" id="rtepng2">
                                  <rte:editor id="rte" value="#{pageFlowScope.rte.HTMLTextArea}" converter="#{pageFlowScope.rte.HTMLConverter}"/>
                                  <!-- keep region wrapped in the facet to be stretched-->
                                  <af:region value="#{bindings.linksResourcePicker.regionModel}" id="lpr"/>
                               </af:panelGroupLayout>
                            </f:facet>
    So likes that editor in fact is from <rte:editor tag.. my question is how to dig into this <rte:editor  to find its jsff code?  And change the menu inside to do the cusomization for them?
    Is that possible?
    A million thanks here in advance!
    wayne

    Based on the Tag TLD reference the editor tag has the following attributes:
    <tag>
        <description>An ADF Wrapper to use the CKeditor&gt;</description>
        <name>editor</name>
        <tag-class>oracle.webcenter.doclib.rte.internal.taglib.RteEditorTag</tag-class>
        <body-content>JSP</body-content>
        <attribute>
          <description>&lt;html&gt;the identifier for the component.  The identifier
    must follow a subset of the syntax allowed in HTML:
    &lt;ul&gt;
    &lt;li&gt;Must not be a zero-length String.&lt;/li&gt;
    &lt;li&gt;First character must be an ASCII letter (A-Za-z) or an underscore ('_').&lt;/li&gt;
    &lt;li&gt;Subsequent characters must be an ASCII letter or digit (A-Za-z0-9), an underscore ('_'), or a dash ('-').&lt;/li&gt;
    &lt;/ul&gt;&lt;/html&gt;</description>
          <name>id</name>
          <rtexprvalue>false</rtexprvalue>
        </attribute>
        <attribute>
          <description>The initial value of this component.</description>
          <name>value</name>
          <required>false</required>
          <rtexprvalue>false</rtexprvalue>
          <deferred-value>
            <type>java.lang.String</type>
          </deferred-value>
        </attribute>
        <attribute>
          <description>a converter object</description>
          <name>converter</name>
          <deferred-value>
            <type>javax.faces.convert.Converter</type>
          </deferred-value>
        </attribute>
        <attribute>
          <description>
            this is a pass through to get/set the CKEditor ToolbarSet property
          </description>
          <name>toolbarSet</name>
          <required>false</required>
          <rtexprvalue>false</rtexprvalue>
          <deferred-value>
            <type>java.lang.String</type>
          </deferred-value>
        </attribute>
        <attribute>
          <description>
            this is a pass through to get/set the CKEditor height property
          </description>
          <name>height</name>
          <required>false</required>
          <rtexprvalue>false</rtexprvalue>
          <deferred-value>
            <type>java.lang.String</type>
          </deferred-value>
        </attribute>
        <attribute>
          <description>
            this is a pass through to get/set the CKEditor width property
          </description>
          <name>width</name>
          <required>false</required>
          <rtexprvalue>false</rtexprvalue>
          <deferred-value>
            <type>java.lang.String</type>
          </deferred-value>
        </attribute>
      </tag>
    Which means that if you want to change the toolbar you have to check what is the type of toolbars the CKEditor uses, I can tell you that there are two defaults: Basic and Full and I believe the tag uses a custom toolbar called WC by default.
    So if you want to change the toolbar to only show basic, change the toolbarSet property to Basic to make the final result looks like <rte:editor id="rte" value="#{pageFlowScope.rte.HTMLTextArea}" converter="#{pageFlowScope.rte.HTMLConverter}" toolbarSet="Basic" />
    This is not tested, this is only a few insights I got reading about CKEditor

  • Rich text editor (apex 4.0)

    using blue gray theme and a page with a rich text editor. Expanding the rich text options displays the text body p below the text area that persists even if you close the rich text options. Anybody know how to get rid of that behavior?

    I think your mixing 2 technologies.
    At 1 side you have xml in combination with xsl (style sheets used in BI Publisher and FOP) to generate your pdf. And at the other side you have HTML...
    XML and HTML are 2 entirely different technologies which you can not mix this simple. I investigated the same problem as you had, and in the end I ended up using jasperreports instead of FOP.
    Maybe BI Publisher has some html regions which you could insert into your word document but I doubt it cause more people have asked the same question on this board...
    So my advice: use jasperreports (also it is free for commercial usage)
    Success
    Br,
    Nico

  • Rich Text Editor Options

    I am working on a project that needs a Rich-Text Editor with
    ability to insert tables, images, and more complex editing features
    such as what FCKEditor provides but ideally that was built with
    Flex in mind. Is there such an editor available? I have seen a few
    options but nothing that really matched the functionality of
    FCKEditor for example.
    Thanks

    Hello,
    I was looking for flex version of the FCK Editor,
    unfortantly, I could not find a fully complete solution, but I
    found the following which might help you:
    1.
    http://flashtexteditor.com/flexdemo/full/
    2.
    http://drumbeatinsight.com/examples/htmlcomponent/editor/HTMLWithRTE.html
    L.L.

  • Using the Document Manager Rich Text Editor

    I'm wondering whether there is a reasonable way we can use the Rich Text Editor (based on CKEditor) that is contained within the Document Manager task flow (primarily for editing Wiki pages) outside of the Document Manager itself? We have another type of content we need a Rich Text Editor for, but it would be great if we could use the inline image links, tables, links to documents in the content repository, etc.

    Have you consider use Site Studio + Content Presenter?
    http://docs.oracle.com/cd/E17904_01/webcenter.1111/e10149/content_cp.htm
    http://george.maggessy.com/2012/05/inline-editing-in-content-presenter-for_10.html
    []'s

  • Portal Rich Text Editor in Firefox 3.5 Not Working

    I'm using Oracle Portal Version: 10.1.4.0.0 (Build: 594)
    The text item Rich Text editor works fine in IE 6 and has reduced functionality in Firefox 3.0 (scroll doesn't work). I've just updated to Firefox 3.5 and the text editor doesn't work at all now.
    The user is presented with a grey box where all the text controls are squashed into the top left hand corner.
    The following errors appear in the Error Console :
    Error: element.children.tags is not a function
    Source File: http://xyz.example.net:7778/images/webword/WebWordMenuToolbar.js
    Line: 1
    Error: attachEvt is not defined
    Source File: http://xyz.example.net:7778/images/webword/buildUI1.js
    Line: 76
    (I've replaced our server url with http://xyz.example.net)
    Has anyone else noticed this? Has anyone got any suggestions on what I can do to investigate/fix it?
    Thanks,
    Matt
    Update :
    There is a patch available to potentially fix the Rich Text Editor issues in Firefox
    "The Rich Text Editor Does Not Work Correctly In FireFox" - Metalink Doc ID: 456512.1
    or you can replace the RTE completely with a 3rd party editor :
    "How to integrate third party RTE (FCKeditor) with Oracle Portal" - Metalink Doc ID: 352796.1
    Using FCKEditor may well solve the issues but I only use Firefox for development. Our users use IE6 so I don't want to replace the interface unless I have to.
    Edited by: Matt Hawkins on Jul 15, 2009 1:58 PM

    This is a known issue in both Portal 10.1.4.x and Portal 11.x :
    Bug 8708210 (11) NOT ABLE TO RENDER RICH TEXT EDITOR WITH FIREFOX 3.5 BROWSER
    This bug is not published on Metalink.
    There is no solution yet. Consider to use IE Tab (https://addons.mozilla.org/en-US/firefox/addon/1419) for editing file items until this bug is solved.

Maybe you are looking for

  • How do I connect my HP Laserjet 1102w directly to a Linksys AE3500 wireless router with USB option?

    I am trying to connect an HP Laserjet 1102w directly to an HP desktop model a172n with Windows Vista Home Premium OS (32 bit) through a new Linksys AE3500 dual band wireless router which has a USB port for a direct connection. The desktop can see the

  • How to duplicate Item

    Hi, I try to duplicate item with this code                         Dim vItem As SAPbobsCOM.Items                         Dim RetVal As Long                         vItem = oCompany.GetBusinessObject(BoObjectTypes.oItems)                         'Retr

  • Cross system depreciation area

    We are facing a production issue while transferring assets between two company codes . Each company code is assigned to diffreent chart of depreciation with different depreciation areas. Now we have to define cross system depreciation area to resolve

  • Error with Flash when trying to publish

    Hi, I am currently working on a project in Flash and I can not publish, test or view the action script. I have around 20 different Flash files that I have created but only 2 work 100% fine. But last week they were all working fine. When I try to open

  • Port number of network printing to hp laserjet p1102w

    Hi I'm trying to set up network printing for this model on a new wifi modem. Printing of a test page to the printer via wireless went ok, with the port name listed as IP_192.168.0.XX.  I can't see the port number listed anywhere - can anyone tell me