| Server IP : 213.186.33.4 / Your IP : 216.73.216.222 Web Server : Apache System : Linux webm005.cluster103.gra.hosting.ovh.net 6.18.39-ovh-vps-grsec-zfs+ #1 SMP PREEMPT_DYNAMIC Tue Jul 21 12:03:15 CEST 2026 x86_64 User : karinebmkh ( 644538) PHP Version : 8.4.22 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/karinebmkh/www2/wp-content/themes/thevoux-wp/vc_templates/ |
Upload File : |
<?php function thb_threedimage( $atts, $content = null ) {
$atts = vc_map_get_attributes( 'thb_threedimage', $atts );
extract( $atts );
$img_id = preg_replace('/[^\d]/', '', $image);
$full = $full_width == 'true' ? 'full' : '';
$img = wpb_getImageBySize( array( 'attach_id' => $img_id, 'thumb_size' => 'full', 'class' => $alignment ) );
$img_src = wp_get_attachment_image_src($img_id, 'full');
if ( $img == NULL ) $img['thumbnail'] = '<img src="http://placekitten.com/g/400/300" />';
$img_link = ( $img_link == '||' ) ? '' : $img_link;
$link = vc_build_link( $img_link );
$link_to = $link['url'];
$a_title = $link['title'];
$a_target = $link['target'] ? $link['target'] : '_self';
ob_start();
echo '<a href="'.esc_url($link_to).'"'. ' target="'.esc_attr( $a_target ).'" title="'.esc_attr($a_title).'" class="atvImg '.esc_attr($full) .'"><div class="atvImg-original">'.$img["thumbnail"].'</div>
<div class="atvImg-layer" data-img="'.esc_attr($img_src[0]).'"></div>
<div class="atvImg-layer"><div class="image_bg"><div class="image_link"></div></div></div>
<div class="atvImg-layer"><span class="title"><h3>'.$a_title.'</h3></span><span class="arrow"><svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
width="69.002px" height="41.752px" viewBox="0 0 69.002 41.752" enable-background="new 0 0 69.002 41.752" xml:space="preserve">
<polygon fill-rule="evenodd" clip-rule="evenodd" points="69.002,20.846 47.351,0 43.475,3.732 58.359,18.064 0,18.064 0,23.439
58.619,23.439 43.475,38.021 47.351,41.752 69.002,20.906 68.971,20.876"/>
</svg></span></div>
</a>';
$out = ob_get_clean();
return $out;
}
thb_add_short('thb_threedimage', 'thb_threedimage');