How can I customize the text inside the Search Control?

We use the Documentation theme quite a bit and a search control is automatically included on the upper-right of every page. Inside the control, the words "Search Confluence" appears before you actually type any search text in the field. We'd like to change what appears in that control but I can't find what "properties" file contains the text that gets displayed. Any ideas? Thanks.

3 answers

1 accepted

This widget could not be displayed.

Hi Roy,

You could put the following on the Confluence Admin >> Custom HTML >> At end of the HEAD

<script type="text/javascript">
AJS.toInit(function() {
AJS.$('#quick-search-query').attr('placeholder','Your String Here');
});
</script>

Please change Your String Here to relevant text.

Hope it helps

Thanks both Uday and Rian, this worked (mostly). It solves my basic problem. Unfortuantely, it leaves a little artifact on a space that uses the Adaptavist Theme Builder but that is a small matter. It works prefectly on all the main spaces in our site and is a good technique to recommend to others who are trying to brand their sites. Appreciate the help!

This widget could not be displayed.

AJS.$("#header .quick-search-query").val("your search Text Here");

You can place this in 'At end of the HEAD' section.

Hope this will help.

Tried it. All that happenned was the "AJS.$("#header.quick-search-query").val("My Search Test");" showed up as a text string above the menu bar. I'm sure I'm doing something wrong, but still looking for a solution.

This widget could not be displayed.
AJS.toInit(function() {
AJS.$("#header .quick-search-query").val("your search Text Here");
});
The above code will work. you should add the line betwen toInit() method.
Place the aboce code in custom HTML-->At the end of the Head.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Monday in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

370 views 2 6
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