Pedro Posada | theme snippet
  • Posted on January 17, 2010 - 7:19pm
    Very handy simple list of country names. I use this list for country select boxes or drop down boxes all the time.
  • Posted on August 28, 2009 - 3:09pm
    I wanted to make one of the pages in my site look and feel completely different than the rest of the site. I wanted to use a different style sheet css file for this page and also didn't want to override all the existing styles. I found a very good post about it on http://drupal.org/node/258756
  • Posted on June 5, 2009 - 3:37pm
    Quick and easy php snippet to have the page title not show on only certain node types. Copy and paste the code below inside your template.php file. type == 'my_node_type'){ $variables['title'] = ''; } } } ?> Works on Drupal 6
  • Posted on October 13, 2008 - 3:06pm
    When I build a site, I always make changes to the style.css file. I always add, modify or remove styles, but there was a problem. When someone came to see my site they would see an old version of the site because their browser would cache the style.css file. In order to avoid this, I came up with this drupal recipe or theme snippet.
  • Posted on October 8, 2008 - 2:15pm
    This is just a sample of how you can add PREV NEXT links to your node type template. This function generates links to navigate your nodes in alphabetical order ASC.
  • Posted on August 5, 2008 - 12:44am
    This code helps you place the pager at top and bottom of your views. Copy and paste this code into your template.php file. use_pager) { $output .= theme('pager', '', $view->pager_limit, $view->use_pager - 1); } $output .= theme_views_view($view, $type, $nodes, $level = NULL, $args = NULL); return $output; } ?> Tested in drupal 4.x and 5.x
  • Posted on April 10, 2008 - 10:32am
    This snippet contains the default regions in the bluemarine theme. I just copy and paste it in the template.php and start adding new ones to the array. And then I define them inside my page.tpl.php This is very useful if you want to place blocks in custom places and easily manage them from the blocks page.