Search Results for header element

42 results found

generate_page_hero_post_author

The generate_page_hero_post_author allows us to alter the HTML of the post author when using {{post_author}} template tag in header element. Example If we don’t want a link surrounding the post author:

How to Create a Page Hero

The Header element module is one of the most popular features of GP Premium and the amount of options available can definitely be overwhelming at the beginning. If you are struggling to make a page hero, the following steps should provide a quick guideline on how to get started. For detailed explanation of each option, […]

generate_page_hero_terms_separator

Note: This filter requires the Header Element add-on in GP Premium. The generate_page_hero_terms_separator filter allows us to alter or remove the comma between each category/tags inside Header Element. Example The PHP snippet below removes the comma:

Page Hero Background Video

Adding a background video to our Page Hero (Header Element) is super easy. We just need to add some HTML into the content area, and add some CSS to our site. The first thing we need to do is structure our HTML within our Element content. Here’s an example: In the HTML above, you’ll notice […]

Show the “Updated” Post Date

In some cases, you may wish to show the date your post was last updated instead of the published date. We can do this with a little CSS: .posted-on .updated { display: inline-block; } .posted-on .updated + .entry-date { display: none; } If you wish to display some text before the date, you can do […]

generate_menu_bar_items

The generate_menu_bar_items hook allows you to hook non-menu item elements such as buttons, icons and whatever else your design requires. Content added there will automatically display in the navigation and mobile header. Using a Hook Element If you have GP Premium, you can use a hook element and add the content like this: Using a Function […]

Animated Hamburgers

By default, our mobile menu icon doesn’t do any animated when you click it. We prefer to skip the animation and move straight to a close icon, as it’s more lightweight that way. However, if you want to animate your mobile menu icons (hamburger icons), you can do some with some custom code. The first […]

generate_page_hero_location

The generate_page_hero_location allows you to move a page hero to other available hooks. For example, the following PHP snippet would move it to the generate_before_content hook:

Adding Breadcrumbs

GeneratePress doesn’t have built-in breadcrumbs. However, it is easy to add breadcrumbs from a third party plugin using hooks. We will use Yoast SEO for the examples below but the method should apply to any breadcrumb plugins. Using Hooks Element If you have GP Premium, the easiest method is to use our Hooks Element. Go […]

Faux Full Screen Page Hero

Starting in GP Premium 1.7, the Full Screen option is only available when Merge with content option is selected. The reason is because Full Screen without having the header merged required javascript and was a little hacky, and it’s not truly full screen if the header isn’t merged. However, if you would like to size […]