Created
November 18, 2012 17:22
-
-
Save deckerweb/4106349 to your computer and use it in GitHub Desktop.
Genesis Widgetized Archive -- hooks, filters and constants for customizing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Constants: | |
/** Genesis Widgetized Archive: Remove Second Widget Area */ | |
define( 'GWAT_NO_SECOND_WIDGET_AREA', true ); | |
/** Genesis Widgetized Archive: Remove Third Widget Area */ | |
define( 'GWAT_NO_THIRD_WIDGET_AREA', true ); | |
/** Genesis Widgetized Archive: Remove Widgets Shortcode Support */ | |
define( 'GWAT_NO_WIDGETS_SHORTCODE', true ); | |
// Hooks: | |
add_action( 'gwat_before_widgetized_area', 'custom_content_before_widgetized_area' ); | |
/** Genesis Widgetized Archive: Add custom stuff before widgetized area */ | |
function custom_content_before_widgetized_area() { | |
// Your specific before code here... | |
} | |
add_action( 'gwat_after_widgetized_area', 'custom_content_after_widgetized_area' ); | |
/** Genesis Widgetized Archive: Add custom stuff after widgetized area */ | |
function custom_content_after_widgetized_area() { | |
// Your specific after code here... | |
} | |
// Filters: | |
add_filter( 'gwat_filter_archive_one_widget_title', 'custom_archive_one_widget_title' ); | |
/** | |
* Genesis Widgetized Archive: Custom Archive Page Template Widget Title | |
*/ | |
function custom_archive_one_widget_title() { | |
return __( 'Custom Archive Page', 'your-child-theme-textdomain' ); | |
} | |
/** | |
* Same principles apply to the other widget area titles/ descriptions: | |
* gwat_filter_archive_one_widget_title | |
* gwat_filter_archive_one_widget_description | |
* gwat_filter_archive_two_widget_title | |
* gwat_filter_archive_two_widget_description | |
* gwat_filter_archive_three_widget_title | |
* gwat_filter_archive_three_widget_description | |
*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Note: The above codes work with plugin version 1.0.0 or higher!
Extended explanation can be found at the plugin's page "FAQ" section:
http://wordpress.org/extend/plugins/genesis-widgetized-archive/faq/
Download "Genesis Widgetized Archive" plugin at WordPress.org:
http://wordpress.org/extend/plugins/genesis-widgetized-archive/