Dein Warenkorb ist gegenwärtig leer.

Dein Warenkorb ist gegenwärtig leer.

Return To Shop

/*** GC Testimonial Overrides ***/ remove_action(‘widgets_init’, ‘gct_load_testimonial_widgets’ ); // Remove widget added by GC Testimonial add_action(‘widgets_init’, ‘overrride_gct_load_testimonial_widgets’); // Add our own widget function overrride_gct_load_testimonial_widgets() { register_widget(‘Override_GCT_Testimonial_Menu_Widget’); } add_action(‘wp_footer’, ‘override_gct_widget_code’); // Add our own script function override_gct_widget_code(){ echo ‘‘; } if(class_exists(‘GCT_Testimonial_Menu_Widget’)): class Override_GCT_Testimonial_Menu_Widget extends GCT_Testimonial_Menu_Widget { function widget($args, $instance) { if (is_active_widget( ”, ”, ‘gc-testimonial-widget’ )) { wp_enqueue_style(‘gctwidgetstyles’, plugins_url().’/gc-testimonials/assets/css/gctwidget.css’, false, ‘1.0’, ‘all’); //add_action(‘wp_footer’, ‘gct_widget_script’); // Remove offending scripts //add_action(‘wp_footer’, ‘gct_widget_code’); } $data = array_merge($args, $instance); echo $data[‘before_widget’]; if ( !empty( $data[‘title’] ) ) { echo $data[‘before_title’] . $data[‘title’] . $data[‘after_title’]; }; if ( !empty( $data[‘limit’] ) ) { $no = $data[‘limit’]; } else { $no = ‘2’; } if ($data[‘category’] != ‘all’) { $term = get_term_by(‘id’, $data[‘category’], ‘testimonial-category’); $term_taxonomy = $term->taxonomy; $term_slug = $term->slug; } else { $term_taxonomy = ”; $term_slug = ”; } $args = array( $term_taxonomy => $term_slug, ‘posts_per_page’ => $no, ‘orderby’ => ‘post_date’, ‘order’ => ‘DESC’, ‘post_type’ => ‘testimonial’, ‘post_status’ => ‘publish’ ); $temp = $wp_query; $wp_query= null; $wp_query = new WP_Query(); $posts_array = $wp_query->query($args); if ($data[‘type’] == ‘cycle’) { echo ‘
‘; } foreach($posts_array as $post) { // Add custom fields $selected_extended_posts = array(); $custom = get_post_custom($post->ID); foreach(array(‘client_name’, ‘client_photo’, ‘company_website’, ‘company_name’) as $field) { if(isset($custom[$field])){ $post->$field = $custom[$field][0]; } } $selected_extended_posts[] = $post; $testimonial = $post; echo ‘
‘; if(!empty($testimonial->post_title)): echo ‘
‘.$testimonial->post_title.’
‘; endif; if ($data[‘images’] == ‘yes’) { if(has_post_thumbnail($testimonial->ID)) { echo ‘
‘.get_the_post_thumbnail($testimonial->ID, array(75, 75)).’
‘; } } echo ‘
‘.wp_trim_words( $testimonial->post_content, $num_words = 50, $more = ‘…’ ).’
‘; echo ‘
‘; echo ‘
‘.$testimonial->client_name.’
‘; if(!empty($testimonial->company_name) && !empty($testimonial->company_website)): echo ‘‘; echo ‘‘; echo $testimonial->company_name; echo ‘‘; elseif(!empty($testimonial->company_website)): echo ‘‘; echo $testimonial->company_website; echo ‘‘; endif; echo ‘
‘; echo ‘
‘; } if ($data[‘type’] == ‘cycle’) { echo ‘
‘; } if ($data[‘more’] == ‘yes’) { $link = get_permalink($data[‘fullpage’]); echo ‘

Read More Testimonials »

‘; } echo $data[‘after_widget’]; } } endif;