Hi,
Thanks for looking at this post.
I know you can add some HTML to add a sitewide banner across confluence. I was wondering if there is a way I could have the banner appear only across all personal spaces.
I am thinking maybe with some java script. I know confluence has a diffrentiator in the system between global spaces and personal spaces so maybe an if personal space then display.
Any ideas?
Thanks,
Aaron
Community moderators have prevented the ability to post new answers.
Hi Aaron,
My specialty is not in this area, but I'll take a stab. I would recommend that you work with the default customizing the space layout:
https://confluence.atlassian.com/display/DOC/Customising+Space+Layouts
If you look under Confluence Admin > Layouts > Space Layout > create custom
You'll see the template behind the default space layout. I noted this bit here:
#if($useSpaceSideBar)
#putMetadata('space-key', $space.key)
#putMetadata('space-name', $space.name)
Confluence grabs some metadata about the $space.key. Since you want to inject a header if one is looking at a personal space, you could create an #if block to check the $space.key for a ~. All personal space key's are ~username. So run the if block to ckeck $space.key like '~%' or similar. I'm not sure how to run that in actual velocity notation but I think you're on the right track there.
Hope that helps!
Thanks Ryan,
Ill look into the sytax for velocity and see how I can do this one.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.