If the function follow_follow_networks() should get the data from the database, it would be easier to add other networks (like Hyves), and easier to remove networks not needed.

Comments

q0rban’s picture

Category: feature » support
Status: Active » Fixed

Hi Niels.. Thanks for the feedback! There is already a hook_follow_networks() invocation to add more networks, so if you wanted to create a separate module that implements this hook, you could add whatever networks you want that way. Thanks!

q0rban’s picture

Title: Move networks to database » Allow altering of networks
Assigned: Unassigned » q0rban
Category: support » task

I will add this here as a task though, bc I need to add a drupal_alter call on the networks so that some can be removed. Thanks!

q0rban’s picture

Status: Fixed » Active
jackhutton’s picture

don't know if this is the right area; but I'd like to add a follow link for a wordpress blog which isn't listed as an option in the configuration.

can i add a line item or modify a line item to modify the title of an unused link to make it a wordpress link.
i would pull in the proper logo image

thanks

jackhutton’s picture

I tried putting this into my template.php file..but doesn't seem to do the trick..and
apologize if this isn't the appropriate area in the forum for posting code questions..
thx

/**
 * Implementation of hook_follow_networks().
 *
 * @return
 *   An array of network names, keys are machine names, values are visible titles.
 */
function eggonbeagle_follow_follow_networks() {
  return array(
    'facebook'  => t('Facebook'),
    'virb'      => t('Virb'),
    'myspace'   => t('MySpace'),
    'twitter'   => t('Twitter'),
    'picasa'    => t('Picasa'),
    'flickr'    => t('Flickr'),
    'youtube'   => t('YouTube'),
    'vimeo'     => t('Vimeo'),
    'bliptv'    => t('blip.tv'),
    'lastfm'    => t('last.fm'),
    'linkedin'  => t('LinkedIn'),
    'delicious' => t('Delicious'),
     'wordpress' => t('Wordpress'),
    'tumblr'    => t('Tubmlr'),
  );
}
q0rban’s picture

Hi Jack,
Try this (without the ). Replace 'eggonbeagle' with the machine name of your module. This won't work in template.php, you'll actually have to create a small module for it.

<?php
/**
* Implementation of hook_follow_networks().
*
* @return
*   An array of network names, keys are machine names, values are visible titles.
*/
function eggonbeagle_follow_networks() {
  return array(
    'wordpress' => t('Wordpress'),
  );
}
?>
jackhutton’s picture

thanks for this. the site is posted, but this will be useful as I modify and rework the site; and for future projects.
appreciate your clear, patient responses..
thanks
jack

q0rban’s picture

Version: 6.x-1.3 » 7.x-1.x-dev
Status: Active » Fixed

This has been implemented in the 7.x version, and I don't really have any intentions of adding this to 6.x (unless you complain loudly enough)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

marktheshark’s picture

How does one specify the icon path for an existing style?

I can add the networks with the hook, but I don't want to change the style, just specify an additional directory to look into for icons...

Edit: After looking into the hooks some more, turns out you have to specify a directory for an entire icon set, you can't do it per network. Also, adding the icon as a background to custom links has to be done via CSS.

It would be nice to have the CSS updated to include also the custom icons, but OK, I got around it.