preprocess function

Get an unaliased views row object for views for views_view_field preprocess functions

  1. /**
  2.  * Returns a view row object in which the property names are unaliased.
  3.  *
  4.  * This facilitates accessing properties from theme hooks when the
  5.  * field_alias is arbitrary unknown, or just non-t
BrightBold's picture

Preprocess Fn to show $submitted username only for one content type

  1. function mytheme_node_submitted($node) {
  2.         if ($vars['node']->type == 'blog_post') {
  3.           return t('by !username on @datetime',
  4.                 array(
  5.                   '!username' => theme('username', $node),
  6.                   '@datetime'

Preprocess Fn to show $submitted usename only for one coment type

  1. function mytheme_node_submitted($node) {
  2.         if ($vars['node']->type == 'blog_post') {
  3.           return t('by !username on @datetime',
  4.                 array(
  5.                   '!username' => theme('username', $node),
  6.                   '@datetime'

Preprocess Fn to show $submitted usename only for one coment type

  1. function matp2point0_node_submitted($node) {
  2.         if ($vars['node']->type == 'blog_post') {
  3.           return t('by !username on @datetime',
  4.                 array(
  5.                   '!username' => theme('username', $node),
  6.                   '@dateti

Override of _preprocess_search_block_form(&variables) is not printing anything

  1. function drunove_preprocess_search_block_form(&$variables) {   
  2.   $variables['search'] = array();
  3.   $variables['form']['search_block_form']['#attributes']['class'] = 'search-input';
  4.   $variables['for
Syndicate content