The Button module is exactly that, a button that you insert into your layout to lead visitors elsewhere within your site or to an external link.
Here are some example of the Button module’s style options:
There are also various options for hover behavior and click action — see the next section for more information about how to set the click action.
- If you add a background color to the Style tab, a Style section will appear with some additional options, including the ability to make the button transparent.
- If you want to set a link for the button but don’t have it right away, just enter a pound sign (#) for the URL so you can save the module.
- Other modules that include buttons: Callout, Call to Action, Contact Form, Subscribe Form.
Click Action: Link or Lightbox
You can set the button’s click action to either a link or a lightbox.
Set the click action to a link
When you set Click action to Link, a Link section opens, where you can enter the URL to the link, whether the link opens in the same window or a new one, and whether to set the link to No Follow for SEO purposes. (If in doubt, leave it set to the default No, which means the search engines are allowed to follow the link)
Tip: If the Link target is another page or post on your site, you can click Selectand start typing part of the page or post title in the Search box to see suggestions appear.
Set the click action to a lightbox
If you choose the Lightbox option, you can also choose whether the lightbox content will be based on HTML that you enter or a link to a video.
With the HTML option, an HTML editing box lets you enter custom HTML that will be displayed in the lightbox. This works great for adding shortcode, for something like a special offer. In the following screenshot, the shortcode for a saved row containing a Call to Action module was inserted into the HTML textbox. You could also add shortcode from third-party plugins.
The video option works well as an alternative to embedding the video in the page. Insert the URL of the video you want to open in the lightbox, from a service such as Youtube or Vimeo.