How can I automatically remove all of the anchor macros post- MS-Word import?

Tim Colson November 1, 2012

I just imported an MS Word doc. Looks pretty good, but there are as many as four anchor macros in front of every heading, with IDs like "_Toc211850156".

If this was Confluence 3.x, I'd view source, do a search/replace in my favorite text editor, and be done, but I'm in Confluence 4.x OnDemand so I'm clueless on how to automate the process to remove what are literally thousands of anchor tags.

What can I do?

-Tim

Update 2013-Oct-31 :

3 answers

0 votes
Tim Colson October 31, 2013

@Susan - I believe I ended up pasting into my desktop editor (Sublime) as text *first* and then pasting into Confluence.

0 votes
Susan Woster October 31, 2013

Tim, did you come up with any solution for removing the anchors other than editing the Word document? There must be a way via the Source editor... I just can't figure it out!

0 votes
Selcuk Savas
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 1, 2012

Hi Tim,

I think that _tocxxxxxxx means that the anchor created by heading settings in MS Word by a Table of Content. I don't think that you can delete them automatically.

You can fix the document in MS Worn and re-import or use Office macros to embed an office document into a confluence page.

I hope this helps.

Cheers,

Selcuk

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events