Created
June 14, 2016 10:15
-
-
Save salcode/442d39e1d16a3063f8cb248cff27b42e to your computer and use it in GitHub Desktop.
Genesis home.php template to display content before posts on blog page.
This file contains hidden or 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 | |
/** | |
* File for home.php | |
* | |
* Blog page template with page description before blog posts. | |
* | |
* @package example; | |
*/ | |
add_action( 'genesis_before_loop', 'fe_home_genesis_before_loop' ); | |
/** | |
* Output page content on Blog Post page | |
*/ | |
function fe_home_genesis_before_loop() { | |
// if page !== page 1 return; | |
$page_id = get_queried_object_id(); | |
echo ' Here is the content from '; | |
echo __FUNCTION__; | |
} | |
genesis(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment