Hi,
I need to get the currently selected tag.
So, i am using editor.getSelectedElement();
in my editor has code in html like
the design mode content looks like below.
when the user right cliks with in any of this tag, i need to get the selected tag in editor.
so, iam using editor.getSelectedElement();
the tag format assigned in editor like'
<tag1><tag2><p>text</p></tag2><tag1>
tag1 is click, the getselectedelemat return the <p> tag always.
because the <p> is the editable tag, which contain the text.
but the user selected the not editable tag, that is the root tag of <p> tag.
How to get the exact tag that is selected in editor.
Thanks,
Uma
I need to get the currently selected tag.
So, i am using editor.getSelectedElement();
in my editor has code in html like
<s
ubelement
id
=
"717"
type
=
"complementary"
><
tag
type
=
"open"
text
=
"complementary"
elem-tag
=
"subelement"
>|</
tag
><
p
><
tag
type
=
"open"
text
=
"p"
elem-tag
=
"p"
>|</
tag
>
An increasing amount of information on complementary and alternative medicine is becoming available. The scope of the BNF is restricted to the discussion of conventional medicines but reference is made to complementary treatments if they affect conventional therapy (e.g. interactions with St John's wort—see Appendix 1). Further information on herbal medicines is available at
complementary-and-alternative-medicine|
p| An increasing amount of information on complementary and alternative medicine is becoming available. The scope of the BNF is restricted to the discussion of conventional medicines but reference is made to complementary treatments if they affect conventional therapy (e.g. interactions with St John's wort—see Appendix 1). Further information on herbal medicines is available at XRef : http://www.mhra.gov.uk| www.mhra.gov.uk |Xref : http://www.mhra.gov.uk . |p
|complementary-and-alternative-medicine
when the user right cliks with in any of this tag, i need to get the selected tag in editor.
so, iam using editor.getSelectedElement();
the tag format assigned in editor like'
<tag1><tag2><p>text</p></tag2><tag1>
tag1 is click, the getselectedelemat return the <p> tag always.
because the <p> is the editable tag, which contain the text.
but the user selected the not editable tag, that is the root tag of <p> tag.
How to get the exact tag that is selected in editor.
Thanks,
Uma