-
AuthorPosts
-
December 29, 2014 at 12:40 pm #372528
Hi, I would like to know how to insert the social share section into my breadcrumbs area.
I have looked through the forum and also used this help section http://kriesi.at/documentation/enfold/enable-social-share-section-for-pages/ but did not manage.I would also like to add a custom class to this share section so I can style it specifically for the breadcrumb area.
Thank you,
- This topic was modified 9 years, 12 months ago by Yigit.
December 29, 2014 at 12:51 pm #372535Hi ybema!
If I understand you correctly you want to show some social icons beside the breadcrumb navigation? If thats the case then I am afraid this is not easily done without major customization. Truth to be told I am not even sure what the best way would be, but it certainly would take a couple of hours to implement and test a solution, so I am afraid this is outside the scope of our support. Sorry for that.
If you are not very good with PHP, which is a requirement for this customization, I would recommend to hire someone for a custom job at http://studio.envato.com
Best reagards!
KriesiDecember 29, 2014 at 1:30 pm #372551Hi, thank you for your comment.
I did manage to implement the social share box using this code but this inject the share box at the bottom of a page created with the avia template builder.
/* Enable Social Share Buttons */ add_filter('avf_template_builder_content', 'avia_add_social_toolbar_template_builder', 10, 1); function avia_add_social_toolbar_template_builder($content = "") { $content .= avia_social_share_links(array(), false); $content .= ''; return $content; }
I then changed some of the CSS to get this result: http://sustainovate.com/fisheries/
Ofcourse this is not the preferred method … but is it not possible to insert the social share section into the header or before the page content?Thank you,
December 29, 2014 at 1:45 pm #372555Hm, might be possible by using the following filter + your function:
/* Enable Social Share Buttons */ add_filter('avf_title_args', 'avia_add_social_toolbar_template_builder', 10, 2); function avia_add_social_toolbar_template_builder($args, $id) { $args['additions'] .= avia_social_share_links(array(), false); return $args; }
this is untested and even if it works will probably required addition CSS to position and style the elements…
December 29, 2014 at 2:54 pm #372565Hi,
Brilliant!
It works perfect for now.For others who would like to achieve the same, include this code to your functions.php in your child theme:
/* Enable Social Share Buttons */ add_filter('avf_title_args', 'avia_add_social_toolbar_template_builder', 10, 2); function avia_add_social_toolbar_template_builder($args, $id) { $args['additions'] .= avia_social_share_links(array(), false); return $args; }
And include this in your style.css in your child theme:
/* Title Social Share Section Adjustment */ .title_container .av-share-box { width: 200px; margin-top: 2px; } .title_container .av-share-box ul li a { padding: 5px 0; } .title_container .av-share-box .av-share-link-description { display: none; } .title_container .av-share-box .avia-related-tooltip { display: none !important; } @media only screen and (max-width: 767px) { .title_container .av-share-box { display: none; } .responsive .title_container .breadcrumb { position: absolute; right: auto; top: 50%; margin-top: -7px; left: -2px; } }
Thank you!
December 29, 2014 at 3:02 pm #372570 -
AuthorPosts
- The topic ‘Insert social share section into the breadcrumbs area’ is closed to new replies.