-1

I have a header like this:

enter image description here

I would like to add a button "Buy tickets" that links to a html page. How can I do this in easy way?

1
  • go to structure/blocks, add new block, set full html on format, write your html there, save block, now on blocks page find your block and place it in top bar section.
    – pinueve
    Mar 27 '18 at 9:34
2

There are a couple of ways of achieving this:

First way is to edit your theme's page.tpl.php file and add your custom html into the correct region. This will ensure your button will appear on all pages, unless you have any custom templates (page-front.tpl.php for example) that override specific pages. In this case you would simply add your code to the custom templates also.

Second method (and probably the easiest) is to create a custom block by visiting www.site.com/admin/structure/blocks and slicing on "+add block". You can then create a block with the html you need - you may need to change the input format of the text box in order to allow all your html code.

As you create this custom block you can decide which region the block will be placed into, making sure it's for the correct theme, and which pages it will appear on. Hopefully it should clear how you can achieve this from the UI.

Save your block and it should now appear!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.