PATH:
home
/
letacommog
/
aperobusiness
/
wp-content
/
themes
/
deep
/
inc
/
webnus-core
/
shortcodes
<?php function deep_ourclients($attributes, $content){ extract(shortcode_atts(array( 'type' => '1', 'client_images' => '', 'image_filter' => '', 'thumbnail' => '', 'show_text' => '', 'pre_txt' => 'Pre', 'next_txt' => 'Next', 'shortcodeclass' => '', 'shortcodeid' => '', ), $attributes) ); wp_enqueue_style( 'wn-deep-our-clients', DEEP_ASSETS_URL . 'css/frontend/our-clients/our-clients.css' ); $images_filter = ''; if ( $image_filter == 'enable' ) { $images_filter = 'class="wn-gray-filter"'; } $show_text = ( ! empty($show_text) ) ? "ourclient6-nav-show" : ''; // Class & ID $shortcodeclass = $shortcodeclass ? $shortcodeclass : ''; $shortcodeid = $shortcodeid ? ' id="' . $shortcodeid . '"' : ''; $client_images_url = ''; $client_images_url2 = ''; if( !empty( $client_images ) ) { $images_id_array = array(); $images_id_array = explode( ',',$client_images ); foreach( $images_id_array as $id ) { $link = get_post($id)->post_content; $alt_text = get_post_meta($id, '_wp_attachment_image_alt', true); $img = wp_get_attachment_url( $id ); if( empty( $link ) ) { $client_images_url .= ' <div class="our-client-item"> <img alt="'.$alt_text.'" src="' .$img . '" '.$images_filter.'> </div>'; $client_images_url2 .= ' <div class="our-clients-item-t'.$type.'"> <img alt="'.$alt_text.'" src="' .$img . '" '.$images_filter.'> </div>'; } else { $client_images_url .= ' <div class="our-client-item"> <a target="_blank" href="' . esc_url( $link ) . '"> <img alt="' . $alt_text . '" src="' . $img . '" ' . $images_filter . '> </a> </div>'; $client_images_url2 .= ' <div class="our-clients-item-t' . $type . '"> <a href="' . esc_url( $link ) . '"> <img alt="'.$alt_text.'" src="' .$img . '" ' . $images_filter . '> </a> </div>'; } } } $out = ''; if ( $type == 1 || $type == 2 ) { $out .= '<div class="aligncenter ' . $shortcodeclass . '" ' . $shortcodeid . '>'; $out .= '<hr class="vertical-space1"><div class="col-md-12 our-clients-wrap">'; $out .= '<div id="our-clients" class="our-clients '; if ( $type == 2 ) { $out .= 'owl-carousel owl-theme our-clients-wrap-carousel'; } $out .= '">'; $out .= $client_images_url; $out .='</div>'; $out .= '</div><hr class="vertical-space2"></div>'; } elseif( $type == 4 ) { $out .= '<div class="our-clients-type4 our-clients-wrap ' . $shortcodeclass . '" ' . $shortcodeid . '>'; $out .= '<div class="center">'; $out .= $client_images_url; $out .= '</div>'; $out .= '</div>'; } elseif( $type == 5 ) { $out = '<div class="our-clients-wrap our-clients-type5 owl-carousel owl-theme ' . $shortcodeclass . '" ' . $shortcodeid . '>'; $out .= $client_images_url2; $out .= '</div>'; } elseif( $type == 6 ) { $out .= '<div class="our-clients-wrap our-clients-type6 owl-carousel owl-theme '. $show_text .' ' . $shortcodeclass . '" ' . $shortcodeid . ' data-next="' . $next_txt . '" data-pre="' . $pre_txt . '">'; $out .= $client_images_url2; $out .= '</div>'; } return $out; } add_shortcode("ourclients", "deep_ourclients"); function deep_client($attributes, $content){ extract(shortcode_atts(array( "img" => '', "img_alt" => '', ), $attributes)); return !empty($img)?'<li><img src="'.$img.'" alt="'.$img_alt.'"></li>':''; } add_shortcode("client", "deep_client");
[+]
..
[-] video-teaser.php
[edit]
[-] vcw.php
[edit]
[-] sermon-category.php
[edit]
[-] iconbox.php
[edit]
[-] speakers.php
[edit]
[-] iconfonts-param.php
[edit]
[-] checklist-param.php
[edit]
[-] infobox.php
[edit]
[-] webtags.php
[edit]
[-] teaser-box.php
[edit]
[-] latest-from-blog.php
[edit]
[-] reservation.php
[edit]
[-] subscribe.php
[edit]
[-] progressbar.php
[edit]
[-] review-items.php
[edit]
[-] icon-divider.php
[edit]
[-] toggle-box.php
[edit]
[+]
assets
[-] pie.php
[edit]
[-] asermon.php
[edit]
[-] buttons.php
[edit]
[-] accordion.php
[edit]
[-] testimonial-carousel.php
[edit]
[-] deep-gallery.php
[edit]
[-] custom-menu.php
[edit]
[-] postslider.php
[edit]
[-] magazine.php
[edit]
[-] callout.php
[edit]
[-] maxcounter.php
[edit]
[-] testimonialslider.php
[edit]
[-] testimonials.php
[edit]
[-] wp-hotel-booking.php
[edit]
[-] services.php
[edit]
[-] image-carousel.php
[edit]
[-] category-tab.php
[edit]
[-] slide-up-note.php
[edit]
[-] ourteam.php
[edit]
[-] prayerwall-items.php
[edit]
[-] heading.php
[edit]
[-] tablepress.php
[edit]
[-] instagram.php
[edit]
[-] video-play.php
[edit]
[-] columns.php
[edit]
[-] special-offer.php
[edit]
[-] like-view-share.php
[edit]
[-] image-hotspot.php
[edit]
[-] postfromblog.php
[edit]
[-] roadmap.php
[edit]
[-] search.php
[edit]
[-] recipes.php
[edit]
[-] ourclients.php
[edit]
[-] tab.php
[edit]
[-] blog.php
[edit]
[-] icon.php
[edit]
[-] latest-tweets.php
[edit]
[-] before-after-image.php
[edit]
[-] food-menu.php
[edit]
[-] alerts.php
[edit]
[-] login.php
[edit]
[-] pricing-plan.php
[edit]
[-] dropcap.php
[edit]
[-] rooms.php
[edit]
[-] prayerwall-form.php
[edit]
[-] countdown.php
[edit]
[-] lefttab.php
[edit]
[-] schedule.php
[edit]
[-] block-quote.php
[edit]
[-] highlight.php
[edit]
[-] our-process.php
[edit]
[-] w-title.php
[edit]
[-] shop-products.php
[edit]
[-] buy-process.php
[edit]
[-] portfolio-carousel.php
[edit]
[-] causes.php
[edit]
[-] review-form.php
[edit]
[-] pricingtables.php
[edit]
[-] sermons.php
[edit]
[-] distance.php
[edit]
[-] collection.php
[edit]
[-] donate.php
[edit]
[-] googlemap.php
[edit]
[-] list.php
[edit]
[-] acause.php
[edit]
[-] service-carousel.php
[edit]
[-] quote.php
[edit]
[-] w-svg.php
[edit]
[-] tooltip.php
[edit]
[-] socials.php
[edit]
[-] process-carousel.php
[edit]