Creating custom widgets

Events happening in the community are now at Drupal community events on www.drupal.org.
eärendil's picture

OS includes a kind of help document for creating custom widgets, but there isn't too much detail in there.

Example via the help doc:

$items = array();
$items['mymodule-block5'] = array(
'module' => 'mymodule',
'delta' => 'block5',
'weight' => -21,
'region' => false,
'label' => 'Latest Things',
'tags' => array('Misc'),
'block_config_path' => "path here",
);
return $items;

Whenever I try to add a config_path, I always get an error, unless I write out the whole path specifically (but that means I have to specify a particular node. i.e. node/1). Something like: http://fakesite.net/fake-name/node/1/etc/.

How would you create a widget that outputs an image or text? I am curious to know what kind of custom widgets anyone has attempted to create and if you have would you be willing to post an example here?

OpenScholar

Group organizers

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: