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 | |
| add_filter( 'display_post_states', 'wpmudev_add_post_state', 10, 2 ); | |
| function wpmudev_add_post_state( $states, $post ) { | |
| if( $post->post_name == 'contact' ) { //Slug of the page, this should be unique | |
| $states[] = 'Contact Page'; | |
| } | |
| return $states; | |
| } |
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 | |
| add_action('wp_head', 'cust_css_wpmudev_head'); | |
| function cust_css_wpmudev_head() { | |
| echo '<style>@media only screen and (min-width: 1080px) { #wrapper-1507244077357-1047, #wrapper-1507244115701-1068, #wrapper-1507267210188-1550 { display:none; } }</style>'; | |
| } |
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 | |
| add_action('wp_head', 'cust_js_wpmudev_head'); | |
| function cust_js_wpmudev_head() { | |
| echo '<script>(function($) { | |
| if ($(window).width() > 1079) { | |
| $( document ).ready(function() { | |
| $("#wrapper-1507244077357-1047").hide(); | |
| }); | |
| $(window).load(function() { | |
| $("#wrapper-1507244115701-1068").hide(); |
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 | |
| add_action('template_redirect', 'bp_private_profile'); | |
| function bp_private_profile() { | |
| if ( ! current_user_can( 'manage_options' ) ) { | |
| if ( bp_is_user_profile() && ! bp_is_my_profile() ) { | |
| wp_redirect( home_url() ); | |
| exit; | |
| } | |
| } | |
| } |
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
| #prosites-signup-form-checkout form#prosites-user-register { | |
| margin-left: auto; | |
| margin-right: auto; | |
| max-width: 450px; | |
| } | |
| #prosites-user-register label { | |
| display: block; | |
| font-size: 15px; | |
| line-height: 22px; |
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 | |
| add_action('admin_head', 'hide_tgmpa_notif'); | |
| function hide_tgmpa_notif() { | |
| echo '<style>#setting-error-tgmpa{display:none;}</style>'; | |
| } |
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 | |
| function nahid_print_date_shortcode() { | |
| echo 'Current as of ' . date("m/Y"); | |
| } | |
| add_shortcode( 'nahid_print_date', 'nahid_print_date_shortcode' ); |
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 | |
| add_action('wp_head', 'gscChangePlaceholder'); | |
| function gscChangePlaceholder() { | |
| ?> | |
| <script type="text/javascript"> | |
| (function($) { | |
| $( document ).ready(function() { | |
| $("#gsc-i-id1").attr("placeholder", "New Placeholder Text"); | |
| } | |
| })(jQuery); |
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 | |
| function mp_cus_continue_shopping_shortcode() { | |
| return '<a href="' . mp_products_link( false, true ) . '" class="mp_button mp_button-continue-shopping mp_button-large">Continue Shopping?</a>'; | |
| } | |
| add_shortcode('mp_continue_shopping_btn', 'mp_cus_continue_shopping_shortcode'); | |
| function mp_cus_review_order_shortcode() { | |
| return '<a href="' . mp_cart_link( false, true ) . '" class="mp_button mp_button-continue-shopping mp_button-large">Review Order</a>'; | |
| } | |
| add_shortcode('mp_review_order_btn', 'mp_cus_review_order_shortcode'); |
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 | |
| $member = MS_MODEL_MEMBER::get_current_member(); | |
| foreach ( $member->subscriptions as $subscription ) { | |
| $membership = $subscription->get_membership(); | |
| $has_access = $membership->has_access_to_post( $post_id ); | |
| if ( $has_access ) { | |
| //Content that you want to show if member has access to the queried post | |
| } | |
| } |