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 | |
// Xprofile get fileds by group | |
if ( bp_has_profile( array( 'user_id' => $user_id ) ) ) { | |
while ( bp_profile_groups() ) : bp_the_profile_group(); | |
$group_name = bp_get_the_profile_group_name(); | |
if ( ( 'Social' == $group_name) && bp_profile_group_has_fields() ) { | |
echo '<div id="bb-profile-group-fields">'; | |
while ( bp_profile_fields() ) : bp_the_profile_field(); |
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 | |
/* | |
* Get content by page ID | |
*/ | |
function marvy_the_content_by_id( $id ) { | |
if ( isset( $id ) && 0 != $id ) { | |
global $post; | |
$post = get_post( $id ); | |
setup_postdata( $post ); |
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
select { | |
-webkit-appearance: none; | |
-moz-appearance: none; | |
appearance: none; | |
background: url('./images/angle-arrow-down.svg') 98% / 15% no-repeat; | |
background-size: 9px; | |
border: 0; | |
border-bottom: 1px solid #e1e1e1; | |
border-radius: 0; |
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 | |
// Define custom post type string | |
define( 'CUSTOM_POST_TYPE', 'affiliates' ); | |
/** | |
* Register the meta box | |
*/ | |
if ( !function_exists( 'page_templates_dropdown_metabox' ) ) { |
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 | |
/* Remove small Gravtars from bbPress Forums */ | |
function rtp_remove_bbp_gravatar_null() { | |
return null; | |
} | |
function rtp_remove_bbp_gravatar($author_link, $args) { | |
return preg_replace('/<a.*<img.*> /iU', '', $author_link); | |
} |
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
/* List convert to Select */ | |
$('ul').each(function() { | |
var list = $(this), | |
select = $(document.createElement('select')).insertBefore($(this)); | |
select.attr('id','list-id'); | |
$('li', this).each(function() { | |
var ahref = $(this).children('a'), | |
target = ahref.attr('target'), | |
option = $(document.createElement('option')) | |
.appendTo(select) |
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 | |
$count = 0; | |
$count_2 = 0; | |
$total_count = count( $post ); | |
if( $count == 0 ) { | |
echo '<div>'; | |
} |