Adding support for other social networks not working
-
Hi,
I’ve added support for Pinterest, Instagram and Tumblr using the instructions on your site but it’s not working properly.
I’ve enabled support for them on the plugin’s admin settings tab and I can see “Show User’s Pinterest link?” et al on the content tab.
However, on the content tab, when I check the boxes to display Pinterst, Instagram and Tumblr then hit save, the boxes are unchecked again but the message box in yellow say the content and settings were updated.
Here’s my code in functions.php:
add_filter ('wp_biographia_contact_info', 'add_pinterest_support'); function add_pinterest_support ($contacts) { // contacts = array (field => array (field => field-name, contactmethod => description)) $contacts['pinterest'] = array ( 'field' => 'pinterest', 'contactmethod' => __('Pinterest') ); return $contacts; } add_filter ('wp_biographia_link_items', 'add_pinterest_link', 10, 2); function add_pinterest_link ($links, $icon_dir_url) { // links = array (field => array (link_title => title, link_text => text, link_icon => URL) $links['pinterest'] = array ( 'link_title' => __('Pinterest'), 'link_text' => __('Pinterest'), 'link_icon' => $icon_dir_url . 'pinterest.png' ); return $links; } add_filter ('wp_biographia_contact_info', 'add_instagram_support'); function add_instagram_support ($contacts) { // contacts = array (field => array (field => field-name, contactmethod => description)) $contacts['instagram'] = array ( 'field' => 'instagram', 'contactmethod' => __('Instagram') ); return $contacts; } add_filter ('wp_biographia_link_items', 'add_instagram_link', 10, 2); function add_instagram_link ($links, $icon_dir_url) { // links = array (field => array (link_title => title, link_text => text, link_icon => URL) $links['instagram'] = array ( 'link_title' => __('Instagram'), 'link_text' => __('Instagram'), 'link_icon' => $icon_dir_url . 'instagram.png' ); return $links; } add_filter ('wp_biographia_contact_info', 'add_tumblr_support'); function add_tumblr_support ($contacts) { // contacts = array (field => array (field => field-name, contactmethod => description)) $contacts['tumblr'] = array ( 'field' => 'tumblr', 'contactmethod' => __('Tumblr') ); return $contacts; } add_filter ('wp_biographia_link_items', 'add_tumblr_link', 10, 2); function add_tumblr_link ($links, $icon_dir_url) { // links = array (field => array (link_title => title, link_text => text, link_icon => URL) $links['tumblr'] = array ( 'link_title' => __('Tumblr'), 'link_text' => __('Tumblr'), 'link_icon' => $icon_dir_url . 'tumblr.png' ); return $links; }
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Adding support for other social networks not working’ is closed to new replies.