Hi,

we're using scaffolding to create standardized pages.
In these pages we use textareas, so the user cannot easily forget certain subjects.
The last of these texareas is for the user to add his/her own subjects, so i cannot use Headings outside this textarea in that case.

We've noticed that Headings embedded in a textarea aren't included in the TOC.

Do you know/have a solution for this?

(we're using Confluence v3.5.6 and Scaffolding v3.4.2)

2 answers

Hi Ruben,

I did a quick test an was able to replicate the problem. It seems that the {toc} macro is caching the TOC (which is a good thing, since generally the layout doesn't change, and it saves it from having to render the whole page twice every time you view it), however it's not updating the cache when Scaffolding data is saved.

I'm not sure if this is due to Scaffolding not sending out the correct event when it updates the page, or if it's something in TOC, or both, however there is a workaround. Simply add '?refresh=true' to the URL to force the TOC to refresh after you save a Scaffold page. Not ideal, but it's the best I've got at the moment.

It may also be worth raising an issue for Scaffolding (https://greenhouse.customware.net/jira/browse/SCAFF) and/or the TOC (https://studio.plugins.atlassian.com/browse/TOC).

Hope that helps!

David Peterson

This pointed me in the right direction, what i did as a workaround until the root problem is fixed is this:

I created a usermacro {kvk-refresh} which contains following code:

<a href="$content.getUrlPath()?refresh=true">$body</a>

Next, i added a call below my TOC heading in the scaffold like this:

h1. TOC
{kvk-refresh}(update TOC){kvk-refresh}
{toc:style=disc|indent=20px}

At least for now we're safe, i will file an issue for Scaffolding.

I don't actually know how scaffolding works (I haven't examined the customware code), but I do believe that it relies on some mechanism of "including a page," which means you're probably running into a variation of https://jira.atlassian.com/browse/CONF-3844

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Tuesday in Confluence

We want to see the templates you've created in Confluence!

Hi Community, Jessica here from the Confluence Product Marketing team!  July’s community challenge is all about sharing pictures  — and as an extension of our first post on what ...

495 views 19 10
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you