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 | |
function below_the_title() { | |
echo '<h3>Make sure your title is punchy and relevant to the content.</h3>'; | |
} | |
add_action( 'edit_form_after_title', 'below_the_title' ); | |
function below_the_editor() { | |
echo '<h4>Now remember to add in your tags, categories and featured image!</h4>'; |
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 | |
// SEND ACCESS LEVEL TO GRAVITY FORMS | |
function get_access_level(){ | |
global $user_ID; | |
$plan_id = rcp_get_subscription_id( $user_ID ); | |
$access_level = rcp_get_subscription_access_level( $plan_id ); | |
return $access_level; | |
} |
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 | |
// DISABLE CERTAIN FIELDS | |
function enqueue_gf_disable() { | |
wp_enqueue_script( 'gf-disable', plugins_url( '/scripts/gravity-forms-disable.js', dirname(__FILE__) ) ); | |
} | |
add_action( 'wp_enqueue_scripts', 'enqueue_gf_disable' ); |
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
jQuery(document).ready(function($){ | |
$(".gform_wrapper .disable input").attr('disabled','disabled'); | |
}); |
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 | |
// DISPLAY YOUR AGE // | |
function whats_my_age_again($birthday) { | |
extract( shortcode_atts( array( | |
'birthday' => 'birthday' | |
), $birthday)); | |
return date("Y", time() - strtotime($birthday)) - 1970; | |
} |
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
I am [show-my-age birthday="02/19/1985"] years old. |
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 // get post attachments | |
$post_attachments = get_posts( array ( | |
'post_type' => 'attachment', | |
'post_parent' => $post->ID | |
)); | |
?> | |
<ul> | |
<?php foreach ( $post_attachments as $post_attachment ) { | |
echo '<li>' . wp_get_attachment_link( $post_attachment->ID, '', false, false ) . '</li>'; | |
} ?> |
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 if( in_category( array( '52', '59', '60', '61', '62', '63' ) ) || is_category( array( 52, 59, 60, 61, 62, 63 ) ) || is_page( '9875' ) ) { // SYSTEMS MENU | |
wp_nav_menu( array('menu' => 'systems-menu', 'container' => false, 'items_wrap' => '<ul id="primary-main-menu" class=%2$s><li class="first-child-divider"></li>%3$s</ul>', 'fallback_cb' => false)); | |
} |
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
#side-tabs a.support { | |
background: url('http://www.yourdomain.com/wp-content/themes/yourtheme/images/support-tab.png'); | |
left: 0px; | |
top: 250px; | |
height: 108px; | |
width: 45px; | |
margin: 0; | |
padding: 0; | |
position: fixed; | |
z-index: 9999; |
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
<div id="side-tabs"> | |
<a class="support" href="http://www.yourdomain.com/support-request/"></a> | |
</div> |