| 158 | | } |
| 159 | | |
| 160 | | // Removes the current anchor from the document |
| 161 | | function RemoveAnchor() |
| 162 | | { |
| 163 | | // If it's also a link, then just remove the name and exit |
| 164 | | if ( oAnchor.href.length != 0 ) |
| 165 | | { |
| 166 | | oAnchor.removeAttribute( 'name' ) ; |
| 167 | | // Remove temporary class for IE |
| 168 | | if ( FCKBrowserInfo.IsIE ) |
| 169 | | oAnchor.className = oAnchor.className.replace( FCKRegexLib.FCK_Class, '' ) ; |
| 170 | | return ; |
| 171 | | } |
| 172 | | |
| 173 | | // We need to remove the anchor |
| 174 | | // If we got a fake image, then just remove it and we're done |
| 175 | | if ( oFakeImage ) |
| 176 | | { |
| 177 | | oFakeImage.parentNode.removeChild( oFakeImage ) ; |
| 178 | | return ; |
| 179 | | } |
| 180 | | // Empty anchor, so just remove it |
| 181 | | if ( oAnchor.innerHTML.length == 0 ) |
| 182 | | { |
| 183 | | oAnchor.parentNode.removeChild( oAnchor ) ; |
| 184 | | return ; |
| 185 | | } |
| 186 | | // Anchor with content, leave the content |
| 187 | | FCKTools.RemoveOuterTags( oAnchor ) ; |