tripal_stock_teaser.tpl.php
- 2.x tripal_stock/theme/templates/tripal_stock_teaser.tpl.php
- 3.x legacy/tripal_stock/theme/templates/tripal_stock_teaser.tpl.php
1 theme call to tripal_stock_teaser.tpl.php
- tripal_stock_node_view in tripal_stock/
includes/ tripal_stock.chado_node.inc - Implements hook_node_view(). Acts on all content types.
File
tripal_stock/theme/templates/tripal_stock_teaser.tpl.phpView source
- <?php
- $node = $variables['node'];
- $stock = $variables['node']->stock;
- $stock = chado_expand_var($stock,'field','stock.description'); ?>
-
- <div class="tripal_stock-teaser tripal-teaser">
- <div class="tripal-stock-teaser-title tripal-teaser-title"><?php
- print l($node->title, "node/$node->nid", array('html' => TRUE));?>
- </div>
- <div class="tripal-stock-teaser-text tripal-teaser-text"><?php
- print substr($stock->description, 0, 650);
- if (strlen($stock->description) > 650) {
- print "... " . l("[more]", "node/$node->nid");
- } ?>
- </div>
- </div>