Adding Support For <abbr> Tags

  •  11-09-2005, 3:58 AM

    Adding Support For <abbr> Tags

    Hi,
     
    I am trying to add a custom button that will display a dialog allowing the user to enter the title attribute for the <abbr> tag.  I can add the button and get the custom dialog to display, however, the following javascript code in the custom dialog will not insert the <abbr> tags into the editor:

    var editor = window.dialogArguments;
    var doc = editor.GetDocument();
    var sel = doc.selection;
    if(sel != null)
    {
        var range = sel.createRange();
        if(range != null)
        {
            var html = "<abbr title='" + Title.value + "'>" + range.text + "</abbr>";
            range.pasteHTML(html);
        }
    }

    However, if I insert <b> tags instead, it works fine.

    Is this an issue with the CuteSoft editor or the MSHTML control?  Is there another way to achieve the same thing?

    I look forward to your reply.
    Kind Regards

    Andy
     
     
View Complete Thread