source: extensions/piclens/stuffs_module/main.inc.php @ 19910

Last change on this file since 19910 was 9448, checked in by patdenice, 14 years ago

PWG Stuffs module is now integrated in piclens plugin.

File size: 5.4 KB
Line 
1<?php
2
3if (!defined('PHPWG_ROOT_PATH')) die('Hacking attempt!');
4
5global $page;
6
7// RSS Feed only available in category or index gallery
8if (isset($page['section']) and $page['section'] == 'categories')
9{
10  include_once PHPWG_ROOT_PATH.'plugins/piclens/include/Piclens.class.php';
11
12  $obj = new Piclens();
13  $obj->load_config();
14
15  $rssfeed = '';
16
17  if( empty($page['category']))
18  {
19    $rssfeed = $obj->root_site_piclens.PICLENS_PATH.'piclenswall-rss.php?/categories';
20  }
21  else
22  {
23  // remplacement naviagation ne doit pas etre active et mis en place sur la page...
24    if (!@$obj->my_config['piclens_wall_nav'] or !@in_array($page['category']['id'], $obj->my_config['piclens_wall_cat_nav_replace']))
25    {       
26      if (@$obj->my_config['piclens_wall_specif'] == 'common') // pas de specificites 3DWall : utilisation des parametres piclens
27      {
28        $rssfeed = $obj->root_site_piclens.PICLENS_PATH.'piclens-rss.php?/category/'.(empty($page['category']['permalink']) ? $page['category']['id'] : $page['category']['permalink']);
29      }
30      elseif (@in_array($page['category']['id'], $obj->my_config['piclens_wall_categories']))
31      {
32        //  categorie pour laquelle le mur est parametre.
33        $rssfeed = $obj->root_site_piclens.PICLENS_PATH.'piclenswall-rss.php?/category/'.(empty($page['category']['permalink']) ? $page['category']['id'] : $page['category']['permalink']);
34      }
35    }
36  }
37  $block['RSSFEED'] = $rssfeed;
38  $block['PIC_HEIGHT']  = @$obj->my_config['piclens_wall_height']; //$datas[0];
39  $block['COLOR']  = @$obj->my_config['piclens_wall_color']; //$datas[1];
40  $block['SHOWFULLSCREEN'] = (@$obj->my_config['piclens_wall_showfullscreen'] ? "true" : "false");
41  $block['SHOWEMBED'] = (@$obj->my_config['piclens_wall_showembed'] ? "true" : "false");
42  $block['SHOWSEARCH'] = (@$obj->my_config['piclens_wall_showsearch'] ? "true" : "false");
43  $block['TRANSPARENT'] = @$obj->my_config['piclens_wall_transparent'];
44  $block['SWF_LINK'] = (@$obj->my_config['piclens_wall_swflocal'] ? @$obj->root_site_piclens.PICLENS_PATH.'swf/cooliris.swf' : 'http://apps.cooliris.com/embed/cooliris.swf');
45  $block['NBLIGNE'] = (isset($obj->my_config['piclens_wall_nb_ligne']) ? @$obj->my_config['piclens_wall_nb_ligne'] : "3");
46
47  if (isset($obj->my_config['piclens_wall_showitemembed']))
48    $block['showitemembed'] = (@$obj->my_config['piclens_wall_showitemembed'] ? "true" : "false");
49  if (isset($obj->my_config['piclens_wall_showlinkout']))
50    $block['showlinkout'] = (@$obj->my_config['piclens_wall_showlinkout'] ? "true" : "false");
51  if (isset($obj->my_config['piclens_wall_showclose']))
52    $block['showclose'] = (@$obj->my_config['piclens_wall_showclose'] ? "true" : "false");   
53 
54  if (isset($obj->my_config['piclens_wall_showChrome']))
55    $block['showChrome'] = (@$obj->my_config['piclens_wall_showChrome'] ? "true" : "false");
56  if (isset($obj->my_config['piclens_wall_showDescription']))
57    $block['showDescription'] = (@$obj->my_config['piclens_wall_showDescription'] ? "true" : "false");
58  if (isset($obj->my_config['piclens_wall_showReflections']))
59    $block['showReflections'] = (@$obj->my_config['piclens_wall_showReflections'] ? "true" : "false");
60  if (isset($obj->my_config['piclens_wall_showTutorial']))
61    $block['showTutorial'] = (@$obj->my_config['piclens_wall_showTutorial'] ? "true" : "false");
62  if (isset($obj->my_config['piclens_wall_showNavArrows']))
63    $block['showNavArrows'] = (@$obj->my_config['piclens_wall_showNavArrows'] ? "true" : "false");
64 
65  $block['backgroundAlpha'] = isset($obj->my_config['piclens_wall_backgroundAlpha']) ? $obj->my_config['piclens_wall_backgroundAlpha'] : "1.0";
66  if (isset($obj->my_config['piclens_wall_backgroundColor']))
67    $block['backgroundColor'] = str_replace('#', '%23', @$obj->my_config['piclens_wall_backgroundColor']) ;
68  if (isset($obj->my_config['piclens_wall_glowColor']))
69    $block['glowColor'] = str_replace('#', '%23', @$obj->my_config['piclens_wall_glowColor']);
70  if (isset($obj->my_config['piclens_wall_descriptionHeight']))
71    $block['descriptionHeight'] = @$obj->my_config['piclens_wall_descriptionHeight'];
72  if (isset($obj->my_config['piclens_wall_tilt']))
73    $block['tilt'] = $obj->my_config['piclens_wall_tilt'];
74
75    if (isset($obj->my_config['piclens_wall_backgroundImage']) and !empty($obj->my_config['piclens_wall_backgroundImage']))
76        $block['backgroundImage'] = @$obj->my_config['piclens_wall_backgroundImage'];
77
78    if (isset($obj->my_config['piclens_wall_tutorial']) and !empty($obj->my_config['piclens_wall_tutorial']))
79        $block['tutorial'] = (empty($obj->my_config['piclens_wall_tutorialtime']) ? "4500" : @$obj->my_config['piclens_wall_tutorialtime']).','.@$obj->my_config['piclens_wall_tutorial'];   
80
81
82  if (isset($obj->my_config['piclens_wall_customButtonURL']) and !empty($obj->my_config['piclens_wall_customButtonURL']))
83        $block['customButton'] = @$obj->my_config['piclens_wall_customButtonURL'].(empty($obj->my_config['piclens_wall_customButtonTARGET']) ? ','.PICLENS_PATH : ','.@$obj->my_config['piclens_wall_customButtonTARGET']); 
84
85    if (isset($obj->my_config['piclens_wall_icons']) and !empty($obj->my_config['piclens_wall_icons']))
86        $block['icons'] = @$obj->my_config['piclens_wall_icons']; 
87    if (isset($obj->my_config['piclens_wall_linkCSS']) and !empty($obj->my_config['piclens_wall_linkCSS']))
88        $block['icons'] = @$obj->my_config['piclens_wall_linkCSS'];
89
90  $block['TEMPLATE'] = realpath(PICLENS_PATH.'stuffs_piclenswall.tpl');
91}
92
93?>
Note: See TracBrowser for help on using the repository browser.