mattlawck of StudioPress
8/3/2018 - 4:03 PM

Genesis box after posts.

Genesis box after posts.

<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
 
//* Hook Genesis box widget area after post content
add_action( 'genesis_entry_footer', 'sp_genesis_box', 9 );
	function sp_genesis_box() {
	if ( is_singular( 'post' ) )
		genesis_widget_area( 'after-post', array(
			'before' => '<div class="genesis-box widget-area">',
			'after' => '</div>',
	) );
}
<div class="genesis-box">
	<h4>YourDomain.com runs on the Genesis Framework</h4>
	<a href="AFFILIATE LINK GOES HERE"><img class="alignright" src="IMAGE URL GOES HERE" alt="Genesis Framework" title="Check out the Genesis Framework" /></a>
	<p>Genesis empowers you to quickly and easily build incredible websites with WordPress. Whether you're a novice or advanced developer, Genesis provides the secure and search-engine-optimized foundation that takes WordPress to places you never thought it could go. It's that simple - start using <a href="AFFILIATE LINK GOES HERE">Genesis</a> now!</p>
	<p>Take advantage of the 6 default layout options, comprehensive SEO settings, rock-solid security, flexible theme options, cool custom widgets, custom design hooks, and a huge selection of child themes ("skins") that make your site look the way you want it to.  With automatic theme updates and world-class support included, Genesis is the smart choice for your WordPress website or blog.</p>
</div>
/* Genesis Box
--------------------------------------------- */
 
.genesis-box {
	background: #f5f5f5;
	border: 1px solid #ddd;
	margin-top: 20px;
	padding: 20px;
}
     
.genesis-box h4 {
	font-size: 18px;
	font-weight: normal;
	margin-bottom: 10px
	padding: 0;
	text-transform: none;
}
     
.genesis-box .alignright {
	background: #fff;
	border: 1px solid #ddd;
	float: right;
	margin: 0 0 5px 10px;
	padding: 7px;
}
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
 
//* Register Genesis box widget area
genesis_register_sidebar( array(
	'id'            => 'after-post',
	'name'          => __( 'Genesis Box', 'themename' ),
	'description'   => __( 'This is a widget area that can be placed after the post', 'themename' ),
) );