Project

General

Profile

Download (2.74 KB) Statistics
| Branch: | Tag: | Revision:
1
<?php 
2
/*
3
   $variables = array(
4
    'content'        => ($teaser && $node->teaser) ? $node->teaser : $node->body,
5
    'date'           => format_date($node->created),
6
    'links'          => $node->links ? theme('links', $node->links, array('class' => 'links inline')) : '',
7
    'name'           => theme('username', $node),
8
    'node'           => $node,  // we pass the actual node to allow more customization
9
    'node_url'       => url('node/'. $node->nid),
10
    'page'           => $page,
11
    'taxonomy'       => $taxonomy,
12
    'teaser'         => $teaser,
13
    'terms'          => theme('links', $taxonomy, array('class' => 'links inline')),
14
    'title'          => check_plain($node->title)
15
  );
16
*/ 
17
?>
18
<?php phptemplate_comment_wrapper(NULL, $node->type); ?>
19

    
20
<div id="node-<?php print $node->nid; ?>" class="node<?php if ($sticky) { print ' sticky'; } ?><?php if (!$status) { print ' node-unpublished'; } ?>">
21

    
22
<?php print $picture ?>
23

    
24
<?php if ($page == 0): ?>
25
  <h2><a href="<?php print $node_url ?>" title="<?php print $title ?>"><?php print $title ?></a></h2>
26
<?php endif; ?>
27

    
28
  <?php if ($submitted): ?>
29
    <span class="submitted"><?php print t('!date — !username', array('!username' => theme('username', $node), '!date' => format_date($node->created))); ?></span>
30
  <?php endif; ?>
31

    
32
  <div class="content">
33
    <?php 
34
      print '<h3>'.t('Expert: ').$node->content['field_parent_person']['#value'].'</h3>';
35
      
36
      $display_options =  array(
37
            //taxa
38
            12 => array('term_path'=> true, 'notes'=>$node->field_taxon_notes[0]['view']),
39
            //geo
40
            13 => array('term_path'=> true, 'notes'=>$node->field_geo_notes[0]['view']),
41
            // methods
42
            5 => array('term_path'=> true),
43
          );
44
          
45
      
46
      print theme('expertdb_interest_categories', $node->taxonomy, $display_options, true);
47
      
48
      $view_args = array('');
49
      
50
      if($node->field_taxon_project){
51
        foreach($node->field_taxon_project as $project){
52
          $view_args[0] .= (strlen($view_args[0]) ? '+' : '').$project['nid'];
53
        }
54
      }
55
      
56
      $projects_view = views_get_view('projects_by_interest');
57
      if(views_access($projects_view)){
58
        $out = views_build_view('block', $projects_view, $view_args, false, false);
59
        if($out){
60
          print '<h3>'.t('Projects:').'</h3>'.$out;
61
        } else {
62
          // empty table but add_link at bottom
63
          print '<h3>'.t('Projects:').'</h3>'.theme('views_view_table_projects_by_interest',$projects_view, array());
64
        }
65
      }
66
      //print $content ?>
67
  </div>
68

    
69
  <div class="clear-block clear">
70

    
71
    <?php if ($links): ?>
72
      <div class="links"><?php print $links; ?></div>
73
    <?php endif; ?>
74
  </div>
75

    
76
</div>
(8-8/14)