Live search macro alignment


Is there a way to move the livesearch macro around the confluence page?
Because after inserting the macro, it's always floated to the left. What I would want is to make it center.

Thanks in advance! :)

2 answers

1 accepted

2 votes
Answer accepted

To a limited degree, my answer from works here as well. You have some leadway in moving the containing div element for the livesearch box around the page using javascript/css as well.

Neal, could you please post a snippet of code to show how to do this? I've tried a ton of solutions, and I'm able to get it to align right, and to modify the size of the search box (to a point) using the solution on your initial answer to a similar question, but I can not for the life of me figure out how to get the darn search box to center!

It seems because the block element doesn't really have an align parameter like other elements might. But I could be wrong. Your guideance would be much appreciated.

Oh, and for good measure here is the snippet of code I've been using, which successfully changes the width of the search box...

I'm rather determined at this point to find some kind of solution...

<script type="text/javascript">
	"align-self": "center",
	"width": "1000px"


I'm not sure align-self would actually center an element like an input box... You could try using the margin trick:

position: relative;
margin-left: auto;
margin-right: auto;

This would pad either side of the element automatically, and essentially center the input box in the parent div.

Hope this helps!

1 vote

Hi Bq0,

You might want to edit the Page Layout and choose the appropriate column settings. Then, add the Livesearch Macro in the desired column.

Hope this helps.

thanks. my workaround is that after editing the page layout, I added the Section and Columns macro to adjust the desired location for the livesearch box

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Mar 13, 2019 in Marketplace Apps

Marketplace Spotlight: Marketing apps for Confluence to keep your teams working on the same page


245 views 0 6
Read article

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