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 | |
/** | |
* The template used for displaying page content in page.php | |
* | |
* @package doc | |
*/ | |
?> | |
<article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> | |
<header class="entry-header"> |
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 | |
// Assign the custom field to a variable | |
$her_final_word = get_post_meta($post->ID, 'her_final_word', true); | |
// Check if variable is not empty | |
if($her_final_word !='') { | |
// True: Print the variable | |
?><p><?php echo $her_final_word; ?></p><?php | |
} | |
else { | |
// Default text that will appear |
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
/** | |
* A dashboard widget that lists out pages in a heirarchy | |
* Add this to the end of your "Functions.php" file in your theme directory | |
* | |
* This function is hooked into the 'wp_dashboard_setup' action below. | |
*/ | |
function site_map_edit() { | |
wp_add_dashboard_widget( | |
'site_map_edit', // Widget slug. |
NewerOlder