Why can't I insert the multi-excerpt-include macro using Wiki markup?
Asked by Gabrielle Gagnon:

I need to insert several multi-excerpt-include macros on pages in bulk, but I'm unable to use Wiki markup to do it as I was when I created the multi-excerpt macro entries. When I try, the Wiki Markup macro appears with the multi-excerpt-include macros enclosed inside, and nothing is rendered.

I tried manually inserting the macro, using the editor, and then checked the storage format, using the Source Editor, and it looks like the syntax for both the macro and the parameters has changed:

{multi-excerpt-include:pageTitle=ABC\|name=DEF\|nopanel=true} has become   
{multiexcerpt-include:PageWithExcerpt=ABC\|MultiExcerptName=DEF\|nopanel=true} (or would become that, if the new syntax worked in Wiki Markup, which it doesn't).

When I use the new syntax, the Wiki Markup macro still appears with the macro code enclosed, and it renders an error on the page: "Unknown macro: {multiexcerpt-include}".

I tried changing the name of the macro back to the old version with the hypen (which doesn't generate an error) with different combination of parameter names, but the only results are either nothing or "Page does not exist." (I've double checked the page name and the excerpt name and they always work when I insert the macro manually.)

It's not practical to insert all of these macros individually using the Insert Macro function. Is there some undocumented way of converting this macro to Wiki Markup, and if I can't use Wiki Markup, is there another way to insert these in bulk?

We are using Confluence 5.1.2.  


Answers:
author: Gabrielle Gagnon
body: Thanks for responding, Roy. I see you were just as frustrated as I was.

Our Confluence admin forwarded my question to Artemis support and Brendan got back to us a couple of weeks ago. He was very helpful and explained the situation, but he didn't make any promises. He just said he'd look into getting the storage format to work with Wiki markup, and that only two customers requested the two implementations interact. (I guess you're the other one.)

I don't know if I need the two formats to interact, but they need to at least allow us to use Wiki markup for both of them.

The issue is a bit trickier than people realize. Basically, the old Wiki parameters ("name" and "pageTitle" are still supported, but only if you use Wiki markup to enter and retrieve the excerpt, and the new XHTML parameter names, MultiExcerptName and PageWithExcerpt, are supported, but only if you use the Insert -- Other Macros function, via the Editor. (You can enter an XHTML Multiexcerpt macro in Wiki markup using MultiExcerptName, but not a Multiexcerpt-include macro, so you can't really use Wiki markup in Confluence 4 and 5 as the Artemis demo says. I thought this was misleading at best.)

I have to admit I wasn't fully aware of the problem, until it became important for me to use Wiki markup extensively, and I tested the macros thoroughly. At first when Wiki markup didn't work, I thought I must be doing something wrong. It didn't occur to me that anyone would implement something like this halfway. Maybe that's why more people haven't said anything about it. Let's hope those who don't have time to enter macros through the Editor, which is the only option for retrieving XHTML multiexcerpts now, step up and say they want this fixed.


author: Alexandre Senecal
body: [This video](https://www.youtube.com/watch?v=I8_nFLTV8do) documents a working solution. Here is the markup to use

In one document named **doc1** insert the following markup

```
{multi-excerpt:name=test1}
bob
{multi-excerpt}
```

Now in another document include the excerpt

```
{multi-excerpt-include:pageTitle=doc1|name=test1|nopanel=true}
```


author: Brendan Patterson
body: Hi! [We created a docs page on this:](https://artemis.atlassian.net/wiki/spaces/CMEP/pages/19398764/Wiki+Markup+and+the+new+XHTML+storage+format)


author: Roy Youngman
body: I was dealing with a simliar problem. I posted a question on the Artemis support site since it is their plug-in and got a prompt response: [](https://getsatisfaction.com/artemis/topics/cant_figure_out_the_correct_wiki_markup_for_multi_excerpt_include?utm_content=reply_link&utm_medium=email&utm_source=reply_notification#reply_13707589)[https://getsatisfaction.com/artemis/topics/cant_figure_out_the_correct_wiki_markup_for_multi_excerpt_include?utm_content=reply_link\&utm_medium=email\&utm_source=reply_notification#reply_13707589](https://getsatisfaction.com/artemis/topics/cant_figure_out_the_correct_wiki_markup_for_multi_excerpt_include?utm_content=reply_link&utm_medium=email&utm_source=reply_notification#reply_13707589)

Basically, the issue is the old wiki markup and the new XHTML are both supported, but don't work with one another at this time. They imply they will fix this sometime in the future - I hope soon!

Good luck


Tags: macro

multi-excerpt-macro