Add a theme function for the block content

budda - May 3, 2007 - 14:28
Project:Countdown
Version:5.x-1.0
Component:Code
Category:feature request
Priority:normal
Assigned:Benjamin Melançon
Status:closed
Description

Make the countdown value format themeable for the block.
I know we can do a per block template, but that's not going to be granular enough to change the layout of the days, hours etc.

#1

Benjamin Melançon - October 28, 2007 - 21:34
Version:5.x-1.x-dev» 5.x-1.0
Assigned to:Anonymous» Benjamin Melançon
Status:active» needs review

This patch applies against version 5.x-1.0 and provides a theme function for all of the block content, simply by throwing most of what was in countdown_block's case: view into a new theme_countdown_block() function.

There might be more logic in this function than there should be, but it will allow people to copy it and put it in their template.php file as your_theme_name_countdown_block() or phptemplate_countdown_block() and completely customize the output-- plus if we do move some logic out of the theming portion and pass it in as variables, it shouldn't break anything for people using this method.

Demo http://dev.wsf2008.net -- all we've done is add a break, but Agaric's theming department will be able to get to it soon.

AttachmentSize
countdown_theme_block.patch 4.95 KB

#2

deekayen - May 12, 2008 - 14:01
Status:needs review» fixed

committed

#3

Anonymous (not verified) - May 26, 2008 - 14:13
Status:fixed» closed

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

 
 

Drupal is a registered trademark of Dries Buytaert.