Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Hidden content macro displaying in search

HH
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.
January 15, 2018

Hi, 

I've set up a hidden contents macro for my confluence instance. This is so I can put synonyms and keywords into the page without the user seeing it. 

 

It works fine, however I have noticed that when you search on the keywords or synonyms it shows all the data you might have put into the macro within the search result. 

Can anyone think of a way to prevent that? 

searchCaputre.PNG

 

Thanks!

Hollie

1 answer

0 votes
AnnWorley
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 16, 2018

Hi Hollie,

Is the Hidden Contents macro a User Macro you wrote yourself or does it come with an add-on, perhaps? I do not find it on the list of macros that come with Confluence: Macros

There was an issue with hidden page properties macro content being displayed in search results in the past, it was fixed in Confluence 6.0.2 Hidden content of Page Properties macro is available in search when you user have read permissions

Please let me know more about the macro, and also what version of Confluence you are using. If it is a user macro, please post the parameters and code here so I can test it, if it is provided by an add-on please let me know which one.

Thanks,

Ann

HH
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.
January 17, 2018

@AnnWorley This is one that someone else has written- I'm just using it: 

## This is a macro to allow for hidden page content to be picked up by the search and used by the search engine.
## @param Note:desc=Example: The content below will not appear in your document.

## @param Hidden:type=boolean|default=true|desc=Uncheck to temporarily view the content in your document.

#if ($paramHidden == false)

$body

#end

Did try page properties but that didn't solve my problem as none of the keywords or synonyms worked when using the search. Tried it with really obvious words like cheese or toast so that it should have been the only article served with that word but nothing was returned. 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events