Using the Banner Module
Agaric is experimenting with the Drupal Banner module, and as some of it is less than intuitive, we thought we'd document some of it here.
- Don't forget to follow its installation instructions and put those two PHP files in your root directory.
- And put at least
<?php print banner_display(4, 1); ?>
in your page.tpl.php where you want the banner to appear, with "4" being the taxonomy term ID of the banner group (see docs, and "1" is the number of banners from that group at a time.) - You may be able to administer its settings under
admin > settings > banner
, but you have to do additional access control settings to see its other admin page underadmin > banner
(this is Drupal 4.7) . - To actually create a banner, you go to
create content
as you would for any node - Under Default Options under
/admin/settings/content-types/banner
(Drupal 4.7) you probably want to uncheck "Promote to front page" and change Default Comment Settings to disabled. - When adding a banner, make note of the banner limits chance setting. If you or someone else has been setting chance to 100 (it defaults to 1), then not changing will mean your banner won't show up very much.
- If you want to replace one banner with another (so that it always displays), be sure to disable other banners.
- Don't use Image Assist to upload your banner images (although changing the setting to text would be an interesting experiment...). Unfortunately you cannot disable image_asst for all banner node type textboxes when editing, but you can tell image_asst to only display its helpful link on certain node creation pages. For instance, under "Access Settings" change
node/*
tonode/*/edit</edit> and add:
<code>node/add/page
node/add/story
node/add/blog
... and whatever other content types you want to allow using image assist when creating content.
As a final thought, Agaric would be interested in looking into using imagecache with banner module to automatically size banners to fit in their banner area, but for now uploading appropriately sized and shaped images for banners (or just using text!) is recommended.
Agaric is experimenting with the Drupal Banner module, and as some of it is less than intuitive, we thought we'd document some of it here.
- Don't forget to follow its installation instructions and put those two PHP files in your root directory.
- And put at least
<?php print banner_display(4, 1); ?>
in your page.tpl.php where you want the banner to appear, with "4" being the taxonomy term ID of the banner group (see docs, and "1" is the number of banners from that group at a time.) - You may be able to administer its settings under
admin > settings > banner
, but you have to do additional access control settings to see its other admin page underadmin > banner
(this is Drupal 4.7) . - To actually create a banner, you go to
create content
as you would for any node - Under Default Options under
/admin/settings/content-types/banner
(Drupal 4.7) you probably want to uncheck "Promote to front page" and change Default Comment Settings to disabled. - When adding a banner, make note of the banner limits chance setting. If you or someone else has been setting chance to 100 (it defaults to 1), then not changing will mean your banner won't show up very much.
- If you want to replace one banner with another (so that it always displays), be sure to disable other banners.
- Don't use Image Assist to upload your banner images (although changing the setting to text would be an interesting experiment...). Unfortunately you cannot disable image_asst for all banner node type textboxes when editing, but you can tell image_asst to only display its helpful link on certain node creation pages. For instance, under "Access Settings" change
node/*
tonode/*/edit</edit> and add:
<code>node/add/page
node/add/story
node/add/blog
... and whatever other content types you want to allow using image assist when creating content.
As a final thought, Agaric would be interested in looking into using imagecache with banner module to automatically size banners to fit in their banner area, but for now uploading appropriately sized and shaped images for banners (or just using text!) is recommended.
Comments
Post new comment