'; $linkend = ''; endif; $routput = ''; $routput = $linkstart . $contentt . $linkend; if ( $nolnknotxt == '1' && $routput == $contentt ) $routput = ''; return $routput; else: return ''; endif; } // CSS Property Change from Options function associationx_cngstyle($option, $default, $items='', $property='', $unit='', $isimportant='', $extrainside='', $extraoutside='', $countzerovalasfalse='' ) { $result = ''; if ($option && $default): $itemvalue = associationx_get_option($option,$default); if($countzerovalasfalse =='1' || $countzerovalasfalse =='true'): if(empty($itemvalue) || $itemvalue == '0'): $itemvalue ='false'; $unit=''; endif; endif; if ( $isimportant == '1' || $isimportant == 'true'): $isimportant = '!important'; endif; if ($itemvalue != $default): if ( $items && $property ): if ( $property == 'background-image' ): $itemvalue = 'url("'.$itemvalue.'")'; endif; $result= $items.'{'.$property.':'.$itemvalue.''.$unit.''.$isimportant.';'.$extrainside.'}'.$extraoutside.''; else: $result=$extraoutside; endif; endif; endif; return $result; } // Background Change function associationx_backchange($option, $itemforback, $image ='', $color = '', $repeat = 'repeat', $position='top left', $attachment = 'scroll' ){ $optionval = associationx_get_option($option); if ( $optionval && $itemforback ): $nimage = $optionval['image']; $ncolor = $optionval['color']; $nrepeat = $optionval['repeat']; $nposition = $optionval['position']; $nattachment = $optionval['attachment']; if ( $nimage == $image && $ncolor == $color && $nrepeat == $repeat && $nposition == $position && $nattachment == $attachment ) : return ''; else: $nfoutput = ''; if($ncolor && $ncolor != $color) $nfoutput .= 'background-color:'. $ncolor . ';'; if($nimage): if($nimage && $nimage != $image): $nfoutput .= 'background-image: url("'.$nimage.'");'; endif; if($nrepeat && $nrepeat != $repeat ): $nfoutput .= 'background-repeat:'. $nrepeat . ';'; endif; if($nposition && $nposition != $position): $nfoutput .= 'background-position:'. $nposition . ';'; endif; if($nattachment && $nattachment != $attachment): $nfoutput .= 'background-attachment:'. $nattachment . ';'; endif; else: $nfoutput .= 'background-image:none;'; endif; if($nfoutput): return $itemforback .'{'.$nfoutput.'}'; else: return ''; endif; endif; else: return ''; endif; } // WooCommerce Check function associationx_woo_check() { if ( in_array( 'woocommerce/woocommerce.php', apply_filters( 'active_plugins', get_option( 'active_plugins' ) ) )): return true; else: return false; endif; } // WooCommerce Cart Icon Add if ( associationx_get_option('woo-cart-icon', '1') && associationx_woo_check() ) { function associationx_wc_cart_count($d5wmenu, $wargs) { if( $wargs->theme_location == 'main-menu'): $wcsccount = WC()->cart->get_cart_contents_count(); $wclink = function_exists( 'wc_get_cart_url' ) ? wc_get_cart_url() : WC()->cart->get_cart_url(); $newmenup = '
  • ' . $wcsccount . '
  • '; $newmenun = $d5wmenu . $newmenup; return $newmenun; else: return $d5wmenu; endif; } add_filter('wp_nav_menu_items','associationx_wc_cart_count', 10, 2); } // WooCommerce Page Check function associationx_woo_page_check() { if ( associationx_woo_check() && ( is_cart() || is_checkout() || is_account_page() ) ): return true; else: return false; endif; } // Social Links function associationx_social_links( $sval = '1' ) { If ( $sval == '1' ): $sltarget = 1; $slink = ''; $numslinks = 4; if($numslinks && is_numeric($numslinks)): foreach (range(1, $numslinks ) as $numslinksn) { $sl = ''; $sl = esc_url(associationx_get_option('sl' . $numslinksn, '#')); $slink .= associationx_linkandtarget('', $sl, $sltarget, '', 'sociallinkitem slicondefined', '1' ); } endif; if($slink) echo ''; endif; } // Post Meta design function associationx_post_meta() { ?>
    ','' ); ?>
    '; echo paginate_links(array( 'mid_size' => 3, 'type' => 'list', 'prev_text' => '', 'next_text' => '', ) ); echo ''; } // Not Found Page function associationx_not_found() { ?>

    «


    '. get_avatar( get_the_author_meta('user_email') , 110 ). '

    '.$authorname.' ' . esc_html(get_the_author()) .'

    ' . wp_kses_post(get_the_author_meta('description')). '
    '; if ( is_single() && $singpost == 1 ): echo $authorbio; endif; if ( is_page() && $singpage == 1 ): echo $authorbio; endif; endif; } // Breadcrumbs function associationx_breadcrumbs() { associationx_breadcrumb_trail(); } add_action('associationx_starting_content', 'associationx_breadcrumbs'); // Menu Description function associationx_description_to_menu($item_output, $item, $depth, $args) { if (strlen($item->description) > 0 ) { $item_output .= sprintf('', esc_html($item->description)); } return $item_output; } add_filter('walker_nav_menu_start_el', 'associationx_description_to_menu', 10, 4); // Add a Close Menu Item with the Main Mneu function associationx_main_menu_close($d5xmenu, $wargs) { if( $wargs->theme_location == 'main-menu'): $newmenup = ''; $newmenun = $d5xmenu . $newmenup; return $newmenun; else: return $d5xmenu; endif; } add_filter('wp_nav_menu_items','associationx_main_menu_close', 10, 2);