<?php
2: /**
3: * @package: Standard Advanced Template for SOBI2
4: * V-Card Template
5: * ===================================================
6: * @author: Sigrid Suski, Sigsiu.NET
7: * Url: http://www.sigsiu.net
8: * ===================================================
9: * @copyright Copyright (C) 2008-2009 Sigsiu.NET (http://www.sigsiu.net). All rights reserved.
10: * @license see http://www.gnu.org/licenses/lgpl.html GNU/LGPL.
11: * You can use, redistribute this file and/or modify
12: * it under the terms of the GNU Lesser General Public License as published by
13: * the Free Software Foundation.
14: */
15: defined( '_SOBI2_' ) || ( trigger_error("Restricted access", E_USER_ERROR) && exit() );
16: function sobi2VCview($id, $style, $ico, $img, $title, $fieldsObjects, $fieldsFormatted, $plugins, $editButton = null, $deleteButton = null)
17: {
18: $mySobi = new sobi2( $id );
19: $config =& sobi2Config::getInstance();
20: $pluginsObjects =& $config->S2_plugins;
21: $catid = (int) sobi2Config::request($_REQUEST, 'catid', 0);
22: $link = sobi2Config::sef("index.php?option=com_sobi2&sobi2Task=sobi2Details&catid={$catid}&sobi2Id={$id}&Itemid={$config->sobi2Itemid}");
23: ?>
24: <td <?php echo $style; ?>>
25:
26: <?php
27: //Show Gallery image if gallery installed. Otherwise show the icon image
28: if (method_exists($pluginsObjects['gallery'],'countImages')) {
29: echo $plugins["gallery"];
30: }
31: else {
32: if ($mySobi->icon) {
33 echo"<div class="sobiGalleryImage">".$ico."</div>";
34: }
35: }?>
36:
37:
38: <div style="float:left">
39: <h1><div class="sobi2_vcard_content"><?php echo $title; ?></h1><br/>
40: <?php echo HTML_SOBI::customFieldsData($fieldsFormatted);?>
41: </div>
42: <div class="readmore"><p><a href="<?php echo $link ?>">read more...</a></p></div>
43: </div>
44:
45: <?php if ($deleteButton) { ?>
46: <div style="float: right;">
47: <?php echo $deleteButton; ?>
48: <?php echo $editButton; ?>
49: </div>
50: <?php } ?>
51: </td>
52: <?php } ?>
53: