Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php if ($fields['type']->content == 'Event'): ?>
- <a href="<?php print $fields['path']->content; ?>"><?php print $fields['title']->content; ?></a>
- <?php endif; ?>
- <?php if ($fields['type']->content == 'PATF News'): ?>
- <a href="<?php print $fields['path']->content; ?>"><?php print $fields['title']->content; ?></a>
- <?php endif; ?>
- <?php if ($fields['type']->content == 'News Link'): ?>
- //This link goes to _blank
- <a href="<?php print $fields['field_link']->content; ?>" target="_blank"><?php print $fields['title']->content; ?></a>
- <?php endif; ?>
- if ($fields['type']->content == 'Page') {
- // print title linking to node
- print $fields['title']->content;
- }
- if ($fields['type']->content == 'News') {
- // print title linking to other website
- print 'http://example.com/'. $fields['title']->content;
- }
- $link = $fields['path']->content;
- $title = $fields['title']->content;
- $options = array();
- if ($fields['type']->content == 'News Link') {
- $link = $fields['field_link']->content;
- $options['attributes']['target'] = '_blank';
- }
- print l($title, $link, $options);
- <?php if ($fields['type']->content == 'xxx') { print 'Test'; } ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement