Viewing 14 posts - 1 through 14 (of 14 total)
  • Author
    Posts
  • #1285745

    Hello,

    I would like to add the social share icon tripadvisor (just like yelp). I imported it and I can use it when adding an icon. But it won’t show up in the social share row to be activated in the ALB. (Neither I can activate it in the secondary menu header)

    How can I activate it?

    Thank you so much for your help I tried so many things but I did not succeed yet.

    Regards, Verena

    #1285783

    Hey Verena,

    Thanks for contacting us!

    Please see – https://kriesi.at/documentation/enfold/social-share-buttons/#how-to-add-custom-social-icons-to-enfold-options. If that does not help, please create temporary admin logins and post them here privately so we can look into it :)

    Best regards,
    Yigit

    #1285912

    Hello Yigit,

    thank you for the quick response. Unfortunately I don’t know how to do it so I would appreciate if you could help me here. Attached you find the credentials of my website.
    To be honest I found the documentations before but I don’t know where to insert the code and where to add the icons name and so on.

    Thank you for your effort
    Regards, Verena

    #1285935

    Hi Verena,

    I added following code to functions.php file of your child theme

    // Register tripadvisor icon as a theme icon
    function avia_add_custom_icon($icons) {
    $icons['tripadvisor_icon'] = array( 'font' =>'tripadvisor', 'icon' => 'uf262');
    return $icons;
    }
    add_filter('avf_default_icons','avia_add_custom_icon', 10, 1);
    
    // Add new icon as an option for social icons
    function avia_add_custom_social_icon($icons) {
    $icons['Tripadvisor'] = 'tripadvisor_icon';
    return $icons;
    }
    add_filter('avf_social_icons_options','avia_add_custom_social_icon', 10, 1);

    and chose Tripadvisor in Enfold theme options > Social Profiles.

    Please review your website :)

    Best regards,
    Yigit

    #1286073

    Many thanks Yigit!

    It works perfectly now in the secondary menu but it still doesnt show up in the social share grid…can you help me with that as well? We would like to use it for sharing us not only on yelp but on Tripadvisor too.

    Thanks again
    Verena

    #1286690

    Hi Verena,

    Could you please try adding following code to Functions.php file as well

    //Add items on the social share section
    add_filter('avia_social_share_link_arguments', 'avia_add_social_share_link_arguments', 10, 1);
    function avia_add_social_share_link_arguments($args) {
    	$new_array = array(
    		'tripadvisor_icon' => array(
    			"encode"=>true, "encode_urls"=>false, "pattern" => "https://www.tripadvisor.com://send?text=[title]-[permalink]"
    		)
    	);
    
    	return array_merge($new_array, $args);
    }

    Best regards,
    Yigit

    #1286706

    Hey Yigit,

    thank you very much for your help. It works perfectly! Just one last question: is there a possibility to change the name “tripadvisor_icon” without cancelling the icon? I tried it by just erasing the _icon part in the code but then the icon disappears ;-)
    It would be perfect if there was just the name Tripadvisor when hovering over the icon, just like it is with Facebook. Is this possible?

    Thanks again,
    Verena

    #1286736

    Hi Verena,

    Your code in functions.php file should be looking as following at the moment

    // Register tripadvisor icon as a theme icon
    function avia_add_custom_icon($icons) {
    $icons['tripadvisor_icon'] = array( 'font' =>'tripadvisor', 'icon' => 'uf262');
    return $icons;
    }
    add_filter('avf_default_icons','avia_add_custom_icon', 10, 1);
    
    // Add new icon as an option for social icons
    function avia_add_custom_social_icon($icons) {
    $icons['Tripadvisor'] = 'tripadvisor_icon';
    return $icons;
    }
    add_filter('avf_social_icons_options','avia_add_custom_social_icon', 10, 1);
    
    //Add items on the social share section
    add_filter('avia_social_share_link_arguments', 'avia_add_social_share_link_arguments', 10, 1);
    function avia_add_social_share_link_arguments($args) {
    	$new_array = array(
    		'tripadvisor_icon' => array(
    			"encode"=>true, "encode_urls"=>false, "pattern" => "https://www.tripadvisor.com://send?text=[title]-[permalink]"
    		)
    	);
    
    	return array_merge($new_array, $args);
    }

    Please change it to following one

    // Register tripadvisor icon as a theme icon
    function avia_add_custom_icon($icons) {
    $icons['Tripadvisor'] = array( 'font' =>'tripadvisor', 'icon' => 'uf262');
    return $icons;
    }
    add_filter('avf_default_icons','avia_add_custom_icon', 10, 1);
    
    // Add new icon as an option for social icons
    function avia_add_custom_social_icon($icons) {
    $icons['Tripadvisor'] = 'Tripadvisor';
    return $icons;
    }
    add_filter('avf_social_icons_options','avia_add_custom_social_icon', 10, 1);
    
    
    //Add items on the social share section
    add_filter('avia_social_share_link_arguments', 'avia_add_social_share_link_arguments', 10, 1);
    function avia_add_social_share_link_arguments($args) {
    	$new_array = array(
    		'Tripadvisor' => array(
    			"encode"=>true, "encode_urls"=>false, "pattern" => "https://www.tripadvisor.com://send?text=[title]-[permalink]"
    		)
    	);
    
    	return array_merge($new_array, $args);
    }

    After that you may need to reset Tripadvisor icon in Enfold theme options > Social Profile.

    If you only need to add Tripadvisor icon to social share and not social profiles, you can use the code as following

    // Register tripadvisor icon as a theme icon
    function avia_add_custom_icon($icons) {
    $icons['Tripadvisor'] = array( 'font' =>'tripadvisor', 'icon' => 'uf262');
    return $icons;
    }
    add_filter('avf_default_icons','avia_add_custom_icon', 10, 1);
    
    //Add items on the social share section
    add_filter('avia_social_share_link_arguments', 'avia_add_social_share_link_arguments', 10, 1);
    function avia_add_social_share_link_arguments($args) {
    	$new_array = array(
    		'Tripadvisor' => array(
    			"encode"=>true, "encode_urls"=>false, "pattern" => "https://www.tripadvisor.com://send?text=[title]-[permalink]"
    		)
    	);
    
    	return array_merge($new_array, $args);
    }

    Best regards,
    Yigit

    #1286901

    Hello Yigit,

    that did not work out unfortunately, I always get a syntax error when adding the codes you sent me. I did exactly what you told me but it didn’t work out.

    Regards,
    Verena

    #1286916

    Hi Verena,

    I applied the changes for you. Please review your website :)

    Best regards,
    Yigit

    #1286930

    Hello Yigit

    you are the best :) thank you very much.

    Just one more question: How can I change the background color when hovering over the social share icon tripadvisor? I tried to figure it out and change it by myself but I could not find the right selector. I would like to the add the color #33E0A0 and the owl icon should turn into #000000 instead of white.

    Can you tell me how this is working? :) So many questions….

    Thx, Verena

    #1287057

    Hi Verena,

    I added following code to bottom of Quick CSS field

    .av-share-box ul li.av-social-link-Tripadvisor a:hover {
        background-color: #33E0A0;
        color: #000;
    }

    Please review your website :)

    Best regards,
    Yigit

    #1289063

    Hey Yigit,

    thank you so much. Everything is working perfectly now.

    You can close this one

    Regards, Verena

    #1289073

    Hi,

    I’m glad this was resolved. If you need additional help please let us know here in the forums.

    Best regards,
    Jordan Shannon

Viewing 14 posts - 1 through 14 (of 14 total)
  • The topic ‘Tripadvisor as social share Icon’ is closed to new replies.