| 1 |  |  | <?php | 
            
                                                                                                            
                            
            
                                    
            
            
                | 2 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 3 |  |  |  * Template Tags | 
            
                                                                                                            
                            
            
                                    
            
            
                | 4 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 5 |  |  |  * @package   to-team | 
            
                                                                                                            
                            
            
                                    
            
            
                | 6 |  |  |  * @author    LightSpeed | 
            
                                                                                                            
                            
            
                                    
            
            
                | 7 |  |  |  * @license   {license} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 8 |  |  |  * @link | 
            
                                                                                                            
                            
            
                                    
            
            
                | 9 |  |  |  * @copyright 2016 LightSpeedDevelopment | 
            
                                                                                                            
                            
            
                                    
            
            
                | 10 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 11 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 12 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 13 |  |  |  * Find the content part in the plugin | 
            
                                                                                                            
                            
            
                                    
            
            
                | 14 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 15 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 16 |  |  |  * @subpackage	template-tag | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 17 |  |  |  * @category 	content | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 18 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 19 |  |  | function lsx_to_team_content( $slug, $name = null ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 20 |  |  | 	do_action( 'lsx_to_team_content',$slug, $name ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 21 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 22 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 23 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 24 |  |  |  * Outputs the current team members role, must be used in a loop. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 25 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 26 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 27 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 28 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 29 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 30 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 31 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 32 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 33 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 34 |  |  | function lsx_to_team_role( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 35 |  |  | 	lsx_to_custom_field_query( 'role',$before,$after,$echo ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 36 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 37 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 38 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 39 |  |  |  * Outputs the current team members role, must be used in a loop. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 40 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 41 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 42 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 43 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 44 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 45 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 46 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 47 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 48 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 49 |  |  | function lsx_to_team_contact_number( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 50 |  |  | 	$contact_number = get_post_meta( get_the_ID(), 'contact_number', true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 51 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 52 |  |  | 	if ( false !== $contact_number && '' !== $contact_number ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 53 |  |  | 		$contact_html = $before . '<a href="tel:+' . $contact_number . '">' . $contact_number . '</a>' . $after; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 54 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 55 |  |  | 		if ( $echo ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 56 |  |  | 			echo wp_kses_post( $contact_html ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 57 |  |  | 		} else { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 58 |  |  | 			return $contact_html; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 59 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 60 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 61 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 62 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 63 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 64 |  |  |  * Outputs the current team members role, must be used in a loop. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 65 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 66 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 67 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 68 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 69 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 70 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 71 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 72 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 73 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 74 |  |  | function lsx_to_team_contact_email( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 75 |  |  | 	$contact_email = get_post_meta( get_the_ID(), 'contact_email', true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 76 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 77 |  |  | 	if ( false !== $contact_email && '' !== $contact_email ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 78 |  |  | 		$contact_html = $before . '<a href="mailto:' . $contact_email . '">' . $contact_email . '</a>' . $after; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 79 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 80 |  |  | 		if ( $echo ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 81 |  |  | 			echo wp_kses_post( $contact_html ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 82 |  |  | 		} else { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 83 |  |  | 			return $contact_html; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 84 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 85 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 86 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 87 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 88 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 89 |  |  |  * Outputs the current team members Skype, must be used in a loop. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 90 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 91 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 92 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 93 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 94 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 95 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 96 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 97 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 98 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 99 |  |  | function lsx_to_team_contact_skype( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 100 |  |  | 	$contact_skype = get_post_meta( get_the_ID(), 'skype', true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 101 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 102 |  |  | 	if ( false !== $contact_skype && '' !== $contact_skype ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 103 |  |  | 		$contact_html = $before . '<span>' . $contact_skype . '</span>' . $after; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 104 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 105 |  |  | 		if ( $echo ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 106 |  |  | 			echo wp_kses_post( $contact_html ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 107 |  |  | 		} else { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 108 |  |  | 			return $contact_html; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 109 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 110 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 111 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 112 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 113 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 114 |  |  |  * Outputs the current team members social profiles, must be used in a loop. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 115 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 116 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 117 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 118 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 119 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 120 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 121 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 122 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 123 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 124 |  |  | function lsx_to_team_social_profiles( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 125 |  |  | 	$social_profiles = array( 'facebook', 'twitter', 'googleplus', 'linkedin', 'pinterest' ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 126 |  |  | 	$social_profile_html = false; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 127 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 128 |  |  | 	foreach ( $social_profiles as $meta_key ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 129 |  |  | 		$meta_value = get_post_meta( get_the_ID(),$meta_key,true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 130 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 131 |  |  | 		if ( false !== $meta_value && '' !== $meta_value ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 132 |  |  | 			$icon_class = ''; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 133 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 134 |  |  | 			switch ( $meta_key ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 135 |  |  | 				case 'facebook': | 
            
                                                                                                            
                            
            
                                    
            
            
                | 136 |  |  | 					$icon_class = 'facebook'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 137 |  |  | 				break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 138 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 139 |  |  | 				case 'twitter': | 
            
                                                                                                            
                            
            
                                    
            
            
                | 140 |  |  | 					$icon_class = 'twitter'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 141 |  |  | 				break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 142 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 143 |  |  | 				case 'googleplus': | 
            
                                                                                                            
                            
            
                                    
            
            
                | 144 |  |  | 					$icon_class = 'google-plus'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 145 |  |  | 				break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 146 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 147 |  |  | 				case 'linkedin': | 
            
                                                                                                            
                            
            
                                    
            
            
                | 148 |  |  | 					$icon_class = 'linkedin'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 149 |  |  | 				break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 150 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 151 |  |  | 				case 'pinterest': | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 152 |  |  | 					$icon_class = 'pinterest-p'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 153 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 154 |  |  | 				default: | 
            
                                                                                                            
                            
            
                                    
            
            
                | 155 |  |  | 				break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 156 |  |  | 			} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 157 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 158 |  |  | 			$social_profile_html .= '<a target="_blank" rel="noopener noreferrer" href="' . $meta_value . '"><i class="fa fa-' . $icon_class . '" aria-hidden="true"></i></a>'; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 159 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 160 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 161 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 162 |  |  | 	if ( false !== $social_profile_html && '' !== $social_profile_html ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 163 |  |  | 		$social_profile_html = $before . $social_profile_html . $after; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 164 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 165 |  |  | 		if ( $echo ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 166 |  |  | 			echo wp_kses_post( $social_profile_html ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 167 |  |  | 		} else { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 168 |  |  | 			return $social_profile_html; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 169 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 170 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 171 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 172 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 173 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 174 |  |  |  * Gets the current teams tagline | 
            
                                                                                                            
                            
            
                                    
            
            
                | 175 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 176 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 177 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 178 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 179 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 180 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 181 |  |  |  * @package 	to-team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 182 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 183 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 184 |  |  | function lsx_to_team_tagline( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 185 |  |  | 	lsx_to_tagline( $before,$after,$echo ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 186 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 187 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 188 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 189 |  |  |  * Gets the current connected team member panel | 
            
                                                                                                            
                            
            
                                    
            
            
                | 190 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 191 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 192 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 193 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 194 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 195 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 196 |  |  | function lsx_to_has_team_member() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 197 |  |  | 	$tour_operator = tour_operator(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 198 |  |  | 	$tab = 'team'; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 199 |  |  | 	$start_with = 'expert-'; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 200 |  |  | 	$has_team = false; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 201 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 202 |  |  | 	// Check if the team member panel has been disabled. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 203 |  |  | 	if ( ! is_singular( 'team' ) && ! is_singular( 'review' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 204 |  |  | 		if ( is_object( $tour_operator ) && isset( $tour_operator->options[ $tab ] ) && is_array( $tour_operator->options[ $tab ] ) && isset( $tour_operator->options[ $tab ]['disable_team_panel'] ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 205 |  |  | 			return false; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 206 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 207 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 208 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 209 |  |  | 	if ( is_singular( 'team' ) || is_singular( 'review' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 210 |  |  | 		$has_team = has_post_thumbnail(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 211 |  |  | 	} elseif ( is_tax() ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 212 |  |  | 		$has_team = lsx_to_has_custom_field_query( 'expert', get_queried_object()->term_id, true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 213 |  |  | 	} else { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 214 |  |  | 		$has_team = lsx_to_has_custom_field_query( 'team_to_' . get_post_type(), get_the_ID() ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 215 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 216 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 217 |  |  | 	if ( false === $has_team ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 218 |  |  | 		if ( is_object( $tour_operator ) && isset( $tour_operator->options[ $tab ] ) && is_array( $tour_operator->options[ $tab ] ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 219 |  |  | 			foreach ( $tour_operator->options[ $tab ] as $key => $value ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 220 |  |  | 				if ( substr( $key, 0, strlen( $start_with ) ) === $start_with ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 221 |  |  | 					$has_team = true; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 222 |  |  | 					break; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 223 |  |  | 				} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 224 |  |  | 			} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 225 |  |  | 		} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 226 |  |  | 	} | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 227 |  |  | 	return $has_team; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 228 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 229 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 230 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 231 |  |  |  * Gets the current connected team member panel | 
            
                                                                                                            
                            
            
                                    
            
            
                | 232 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 233 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 234 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 235 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 236 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 237 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 238 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 239 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 240 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                                                                
            
                                    
            
            
                | 241 |  |  |  */ | 
            
                                                                        
                            
            
                                    
            
            
                | 242 |  |  | function lsx_to_team_member_panel( $before = '', $after = '' ) { | 
            
                                                                        
                            
            
                                    
            
            
                | 243 |  |  | 	$team_id = false; | 
            
                                                                        
                            
            
                                    
            
            
                | 244 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 245 |  |  | 	if ( is_tax() ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 246 |  |  | 		$meta_key = 'expert'; | 
            
                                                                        
                            
            
                                    
            
            
                | 247 |  |  | 		$team_id = get_transient( get_queried_object()->term_id . '_' . $meta_key ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 248 |  |  | 	} else { | 
            
                                                                        
                            
            
                                    
            
            
                | 249 |  |  | 		$meta_key = 'team_to_' . get_post_type(); | 
            
                                                                        
                            
            
                                    
            
            
                | 250 |  |  | 		$team_id = get_transient( get_the_ID() . '_' . $meta_key ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 251 |  |  | 	} | 
            
                                                                        
                            
            
                                    
            
            
                | 252 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 253 |  |  | 	if ( false === $team_id ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 254 |  |  | 		$tour_operator = tour_operator(); | 
            
                                                                        
                            
            
                                    
            
            
                | 255 |  |  | 		$tab = 'team'; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 256 |  |  | 		$start_with = 'expert-'; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 257 |  |  | 		$team_ids = array(); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 258 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 259 |  |  | 		if ( is_object( $tour_operator ) && isset( $tour_operator->options[ $tab ] ) && is_array( $tour_operator->options[ $tab ] ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 260 |  |  | 			foreach ( $tour_operator->options[ $tab ] as $key => $value ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 261 |  |  | 				if ( substr( $key, 0, strlen( $start_with ) ) === $start_with ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 262 |  |  | 					$team_ids[] = $value; | 
            
                                                                        
                            
            
                                    
            
            
                | 263 |  |  | 				} | 
            
                                                                        
                            
            
                                    
            
            
                | 264 |  |  | 			} | 
            
                                                                        
                            
            
                                    
            
            
                | 265 |  |  | 		} | 
            
                                                                        
                            
            
                                    
            
            
                | 266 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 267 |  |  | 		if ( count( $team_ids ) > 0 ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 268 |  |  | 			$team_id = $team_ids[ array_rand( $team_ids ) ]; | 
            
                                                                        
                            
            
                                    
            
            
                | 269 |  |  | 		} | 
            
                                                                        
                            
            
                                    
            
            
                | 270 |  |  | 	} | 
            
                                                                        
                            
            
                                    
            
            
                | 271 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 272 |  |  | 	if ( false !== $team_id ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 273 |  |  | 		$team_args = array( | 
            
                                                                        
                            
            
                                    
            
            
                | 274 |  |  | 			'post_type'	=> 'team', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 275 |  |  | 			'post_status' => 'publish', | 
            
                                                                        
                            
            
                                    
            
            
                | 276 |  |  | 			'p' => $team_id, | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 277 |  |  | 		); | 
            
                                                                        
                            
            
                                    
            
            
                | 278 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 279 |  |  | 		$team = new WP_Query( $team_args ); | 
            
                                                                        
                            
            
                                    
            
            
                | 280 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 281 |  |  | 		if ( $team->have_posts() ) : | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 282 |  |  | 			echo wp_kses_post( $before ); | 
            
                                                                        
                            
            
                                    
            
            
                | 283 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 284 |  |  | 			while ( $team->have_posts() ) : | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 285 |  |  | 				global $post; | 
            
                                                                        
                            
            
                                    
            
            
                | 286 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 287 |  |  | 				$team->the_post(); | 
            
                                                                        
                            
            
                                    
            
            
                | 288 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 289 |  |  | 				$has_single = ! lsx_to_is_single_disabled(); | 
            
                                                                        
                            
            
                                    
            
            
                | 290 |  |  | 				$permalink = ''; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 291 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 292 |  |  | 				if ( $has_single ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 293 |  |  | 					$permalink = get_the_permalink(); | 
            
                                                                        
                            
            
                                    
            
            
                | 294 |  |  | 				} elseif ( ! is_post_type_archive( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 295 |  |  | 					$has_single = true; | 
            
                                                                        
                            
            
                                    
            
            
                | 296 |  |  | 					$permalink = get_post_type_archive_link( 'team' ) . '#team-' . $post->post_name; | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 297 |  |  | 				} | 
            
                                                                        
                            
            
                                    
            
            
                | 298 |  |  | 				?> | 
            
                                                                        
                            
            
                                    
            
            
                | 299 |  |  | 				<article <?php post_class(); ?>> | 
            
                                                                        
                            
            
                                    
            
            
                | 300 |  |  | 					<div class="lsx-to-contact-thumb"> | 
            
                                                                        
                            
            
                                    
            
            
                | 301 |  |  | 						<?php if ( $has_single ) { ?><a href="<?php echo esc_url( $permalink ); ?>"><?php } ?> | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 302 |  |  | 							<?php lsx_thumbnail( 'lsx-thumbnail-square' ); ?> | 
            
                                                                        
                            
            
                                    
            
            
                | 303 |  |  | 						<?php if ( $has_single ) { ?></a><?php } ?> | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 304 |  |  | 					</div> | 
            
                                                                        
                            
            
                                    
            
            
                | 305 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 306 |  |  | 					<div class="lsx-to-contact-info"> | 
            
                                                                        
                            
            
                                    
            
            
                | 307 |  |  | 						<small class="lsx-to-contact-prefix text-center">Your travel expert:</small> | 
            
                                                                        
                            
            
                                    
            
            
                | 308 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 309 |  |  | 						<h4 class="lsx-to-contact-name text-center"> | 
            
                                                                        
                            
            
                                    
            
            
                | 310 |  |  | 							<?php if ( $has_single ) { ?><a href="<?php echo esc_url( $permalink ); ?>"><?php } ?> | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 311 |  |  | 								<?php the_title(); ?> | 
            
                                                                        
                            
            
                                    
            
            
                | 312 |  |  | 							<?php if ( $has_single ) { ?></a><?php } ?> | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                        
                            
            
                                    
            
            
                | 313 |  |  | 						</h4> | 
            
                                                                        
                            
            
                                    
            
            
                | 314 |  |  | 					</div> | 
            
                                                                        
                            
            
                                    
            
            
                | 315 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 316 |  |  | 					<div class="lsx-to-contact-meta-data text-center hidden"> | 
            
                                                                        
                            
            
                                    
            
            
                | 317 |  |  | 						<?php | 
            
                                                                        
                            
            
                                    
            
            
                | 318 |  |  | 							lsx_to_team_contact_number( '<span class="lsx-to-meta-data contact-number"><i class="fa fa-phone orange"></i> ', '</span>' ); | 
            
                                                                        
                            
            
                                    
            
            
                | 319 |  |  | 							lsx_to_team_contact_email( '<span class="lsx-to-meta-data email"><i class="fa fa-envelope orange"></i> ', '</span>' ); | 
            
                                                                        
                            
            
                                    
            
            
                | 320 |  |  | 							lsx_to_team_contact_skype( '<span class="lsx-to-meta-data skype"><i class="fa fa-skype orange"></i> ', '</span>' ); | 
            
                                                                        
                            
            
                                    
            
            
                | 321 |  |  | 							lsx_to_team_social_profiles( '<div class="lsx-to-meta-data lsx-to-contact-socials">', '</div>' ); | 
            
                                                                        
                            
            
                                    
            
            
                | 322 |  |  | 						?> | 
            
                                                                        
                            
            
                                    
            
            
                | 323 |  |  | 					</div> | 
            
                                                                        
                            
            
                                    
            
            
                | 324 |  |  | 				</article> | 
            
                                                                        
                            
            
                                    
            
            
                | 325 |  |  | 				<?php | 
            
                                                                        
                            
            
                                    
            
            
                | 326 |  |  | 			endwhile; | 
            
                                                                        
                            
            
                                    
            
            
                | 327 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 328 |  |  | 			echo wp_kses_post( $after ); | 
            
                                                                        
                            
            
                                    
            
            
                | 329 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 330 |  |  | 			wp_reset_postdata(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 331 |  |  | 		endif; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 332 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 333 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 334 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 335 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 336 |  |  |  * Outputs the connected accommodation for a team member | 
            
                                                                                                            
                            
            
                                    
            
            
                | 337 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 338 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 339 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 340 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 341 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 342 |  |  | function lsx_to_team_accommodation() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 343 |  |  | 	global $lsx_to_archive; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 344 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 345 |  |  | 	if ( post_type_exists( 'accommodation' ) && is_singular( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 346 |  |  | 		$args = array( | 
            
                                                                                                            
                            
            
                                    
            
            
                | 347 |  |  | 			'from'		=> 'accommodation', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 348 |  |  | 			'to'		=> 'team', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 349 |  |  | 			'column'	=> '3', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 350 |  |  | 			// @codingStandardsIgnoreLine | 
            
                                                                                                            
                            
            
                                    
            
            
                | 351 |  |  | 			'before'	=> '<section id="accommodation" class="lsx-to-section lsx-to-collapse-section"><h2 class="lsx-to-section-title lsx-to-collapse-title lsx-title" data-toggle="collapse" data-target="#collapse-accommodation">' . __( lsx_to_get_post_type_section_title( 'accommodation', '', 'Featured Accommodations' ), 'to-team' ) . '</h2><div id="collapse-accommodation" class="collapse in"><div class="collapse-inner">', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 352 |  |  | 			'after'		=> '</div></div></section>', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 353 |  |  | 		); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 354 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 355 |  |  | 		lsx_to_connected_panel_query( $args ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 356 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 357 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 358 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 359 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 360 |  |  |  * Outputs the connected destination for a team member | 
            
                                                                                                            
                            
            
                                    
            
            
                | 361 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 362 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 363 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 364 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 365 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 366 |  |  | function lsx_to_team_destination() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 367 |  |  | 	global $lsx_to_archive; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 368 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 369 |  |  | 	if ( post_type_exists( 'destination' ) && is_singular( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 370 |  |  | 		$args = array( | 
            
                                                                                                            
                            
            
                                    
            
            
                | 371 |  |  | 			'from'   => 'destination', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 372 |  |  | 			'to'     => 'team', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 373 |  |  | 			'column' => '3', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 374 |  |  | 			// @codingStandardsIgnoreLine | 
            
                                                                                                            
                            
            
                                    
            
            
                | 375 |  |  | 			'before' => '<section id="destination" class="lsx-to-section lsx-to-collapse-section"><h2 class="lsx-to-section-title lsx-to-collapse-title lsx-title" data-toggle="collapse" data-target="#collapse-destination">' . __( lsx_to_get_post_type_section_title( 'destination', '', 'Featured Destinations' ), 'to-team' ) . '</h2><div id="collapse-destination" class="collapse in"><div class="collapse-inner">', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 376 |  |  | 			'after'  => '</div></div></section>', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 377 |  |  | 		); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 378 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 379 |  |  | 		lsx_to_connected_panel_query( $args ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 380 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 381 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 382 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 383 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 384 |  |  |  * Outputs the connected tour for a team member | 
            
                                                                                                            
                            
            
                                    
            
            
                | 385 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 386 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 387 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 388 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 389 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 390 |  |  | function lsx_to_team_tours() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 391 |  |  | 	global $lsx_to_archive; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 392 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 393 |  |  | 	if ( post_type_exists( 'tour' ) && is_singular( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 394 |  |  | 		$args = array( | 
            
                                                                                                            
                            
            
                                    
            
            
                | 395 |  |  | 			'from'		=> 'tour', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 396 |  |  | 			'to'		=> 'team', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 397 |  |  | 			'column'	=> '3', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 398 |  |  | 			// @codingStandardsIgnoreLine | 
            
                                                                                                            
                            
            
                                    
            
            
                | 399 |  |  | 			'before'	=> '<section id="tours" class="lsx-to-section lsx-to-collapse-section"><h2 class="lsx-to-section-title lsx-to-collapse-title lsx-title" data-toggle="collapse" data-target="#collapse-tours">' . __( lsx_to_get_post_type_section_title( 'tour', '', 'Featured Tours' ), 'to-team' ) . '</h2><div id="collapse-tours" class="collapse in"><div class="collapse-inner">', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 400 |  |  | 			'after'		=> '</div></div></section>', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 401 |  |  | 		); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 402 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 403 |  |  | 		lsx_to_connected_panel_query( $args ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 404 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 405 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 406 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 407 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 408 |  |  |  * Outputs the connected accommodation for a team member | 
            
                                                                                                            
                            
            
                                    
            
            
                | 409 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 410 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 411 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 412 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 413 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 414 |  |  | function lsx_to_team_reviews() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 415 |  |  | 	global $lsx_to_archive; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 416 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 417 |  |  | 	if ( post_type_exists( 'review' ) && is_singular( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 418 |  |  | 		$args = array( | 
            
                                                                                                            
                            
            
                                    
            
            
                | 419 |  |  | 			'from'		=> 'review', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 420 |  |  | 			'to'		=> 'team', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 421 |  |  | 			'column'	=> '2', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 422 |  |  | 			// @codingStandardsIgnoreLine | 
            
                                                                                                            
                            
            
                                    
            
            
                | 423 |  |  | 			'before'	=> '<section id="reviews" class="lsx-to-section lsx-to-collapse-section"><h2 class="lsx-to-section-title lsx-to-collapse-title lsx-title" data-toggle="collapse" data-target="#collapse-reviews">' . __( lsx_to_get_post_type_section_title( 'review', '', 'Featured Reviews' ), 'to-team' ) . '</h2><div id="collapse-reviews" class="collapse in"><div class="collapse-inner">', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 424 |  |  | 			'after'		=> '</div></div></section>', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 425 |  |  | 		); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 426 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 427 |  |  | 		lsx_to_connected_panel_query( $args ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 428 |  |  | 	} | 
            
                                                                                                            
                            
            
                                    
            
            
                | 429 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 430 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 431 |  |  | /** | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 432 |  |  |  * Gets the current specials connected team member | 
            
                                                                                                            
                            
            
                                    
            
            
                | 433 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 434 |  |  |  * @param		$before	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 435 |  |  |  * @param		$after	| string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 436 |  |  |  * @param		$echo	| boolean | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 437 |  |  |  * @return		string | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 438 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 439 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 440 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 441 |  |  |  * @category 	connections | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 442 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 443 |  |  | function lsx_to_connected_team( $before = '', $after = '', $echo = true ) { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 444 |  |  | 	lsx_to_connected_items_query( 'team', get_post_type(), $before, $after, $echo ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 445 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 446 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 447 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 448 |  |  |  * Outputs the connected posts | 
            
                                                                                                            
                            
            
                                    
            
            
                | 449 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 450 |  |  |  * @package 	tour-operator | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 451 |  |  |  * @subpackage	template-tags | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 452 |  |  |  * @category 	team | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 453 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 454 |  |  | function lsx_to_team_posts() { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 455 |  |  | 	//$site_user = get_post_meta( get_the_ID(), 'site_user', true ); | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 456 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 457 |  |  | 	if ( post_type_exists( 'post' ) && is_singular( 'team' ) ) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 458 |  |  | 		$args = array( | 
            
                                                                                                            
                            
            
                                    
            
            
                | 459 |  |  | 			'from'		=> 'post', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 460 |  |  | 			'to'		=> 'team', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 461 |  |  | 			'column'	=> '3', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 462 |  |  | 			// @codingStandardsIgnoreLine | 
            
                                                                                                            
                            
            
                                    
            
            
                | 463 |  |  | 			'before'	=> '<section id="posts" class="lsx-to-section lsx-to-collapse-section"><h2 class="lsx-to-section-title lsx-to-collapse-title lsx-title" data-toggle="collapse" data-target="#collapse-posts">' . __( lsx_to_get_post_type_section_title( 'post', '', 'Featured Posts' ), 'to-team' ) . '</h2><div id="collapse-posts" class="collapse in"><div class="collapse-inner">', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 464 |  |  | 			'after'		=> '</div></div></section>', | 
                            
                    |  |  |  | 
                                                                                        
                                                                                            
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 465 |  |  | 		); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 466 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 467 |  |  | 		lsx_to_connected_panel_query( $args ); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 468 |  |  | 	} | 
            
                                                                                                            
                                                                
            
                                    
            
            
                | 469 |  |  | } | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                        
            
                                    
            
            
                | 470 |  |  |  |