Remove Default br tag in RichText

When I set the 'removeSingleParagraphContainer' property to true, the RichText editor inserts a <br> tag even if there is no text.  Is there a way to stop this?

<?xml version="1.0" encoding="UTF-8"?>
<jcr:root xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
    jcr:primaryType="cq:TabPanel"
    activeTab="0"
    helpPath="en/cq/current/wcm/default_components.html#Text Image"
    xtype="tabpanel">
    <items jcr:primaryType="cq:WidgetCollection">
        <tab2
            jcr:primaryType="cq:Widget"
            cropParameter="./imageCrop"
            ddGroups="[media]"
            fileNameParameter="./fileName"
            fileReferenceParameter="./fileReference"
            mapParameter="./imageMap"
            name="./file"
            requestSuffix=".img.png"
            rotateParameter="./imageRotate"
            sizeLimit="100"
            title="Image"
            uploadUrl="/tmp/upload/*"
            xtype="smarterimage"/>
       <tab3
            jcr:primaryType="cq:Widget"
            prefix="."
            title="Advanced Image Properties"
            xtype="ImageProperties"/>
        <tab4
            jcr:primaryType="cq:Widget"
            xtype="configcomponentstyles"/>
    </items>
</jcr:root>
The portion that actually declares the RichText fields is in a separate js file here:
CN.Author.widgets.ImageProperties = CQ.Ext.extend(CQ.Ext.Panel, {
    prefix             : './image',
    renditionOptions   : [],
    rendition          : null,
    selectedRendition  : null,
    componentPath      : null,
    ORIGINAL           : "[0:0]",
    USE_SIZE           : "[-1:-1]",
    constructor: function(config) {
        this.CN   = this.CN || {};
        config    = config || {};
        CN.Author.widgets.ImageProperties.superclass.constructor.call(this, config);
    initComponent: function() {
        var
            me = this,
            dialog,
            tabPanel,
             * Populates the panel's form fields.
             * @param {Object} data An object containing metadata
             * @private
            populate = function(data) {
                var
                    fieldPanel = this.getComponent('imageProperties_panel');
                fieldPanel.getComponent('imageProperties_title').setValue(data['dc:title']);
                fieldPanel.getComponent('imageProperties_alt').setValue(data['dc:title']);
                fieldPanel.getComponent('imageProperties_credit').setValue(data['dc:title']);
                fieldPanel.getComponent('imageProperties_desc').setValue(data['dc:description']);
             * Checkbox handler, which is called with every check.
             * @param {CQ.Ext.form.Checkbox} checkbox The checkbox that has been checked/unchecked
             * @param {Boolean} isChecked True if checked
             * @private
            checkHandler = function(checkbox, isChecked) {
                if (isChecked) {
                    populate.call(this, this.CN.imageMetaData);
            damBox = new CQ.Ext.form.Checkbox({
                disabled       : true,
                fieldLabel     : 'Use DAM Meta'
            saveRendition = new CQ.form.Selection({
                fieldLabel     : 'Save this new rendition',
                name           : './saveRendition',
                type           : "checkbox"
            rendition = new CQ.form.Selection({
                name           : './rendition',
                fieldLabel     : "Rendition:",
                type           : "select",
                listeners      : {
                    selectionchanged     : function() {
                        var
                            newValue  = this.getValue(),
                            sizeField = me.fieldPanel.get('imageProperties_size');
                        if (newValue === me.ORIGINAL) {
                             sizeField.reset();
                             sizeField.setDisabled(true);
                        else if (newValue === me.USE_SIZE) {
                            sizeField.setDisabled(false);
                            sizeField.reset();
                        else {
                            sizeField.reset();
                            sizeField.setDisabled(true);
                    loadContent         : function(field,record,path){
                        me.selectedRendition = record.data.rendition;
            fieldPanel   = new CQ.Ext.Panel({
                frame        : false,
                border       : false,
                layout       : 'form',
                autoScroll   : true,
                autoHeight   : true,
                itemId       : 'imageProperties_panel',
                cls          : 'imagePropertiesPanel',
                items        : [
                        itemId                            : 'imageProperties_title',
                        name                                  : this.prefix + '/jcr:title',
                        xtype                             : 'textfield',
                        fieldLabel                        : 'Title',
                        width                             : '95%'
                        itemId                            : 'imageProperties_alt',
                        name                              : this.prefix + '/alt',
                        xtype                             : 'textfield',
                        fieldLabel                        : 'Alt Text',
                        width                             : '95%'
                        itemId                            : 'imageProperties_link',
                        name                              : this.prefix + '/linkURL',
                        xtype                             : 'pathfield',
                        fieldLabel                        : 'Link to',
                        parBrowse                         : true,
                        width                             : '95%'
                        itemId                            : 'imageProperties_credit',
                        name                              : this.prefix + '/photoCredit',
                        xtype                             : 'richtext',
                        fieldLabel                        : 'Photo Credit',
                        width                             : '95%',
                        height                            : 100,
                        removeSingleParagraphContainer     : true,
                        singleParagraphContainerReplacement: 'div',
                        rtePlugins                        : {
                            misctools: {
                                features: ['specialchars', 'sourceedit'],
                                specialCharsConfig: {
                                    chars: {
                                        "copyright": {
                                            "entity": "&copy;"
                                        "degree": {
                                            "entity": "&deg;"
                                        "elipses": {
                                            "entity": "&#133;"
                                        "latin": {
                                            "rangeEnd": "255",
                                            "rangeStart": "192"
                                        "leftanglequote": {
                                            "entity": "&laquo;"
                                        "misc": {
                                            "rangeEnd": "152",
                                            "rangeStart": "145"
                                        "morefractions": {
                                            "rangeEnd": "8543",
                                            "rangeStart": "8531"
                                        "percentage": {
                                            "rangeEnd": "47",
                                            "rangeStart": "32"
                                        "register": {
                                            "entity": "&reg;"
                                        "rightpointquote": {
                                            "entity": "&raquo;"
                                        "trademark": {
                                            "entity": "&#153;"
                                        "vulgarfractions": {
                                            "rangeEnd": "190",
                                            "rangeStart": "188"
                        itemId                            : 'imageProperties_desc',
                        name                              : this.prefix + '/jcr:description',
                        xtype                             : 'richtext',
                        fieldLabel                        : 'Caption',
                        width                             : '95%',
                        height                            : 100,
                        removeSingleParagraphContainer     : true,
                        rtePlugins                        : {
                            misctools: {
                                features: ['specialchars', 'sourceedit'],
                                specialCharsConfig: {
                                    chars: {
                                        "copyright": {
                                            "entity": "&copy;"
                                        "degree": {
                                            "entity": "&deg;"
                                        "elipses": {
                                            "entity": "&#133;"
                                        "latin": {
                                            "rangeEnd": "255",
                                            "rangeStart": "192"
                                        "leftanglequote": {
                                            "entity": "&laquo;"
                                        "misc": {
                                            "rangeEnd": "152",
                                            "rangeStart": "145"
                                        "morefractions": {
                                            "rangeEnd": "8543",
                                            "rangeStart": "8531"
                                        "percentage": {
                                            "rangeEnd": "47",
                                            "rangeStart": "32"
                                        "register": {
                                            "entity": "&reg;"
                                        "rightpointquote": {
                                            "entity": "&raquo;"
                                        "trademark": {
                                            "entity": "&#153;"
                                        "vulgarfractions": {
                                            "rangeEnd": "190",
                                            "rangeStart": "188"
                        itemId            : 'imageProperties_size',
                        widthParameter    : this.prefix + '/width',
                        heightParameter   : this.prefix + '/height',
                        xtype             : 'sizefield',
                        fieldLabel        : 'Size',
                        disabled          : true
                    damBox,
                    rendition,
                    saveRendition
        CN.Author.widgets.ImageProperties.superclass.initComponent.call(this);
        this.rendition     = rendition;
        this.fieldPanel    = fieldPanel;
        this.add(fieldPanel);
        this.CN.damBox     = damBox;
        this.CN.damBox.on('check', checkHandler, this);
        dialog             = this.findParentByType("dialog");
        tabPanel           = this.ownerCt;
        if (dialog) {
            dialog.on("loadcontent", function() {
                 this.onLoadContent(dialog.path);
            }, this);
        if(tabPanel) {
            tabPanel.on("tabchange",function(tabPanel, tab) {
                if(tab.xtype === 'ImageProperties') {
                     this.onActivate(tab);
            }, this);
     * Overrides CQ.Ext.Panel.onRender.  Find the smarterimage component and register a callback onto
     * the CN.customEvents.DAM.response event.
    onRender: function (ct, pos) {
        var
            ownerCt          = this.ownerCt,
            items            = null,
            imgCmpt          = null,
            i                = 0,
            len              = 0;
        if (typeof ownerCt !== "undefined") {
            items = ownerCt.items.items;
            len   = items.length;
            for (i = 0; i < len; i++) {
                imgCmpt = (imgCmpt === null) ? ((items[i].xtype === "smarterimage") ? items[i] : null) : imgCmpt;
            if (imgCmpt !== null) {
                // Let's know about all the images loading on the smarterimage widget
                imgCmpt.on('CN.customEvents.DAM.response', this.onDamResponse, this);
        CN.Author.widgets.ImageProperties.superclass.onRender.call(this, ct, pos);
    onLoadContent: function(path) {
        this.componentPath = path;
    onActivate: function(tab) {
        var
            sizes,
            rendition,
            option;
        if (this.renditionOptions.length === 0) {
            sizes = CN.Author.Util.getConfiguration("dam/sizes");
            this.renditionOptions.push({'text':'-Use size field-','value':this.USE_SIZE});
            this.renditionOptions.push({'text':'Original Size','value':this.ORIGINAL});
            for(rendition in sizes) {
                if(sizes.hasOwnProperty(rendition)){
                    option = {};
                    if(!rendition.match(/jcr/g)) {
                        option['text']  = rendition;
                        option['value'] = sizes[rendition];
                        this.renditionOptions.push(option);
        if (this.renditionOptions.length > 0) {
            this.rendition.setOptions(this.renditionOptions);
            this.rendition.setValue(this.selectedRendition);
     * CN.customEvents.DAM.response handler.
     * @param {Object} metaData The metadata object from the HTTP response of smarterimage
     * @public
    onDamResponse: function(metaData) {
        this.CN.damBox.enable();
        this.CN.imageMetaData = metaData;
CQ.Ext.reg('ImageProperties', CN.Author.widgets.ImageProperties);

Similar Messages

  • How can I remove default alarm for events in iCal on devices ios?

    Whenever I add an event to my iCal calendar in Mounain Lion it will automatically add one default alert only on my iphone and ipad. These default alarms are not displayed on my macbook or icloud.com
    Default alarms are disabled in macbook, icloud.com, and my ios devices.
    How can I remove default alarm for events in iCal on devices ios?
    Thanks and sorry for my english.
    MacBook Pro, Mac OS X 10.8

    OK, so I have had this issue for the past several months. I think it all started when I upgraded to ML from SL and migrated my calendars and contacts to iCloud. That was a couple months ago. But now I am running 10.8.2, and about two weeks ago I upgraded my iOS devices to 6.0.1.
    I don't seem to be having any issues with events that I create now, but all those old events that were migrated to iCloud a couple months ago, many of those sound alerts on the iOS devices even though there was no alert defined when the event was originally created. I have always had alerts off by default both in iCal and on the iOS devices.
    So here's the question: is there a way to go through and disable all these spurious event alerts? I've been disabling them as the event reminders come up, but it's irritating. It would be nice if there was a way to turn them off all in one shot somehow.

  • Remove Empty XML Tags using module parameters

    Hi All,
    In my lanscape I have two PI Systems.
    My scenario is an IDOC reaches 1st PI system gets converted into an EDIFACT and then goes to the 2nd PI and from there it gets routed to the respective AS2 Party.
    I am using SOAP to pass message between the PI systems and B2B Toolkit's AS2 Adapter for the communication with AS2 party.
    The issue is when the message is getting converted from IDOC to EDIFACT there are a few feilds with occurence 1..1 and due to these fields i get an empty XML tag at the output. These empty XML tags give me an error in the B2B Toolkit's AS2 Adapter Receiver Channel
    I cannot change the occurence in the structure of the EDIFACT nor can I use an XSLT mapping to remove empty tags before the message reaches the Communication Channel.
    I want to know if there are any module parameters which i can use either in SOAP Channel or the AS2 Channel to remove the XML Tags.

    Hi Muni,
    "1..1 means, you must send some values for that fields. try to find out why these are not getting any values."
    This empty tag is expected. Before using B2B Toolkit's AS2 Adapter we used to use Seeburger's AS2 Adpater and the message used to get executed successfully with these empty tags.The issue is coming only when we are using B2B Toolkit's AS2 Adapter.
    "if you want to stop sending(the fields which are not needed in target) you can you can disable the fields in the message mapping."
    I cannot disable the feild in the mapping as some other message may use this field.
    Thanks,
    Farhaan

  • Removing message type tag in output file

    Hi guys,
    I'm new to XI. I have done an xml file to xml file scenario. It is working successfully
    The output file has a format
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:mt_xml_receiver xmlns:ns0="http://xml2xml">
         <DETAILS>
              <ID>111</ID>
              <NAME>Varun</NAME>
              <LOCATION>India</LOCATION>
              <ADD>Bangalore</ADD>
              <MOBILE>46572727</MOBILE>
              <EMAIL>[email protected]</EMAIL>
         </DETAILS>
    </ns0:mt_xml_receiver>
    I want to remove the additional tag present for the message type and i want the output in the format
    <?xml version="1.0" encoding="UTF-8"?>
         <DETAILS>
              <ID>111</ID>
              <NAME>Varun</NAME>
              <LOCATION>India</LOCATION>
              <ADD>Bangalore</ADD>
              <MOBILE>46572727</MOBILE>
              <EMAIL>[email protected]</EMAIL>
         </DETAILS>
    Can any one help me on how to achieve this???
    Pl help me on this guys
    Regards
    Varun

    HI Varun,
    This will help you..
    In the message type <b>mt_xml_receive</b>r there is a box where the namespace name is specified.
    Simply delete the same and activate the message type.
    In your case what you can do is as you dont want the message type name also.
    you can create the message type name as DETAILS instead of mt_xml_receiver.
    Regards,
    Sumit
    ps : reward points if tht helped u.

  • How to remove the header tag in the XML data ?

    Hi All,
    I am sending an XML data from SFTP to Proxy, in that I want to remove the header tag (first tag) from the xml, while loading the data. how to do that ?

    Hi,
          It is not about the thing that, whether your source is XML or flat file. If you dont want some thing in your source file , dont consider it and dont map it with your target structure. think that, your not getting the header in your source.  What is the header here.
    <Emp_details>
    <Emp_Id> Employee No </Emp_Id>
    <Emp_Name> Employee Name </Emp_Name>
    </Emp_details>
    <Emp_details>
    <Emp_Id> 1234 </Emp_Id>
    <Emp_Name> xxxx </Emp_Name>
    </Emp_details>
    <Emp_details>
    <Emp_Id> 5678 </Emp_Id>
    <Emp_Name> yyy </Emp_Name>
    </Emp_details>
    you have two fields under node Emp_details. What do u want to avoid here?
    Regards,
    Reyaz

  • Remove un-necessary tags?

    Jdbc to file scenario, in this scenario we need to remove empty value tags from sender or receiver side before creating Xml document in third party.
    Is that possible? I know this is very dummy question but I am new in pi and sdn
    Ex:
    <test>
    <empdetails>
    <emp-no>12</emp-no>
    <emp-name></emp-name >
    <emp-salary>120000</emp-salary >
    <empid></empid>
    </ empdetails>
    <empdetails>
    <emp-no>13</emp-no>
    <emp-name>xsd</emp-name >
    <emp-salary></emp-salary >
    <empid>rt54</empid>
    </ empdetails>
    </test>
    any bisy give solution for this querry.
    Edited by: santhooshv on Dec 20, 2011 7:43 AM
    Edited by: santhooshv on Dec 20, 2011 7:45 AM

    hi,
    <test>
    <empdetails>
    <emp-no>12</emp-no>
    <emp-name></emp-name >
    <emp-salary>120000</emp-salary >
    <empid></empid>
    </ empdetails>
    <empdetails>
    <emp-no>13</emp-no>
    <emp-name>xsd</emp-name >
    <emp-salary></emp-salary >
    <empid>rt54</empid>
    </ empdetails>
    </test>
    As per My knowledge, That is possible with remove the empty tags of the Additional Parameters in u201CAdvanced Modeu201D in Sender Jdbc Communication channel.
    If you want to remove the empty tags from the test of the sender adapter, select Remove Empty Tags. Main advantage is  reduce the size of XML documents.
    <test>
    <empdetails>
    <emp-no>12</emp-no>
    <emp-salary>120000</emp-salary >
    </ empdetails>
    <empdetails>
    <emp-no>13</emp-no>
    <emp-name>xsd</emp-name >
    <empid>rt54</empid>
    </ empdetails>
    </test>
    please gothrough below link:
    http://help.sap.com/saphelp_nw73/helpdata/en/7e/5df96381ec72468a00815dd80f8b63/content.htm
    thanks,

  • Remove the unnecessary tags in XML using PL/SQL

    Hi Friends
    from the below XML, its generate by a complex SQL query, Now we need to remove all the object type tags, and all the empty tags.
    Version - PL/SQL Release 11.2.0.3.0 - Production
    <MajorLine>
        <MAJOR_LINE_OBJECT_TYPE> -- Need to remove these Objects types showing in the XML
            <LINEID>143424538</LINEID>
            <ITEMNAME>TC-ABC-123</ITEMNAME>
            <ITEMPATH>78245</ITEMPATH>
            <QUANTITY>10</QUANTITY>
            <SERVICELINE/> -- Need to remove all the Empty tags
            <MINORLINE>
                <MINOR_LINE_OBJECT_TYPE> -- Need to remove these Objects types showing in the XML
                    <LINEID>143424799</LINEID>
                    <ITEMNAME>TCC-abc</ITEMNAME>
                    <ITEMPATH>78245</ITEMPATH>
                    <QUANTITY>10</QUANTITY>
                    <SERVICELINE/>-- Need to remove all the Empty tags
                    <MINOR_MINOR_LINES>
                        <M_MINOR_LINE_TYPE> -- Need to remove these Objects types showing in the XML
                            <LINEID>143424798</LINEID>
                            <ITEMNAME>SF15-abc-xyz</ITEMNAME>
                            <ITEMPATH>78245</ITEMPATH>
                            <QUANTITY>10</QUANTITY>
                      </M_MINOR_LINE_TYPE>-- Need to remove these Objects types showing in the XML
                    </MINOR_MINOR_LINES>
                </MINOR_LINE_OBJECT_TYPE>--Need to remove these Objects types showing in the XML
            </MINORLINE>
        </MAJOR_LINE_OBJECT_TYPE>-- Need to remove these Objects types showing in the XML
    </MajorLine>
    i tried one of the queries posted in this blog ,PFB  to remove the empty tags , but it didnt work for me unfortunately. Please help.
    PFB
    WITH sample_data AS (
      SELECT xmltype('<MajorLine>
        <MAJOR_LINE_OBJECT_TYPE>
            <LINEID>143424538</LINEID>
            <ITEMNAME>hijk</ITEMNAME>
            <ITEMPATH>78245</ITEMPATH>
            <QUANTITY>10</QUANTITY>
            <SERVICELINE/>
            <MINORLINE>
                <MINOR_LINE_OBJECT_TYPE>
                    <LINEID>143424799</LINEID>
                    <ITEMNAME>efg</ITEMNAME>
                    <ITEMPATH>78245</ITEMPATH>
                    <QUANTITY>10</QUANTITY>
                    <SERVICELINE/>
                    <MINOR_MINOR_LINES>
                        <M_MINOR_LINE_TYPE>
                            <LINEID>143424798</LINEID>
                            <ITEMNAME>abc</ITEMNAME>
                            <ITEMPATH>78245</ITEMPATH>
                            <QUANTITY>10</QUANTITY>
                        </M_MINOR_LINE_TYPE>
                    </MINOR_MINOR_LINES>
                </MINOR_LINE_OBJECT_TYPE>
            </MINORLINE>
        </MAJOR_LINE_OBJECT_TYPE>
    </MajorLine>') xmldoc
      FROM dual
    SELECT deleteXML( t.xmldoc
                    , '/MajorLine/*[.="" or contains(.,"?")]'
                    ) as result
    FROM sample_data t
    My email ID is [email protected] -- You can reach me
    thanks in advance ... Arun thomas T

    Hey Odie. Great to see you again, the query is
    SELECT XMLELEMENT (
              "MajorLine",
              major_line_object_type (
    oola_major.line_id,
    oola_major.ordered_item,
    oola_major.header_id,
    oola_major.ordered_quantity,
                 CAST (
                    MULTISET (
                       SELECT oola_ser.line_id,
    oola_ser.ordered_item,
    --oola_ser.header_id,
    oola_ser.ordered_quantity,
    CAST (
                                 MULTISET (
    SELECT oola_ser2.service_start_date,
    oola_ser2.service_end_date,
    oola_ser2.service_duration
                                      FROM oe_order_lines_all oola_ser2
                                     WHERE oola_major.line_id =
    oola_ser2.service_reference_line_id
                                           AND oola_ser2.header_id =
    oola_major.header_id) AS service_period_table_type)
    FROM oe_order_lines_all oola_ser
                        WHERE oola_major.line_id =
                                 oola_ser.service_reference_line_id
    AND oola_ser.header_id = oola_major.header_id) --As of now excluding cross order service line
    AS SERVICE_TABLE_TYPE),
                 CAST (
                    MULTISET (
                       SELECT oola_minor.line_id,
    oola_minor.ordered_item,
    oola_minor.header_id,
    oola_minor.ordered_quantity,
    CAST (
                                 MULTISET (
                                    SELECT oola_ser1.line_id,
    oola_ser1.ordered_item,
                                           -- oola_ser1.header_id,
    oola_ser1.ordered_quantity,
                                           CAST (
                                              MULTISET (
                                                 SELECT oola_ser3.
    service_start_date,
    oola_ser3.
    service_end_date,
    oola_ser3.
    service_duration
                                                   FROM oe_order_lines_all oola_ser3
                                                  WHERE oola_minor.line_id =
    oola_ser3.
    service_reference_line_id
    AND oola_ser3.header_id =
    oola_major.
    header_id) AS service_period_table_type)
                                      FROM oe_order_lines_all oola_ser1
                                     WHERE oola_minor.line_id =
    oola_ser1.service_reference_line_id
                                           AND oola_ser1.header_id =
    oola_major.header_id) --As of now excluding cross order service line
    AS SERVICE_TABLE_TYPE),
    CAST (
                                 MULTISET (
                                    SELECT oola_minor_m.line_id,
    oola_minor_m.ordered_item,
                                           oola_minor_m.header_id,
    oola_minor_m.ordered_quantity
                                      FROM oe_order_lines_all oola_minor_m
                                     WHERE oola_minor.line_id =
                                              oola_minor_m.link_to_line_id
                                           AND oola_minor_m.header_id =
    oola_major.header_id) --As of now excluding cross order service line
                                                                       AS m_minor_line_table_type)
    FROM oe_order_lines_all oola_minor
                        WHERE    --oola_minor.top_model_line_id=oola_major.line_id
    oola_minor.link_to_line_id = oola_major.line_id
    AND oola_minor.header_id = oola_major.header_id
    AND oola_minor.item_type_code != 'SERVICE') AS MINOR_LINE_TABLE_TYPE)))
              AS "XMLOutput"
      FROM oe_order_lines_all oola_major
    WHERE oola_major.line_id = 143424538 AND oola_major.link_to_line_id IS NULL;
    can we rewirte it to get the desired out put ..
    Desired output is Just remove the Object_type tags and empty tags coming in the output xml.
    The previous issues i mentioned are not solved yet  . actually will update the challenges ..
    Odie .. thanks.. again

  • How to REMOVE [b] H1 Tag[/b] from HTML without changing other Tags?

    Hi there!
    I'm searching for a method to remove Tags from HTML (using HTMLEditorKit, HTMLDocument ...).
    My current code is as follows:
    // first get the whole paragraph
       int iCaretPos = tpMyTextPane.getCaretPosition();
       Object oAttrib;
       HTMLDocument.BlockElement oElem = (HTMLDocument.BlockElement)oMyDocument.getParagraphElement(iCaretPos);
       AttributeSet oAttribs;
       SimpleAttributeSet oNewAttribs;
       int iParaStart = oElem.getStartOffset();
       int iParaEnd = oElem.getEndOffset();
       tpMyTextPane.select(iParaStart, iParaEnd);
       // the following only fetches the Tags that are valid for the whole paragraph!!!!!
       oAttribs = tpMyTextPane.getCharacterAttributes();
       oNewAttribs = new SimpleAttributeSet(oAttribs);
       if(iParaEnd - iParaStart > 0)
          // now analyse the attributes (remove all paragraph-tags)
          for(int iIndex = 0; iIndex < oaOurFormatTags.length; iIndex++)
             oNewAttribs.removeAttribute(oaOurFormatTags[iIndex]);
          if(iParaEnd - iParaStart > 0)
             oMyDocument.setCharacterAttributes(iParaStart, iParaEnd - iParaStart, oNewAttribs, true);
             tpMyTextPane.setCaretPosition(iCaretPos);
          tpMyTextPane.requestFocus();
          tpMyTextPane.repaint();
       }This code works for me, but all Tags of the selected paragraph are removed. That means:
    <P><H1>This is a <B>test</B> text<H2></P>
    will be converted to:
    <P>This is a test text</P>
    but I want it to be converted to:
    <P>This is a <B>test</B> text</P>
    Is there any other method to remove specific Tags (<H1>, ... <H6>) without touching other tags????

    In February I wrote a feature request about this. Today it has been accepted to the bug database. Please make your vote:
    http://developer.java.sun.com/developer/bugParade/bugs/4760082.html

  • How remove an XML tag and its childs?

    Hi all,
    I'm a newbie with XML library. I would like to remove a specific tag and all its childs from an XML document.
    I've modified an example VI  but Error -2607 is generated (see attachment).
    Thanks in advance
    Attachments:
    xmlTest.jpg ‏167 KB

    Post your code and not a picture about it.

  • Changing default META TAG

    Hi,
    is there any solution for changing the default meta tag charset? In my case it's <meta http-equiv="content-type" content="text/html;charset=utf8"> but I need
    <meta http-equiv="content-type" content="text/html;charset=windows-1250">. I can't simply add this meta tag to HTML header, because APEX automatically insert it's own meta tag for character set.
    thanx for your advices
    Robert

    Another issue, which i've solved on my own.
    It's not the question of character set in html meta tag. The solution for this issue was easy. You have to import data with NLS_LANG system variable set to correct language. In my case it was EE8MSWIN1250. After such import, all data are displayed correctly within IE.
    ;o)

  • Eliminating excessive dhcpcd add/remove default route messages

    I've been on an IPv6 network for the past several months. I use no network manager (aside from netctl and wifi-menu) and I'm generally wired in. I manually start dhcpcd on my eth0 when I start my computer.
    The issue I've been having and have been unable to resolve is the fact that the following two messages have been repeating in my log every 2-10 seconds for the past several months and I now have several thousand of them. It's just getting annoying at this point because it interferes with actually reading relevant log messages via journalctl:
    Mar 22 10:45:56 kcuzner-desktop dhcpcd[1109]: eth0: adding default route via fe80::fa8f:caff:fe2d:b464
    Mar 22 10:45:56 kcuzner-desktop dhcpcd[1109]: eth0: removing default route via fe80::fa8f:caff:fe2d:b464
    No matter what I search, I can't seem to find a way to get rid of these. I keep a terminal open with journalctl -f running almost always and it's just filled with these, quickly pushing away relevant messages such as "codeblocks dumped core". Does anyone have any tips for preventing these sorts of log entries?
    Last edited by Los Frijoles (2015-03-22 18:27:41)

    I don't think there is a way for journalctl to exclude logging from only dhcpcd. Of course, you can filter the real time logging to the group of units that you do want to watch but I think you want to watch everything else, right?
    How about trying systemd-networkd rather than dhcpcd? Or, if you are only concerned about certain priority level messages, set the priority level. If everything you want to monitor is priority 4 and below for example, and if this message priority is 6, then you're all set.
    Last edited by nullified (2015-03-22 19:43:59)

  • Regex - Remove specific HTML Tags

    I have already found a solution in the forum to remove all html tags but I need some specific tags - img, a, b, i, u - and also their closing tags - </a>, </b>.
    The regex also needs to differ between img without the class attribute and with class attribute - it should remove elements with class attribute
    So I have tried to modifiy the found solution:
    result = Regex.Replace(result, "<[^(img|a|b|i|u)][^>]*>", " ");
    It works not optimal because it also removes the closing tags, doesn't differ and doesn't remove the br tags. It's not necessary to do all these actions in one statement.

    you can use regular
    <[(/body|html)\s]*>
    in c#:
    var result = Regex.Replace(html, @"<[(/body|html)\s]*>", "");
    <html>
    <body>
    < / html>
    < / body>

  • [svn:fx-] 21427: Removed flex/sdk/tags/trunk4.5.1 - history not maintained!

    Revision: 21427
    Revision: 21427
    Author:   [email protected]
    Date:     2011-06-21 07:16:13 -0700 (Tue, 21 Jun 2011)
    Log Message:
    Removed flex/sdk/tags/trunk4.5.1 - history not maintained!
    Removed Paths:
        flex/sdk/tags/trunk4.5.1/

  • How do I remove the acronym tags from menu items in Business Catalyst?

    Hello, can anybody answer this for me please? Not having any success googling or foruming it so far.
    How do I remove the acronym tags from menu items in Business Catalyst? 
    Thanks in advance
    Grant

    These are titles and in the dynamic menu will be the item description per item.
    These are actually important though and you do not really want to remove them but make them better and reword them other then the same as the link test. These are good for the user experience as well as SEO. A bot knowing a description of a link and where it is going coupled with the URL's and the title of an anchor are all important aspects of your sites SEO.

  • Remove the bilingual "tag"

    How do I remove the bilingual "tag" that appears at the bottom of every email I send? Thanks!
    Solved!
    Go to Solution.

    Here you go:
    Thanks,
    Bifocals
    http://bis.na.blackberry.com/html?brand=bell
    Click Accept as Solution for posts that have solved your issue(s)!
    Be sure to click Like! for those who have helped you.
    Install BlackBerry Protect it's a free application designed to help find your lost BlackBerry smartphone, and keep the information on it secure.

Maybe you are looking for

  • SuperDrive not recognizing OSX install CD?!?

    So with all the other issues I've posted in the last hour or so (other threads) I figured I should run the install disk utilities. Since I bought this Mac secondhand, I do not have the original installation CDs (of course), but borrowed the Tiger CD

  • Help! This is annoying!

    My Ethernet connection keeps dropping on my iBook after only a minute after connecting. The "internet connect" program shows that I am still connected to the internet, but pages will not load in Safari and I get a "You are not connected to the intern

  • What is Adobe Shockwave

    I suddenly keep getting "Adobe Shockwave" folder popping up on my desktop. It pops up at least 3 or 4 times a day. In the folder there is "Shockwave Installer Full Pkg" and "Shockwave Uninstaller app" I don't know where it came from or whether I shou

  • Need help writing a TRIGGER !!!

    The trigger below: create or replace TRIGGER dtworepair_after_update_status AFTER UPDATE OF worepair_status ON dtworepair FOR EACH ROW WHEN (NEW.worepair_status = 'CLOSED') DECLARE --workorder_nbr_var   dtworepair.worepair_wonbr%TYPE;* id_count_var  

  • I want to make a DVD on how to use Garage band and sell them. Do I need apple's permission to do this?

    If I want to write a book on how to make great music in Garage Band and sell the book do I need permisison. I also thought about making video tutorials on the same subject. Again do I need permission to do this?