Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I created a teaser form for my content:
<?php print 'Language(s): '. $node->taxonomy[683]->name ?>
<?php print $node->content['field_cert_status']['#value'] ?>
<?php print $node->field_job_type[0]['view'] .' for ' $node->field_meeting_type[0]['view'] ?>
<?php print 'Created/Changed: '. format_date($node->changed, 'short') ?>
<?php print $node->content['group_meeting_information']['#children'] ?>
I cannot get it to show with any method I have tried (Views, taxonomy/term, custom module for showing types). What am I doing wrong?
Here's the View, in case that helps:
$view = new stdClass();
$view->name = 'Jobs';
$view->description = 'List of Jobs';
$view->access = array (
);
$view->view_args_php = '';
$view->page = TRUE;
$view->page_title = '';
$view->page_header = '';
$view->page_header_format = '1';
$view->page_footer = '';
$view->page_footer_format = '1';
$view->page_empty = 'Sorry, I can\'t find any at the moment.';
$view->page_empty_format = '1';
$view->page_type = 'teaser';
$view->url = 'job_list';
$view->use_pager = TRUE;
$view->nodes_per_page = '10';
$view->menu = TRUE;
$view->menu_title = 'Jobs List';
$view->menu_tab = FALSE;
$view->menu_tab_weight = '0';
$view->menu_tab_default = FALSE;
$view->menu_tab_default_parent = NULL;
$view->menu_tab_default_parent_type = 'tab';
$view->menu_parent_tab_weight = '0';
$view->menu_parent_title = '';
$view->sort = array (
array (
'tablename' => 'node',
'field' => 'sticky',
'sortorder' => 'ASC',
'options' => '',
),
array (
'tablename' => 'node',
'field' => 'changed',
'sortorder' => 'ASC',
'options' => 'normal',
),
);
$view->argument = array (
);
$view->field = array (
array (
'tablename' => 'node',
'field' => 'title',
'label' => '',
'handler' => 'views_handler_field_nodelink',
'options' => 'link',
),
array (
'tablename' => 'node',
'field' => 'body',
'label' => '',
'handler' => 'views_handler_field_teaser',
),
);
$view->filter = array (
array (
'tablename' => 'node',
'field' => 'type',
'operator' => 'OR',
'options' => '',
'value' => array (
0 => 'job',
),
),
);
$view->exposed_filter = array (
);
$view->requires = array(node);
$views[$view->name] = $view;
Comments
Comment #1
NancyDru?
Comment #2
tanjerine CreditAttribution: tanjerine commentedsame problem here. im using contemplate with nodewords. and nothing i put in the teaser portion of contemplate is printed out.
[edit] my bad. the teaser is being created (did a view that would output the teaser)... the problem is that nodewords isn't 'getting' the teaser.