generate_default_color_palettes

generate_default_color_palettes

This filter allows you to set the default color palettes inside your color pickers in the Customizer.
This filter requires an array in the return.
You should return 8 colors.
add_filter( 'generate_default_color_palettes', 'tu_custom_color_palettes' );
function tu_custom_color_palettes( $palettes ) {
$palettes = array(
'#000000',
'#FFFFFF',
'#F1C40F',
'#E74C3C',
'#1ABC9C',
'#1e72bd',
'#8E44AD',
'#00CC77',
);

return $palettes;
}

generate_premium_url_args

generate_premium_url_args

This filter allows you to add certain arguments to the premium URLs in the free theme Dashboard.
For example, you can add your affiliate ID and campaign to all URLs in the Dashboard and Customizer that point to GeneratePress.
So if my affiliate ID is 1, and my campaign name (optional) is test, I would do this:
add_filter( 'generate_premium_url_args', 'tu_affiliate_id' );
function tu_affiliate_id( $args )
{
$args = array(
'ref' => 1,
'campaign' => 'test'
);
return $args;
}
Now all of the URLs pointing to generatepress.com in the Dashboard will have my affiliate ID and campaign added to them.

Changelogs

Changelogs

Changelogs are logs what what changes took place is certain updates.
In most cases, you can find .txt files in your updates named changelog.txt which has all of the changes.
You can also check out our development blog here.

Removing Comments

Removing Comments

WordPress used to enable comments on all pages by default, but thankfully that』s not the case anymore.
However, they are enabled on posts by default, and might still be enabled on your current pages depending on when you installed WordPress.
1. To stop future pages or posts you add from having comments, go to Settings > Discussion and de-select the couple options at the top dealing with comments and trackbacks. Note that this will only affect future pages, you will still have to do #2 below.
2. To remove comments from existing pages, go to the 「Pages」 area in your Dashboard (or whatever post type you have), and click 「Quick Edit」 within the pages you wish to remove the comments from. While in Quick Edit mode, you』ll see an option to allow comments which you can de-select.
It』s important to note that if your page or post already has comments, disabling them like the above will simply stop new comments from being added. Existing comments and pingbacks will still display. If you wish to remove them, you』ll need to delete the actual comments or pingbacks from your installation in the 「Comments」 area of your Dashboard.
If you wish to disable comments on certain post types but not others (not have them on pages, but do have them on posts), this plugin is great: Disable Comments

Updating GeneratePress

Updating GeneratePress

GeneratePress is the free theme that acts as the framework to your website.
To check what version you』re using, you can go to Appearance > GeneratePress.
From time to time, updates will be released for it and you should update your site to most recent version.
To do this, go to Appearance > Themes and click the Update Now link.
Updating GeneratePress
To learn how to update GP Premium, click here.

Allow Sidebars with Sections

Allow Sidebars with Sections

By default, Sections are meant to be the full width or your content.
In some cases, you may want to use Sections along with your sidebar.
In that case, you need to add this function:
add_filter( 'generate_sections_sidebars','__return_true' );
Learn how to add PHP here.

generate_page_header_video_loop

generate_page_header_video_loop

The generate_page_header_video_loop filter allows you to choose whether the background video in the page header loops or not.
Default (boolean): true
Usage
Please refer to the Using Filters article to learn how to use this filter.

generate_inside_mobile_menu_bar

generate_inside_mobile_menu_bar

The generate_inside_mobile_menu_bar hook appears inside the .mobile-bar-items element which exists if your navigation search is enabled. This element only displays on mobile.
Usage
Please refer to the Using Hooks article to learn how to use this hook.