Changeset 3619
- Timestamp:
- Jul 17, 2009, 7:41:22 PM (15 years ago)
- Location:
- extensions/piclens
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/piclens/admin/config.php
r3410 r3619 59 59 $me->my_config['piclens_bestrated_active'] = isset($_POST['piclens_bestrated_active']); 60 60 $me->my_config['piclens_favorites_active'] = isset($_POST['piclens_favorites_active']); 61 $me->my_config['piclens_tags_active'] = isset($_POST['piclens_tags_active']); 61 62 62 63 $me->my_config['piclens_recursive_mode'] = $_POST['recursive_mode']; … … 67 68 } 68 69 69 //$template->assign('PICLENS_ACTIVATED', $me->my_config['piclens_active'] ? 'checked="checked"' : '' );70 //$template->assign('PICLENS_RECURSIVE_ACTIVATED', $me->my_config['piclens_recursive'] ? 'checked="checked"' : '' );71 //$template->assign('PICLENS_GALLERIE_ACTIVATED', $me->my_config['piclens_gallerie_active'] ? 'checked="checked"' : '' );72 73 70 // Affichage des coix miniature possibles pour la recursivite de l'option 'Activer gallerie' 74 71 $i=1; … … 78 75 $i++; 79 76 } 80 //$template->assign('PICLENS_GALLERIE_TYPE', $me->my_config['piclens_gallerie_type']);81 82 //$template->assign('PICLENS_LITE_ACTIVATED', $me->my_config['piclens_lite_active'] ? 'checked="checked"' : '' );83 84 //$template->assign('PICLENS_SECUREIMAGE', get_db_plugins('active','secureImages'));85 //$template->assign('PICLENS_SECUREIMAGE_ACTIVATED', $me->my_config['piclens_secureimage'] ? 'checked="checked"' : '' );86 87 //$template->assign('PICLENS_EXTENDEDDESC', get_db_plugins('active','ExtendedDescription') );88 //$template->assign('PICLENS_EXTENDEDDESC_ACTIVATED', $me->my_config['piclens_extendeddesc'] ? 'checked="checked"' : '' );89 90 //$template->assign('PICLENS_RECENTPICS_ACTIVATED', $me->my_config['piclens_recentpics_active'] ? 'checked="checked"' : '' );91 //$template->assign('PICLENS_RECENTCATS_ACTIVATED', $me->my_config['piclens_recentcats_active'] ? 'checked="checked"' : '' );92 //$template->assign('PICLENS_MOSTVISITED_ACTIVATED', $me->my_config['piclens_mostvisited_active'] ? 'checked="checked"' : '' );93 //$template->assign('PICLENS_BESTRATED_ACTIVATED', $me->my_config['piclens_bestrated_active'] ? 'checked="checked"' : '' );94 //$template->assign('PICLENS_FAVORITES_ACTIVATED', $me->my_config['piclens_favorites_active'] ? 'checked="checked"' : '' );95 77 96 78 $template->assign(array( … … 109 91 'PICLENS_BESTRATED_ACTIVATED' => ($me->my_config['piclens_bestrated_active'] ? 'checked="checked"' : '' ), 110 92 'PICLENS_FAVORITES_ACTIVATED' => ($me->my_config['piclens_favorites_active'] ? 'checked="checked"' : '' ), 93 'PICLENS_TAGS_ACTIVATED' => ($me->my_config['piclens_tags_active'] ? 'checked="checked"' : '' ), 111 94 $me->my_config['piclens_recursive_mode'].'_CHECKED' => 'checked="checked"', 112 95 'ICON_INFO' => PICLENS_ADMIN_PATH . 'info.png', -
extensions/piclens/admin/config.tpl
r3410 r3619 102 102 <input type="checkbox" name="piclens_recentcats_active" {$PICLENS_RECENTCATS_ACTIVATED}/> {'piclens_recentcats_label'|@translate} 103 103 <br/> 104 <input type="checkbox" name="piclens_tags_active" {$PICLENS_TAGS_ACTIVATED}/> {'piclens_tags_label'|@translate} 105 <br/> 104 106 105 107 </TD> -
extensions/piclens/admin/piclenswallconfig.php
r3598 r3619 45 45 $me->my_config['piclens_wall_spec_bestrated'] = isset($_POST['piclens_wall_spec_bestrated']); 46 46 $me->my_config['piclens_wall_spec_favorites'] = isset($_POST['piclens_wall_spec_favorites']); 47 $me->my_config['piclens_wall_spec_tags'] = isset($_POST['piclens_wall_spec_tags']); 47 48 48 49 $me->my_config['piclens_wall_swflocal'] = isset($_POST['piclens_wall_swflocal']); … … 104 105 'PICLENS_WALL_SPEC_BESTRATED' => ($me->my_config['piclens_wall_spec_bestrated'] ? 'checked="checked"' : '' ), 105 106 'PICLENS_WALL_SPEC_FAVORITES' => ($me->my_config['piclens_wall_spec_favorites'] ? 'checked="checked"' : '' ), 107 'PICLENS_WALL_SPEC_TAGS' => ($me->my_config['piclens_wall_spec_tags'] ? 'checked="checked"' : '' ), 106 108 'PICLENS_WALL_SWFLOCAL' => ($me->my_config['piclens_wall_swflocal'] ? 'checked="checked"' : '' ) 107 109 )); -
extensions/piclens/admin/piclenswallconfig.tpl
r3598 r3619 139 139 <br/> 140 140 <input type="checkbox" name="piclens_wall_spec_recentpics" {$PICLENS_WALL_SPEC_RECENTPICS}/> {'piclens_recentpics_label'|@translate} 141 <br/> 142 <input type="checkbox" name="piclens_wall_spec_tags" {$PICLENS_WALL_SPEC_TAGS}/> {'piclens_tags_label'|@translate} 141 143 142 144 </TD> -
extensions/piclens/admin/rssfeed.php
r3614 r3619 19 19 $me = get_plugin_data($plugin_id); 20 20 21 //$order_list = array('Defaut Piwigo', 'Date de Creation', 'Date d\'ajout', 'Note Moyenne', 'Plus vues', 'Nom du fichier', 'Id', 'Aléatoire', 'Catégories');22 21 $order_list = array(l10n('piclens_label_orderPiwigo'), l10n('piclens_label_orderCreDate'), l10n('piclens_label_orderAddDate'), l10n('piclens_label_orderRank'), l10n('piclens_label_orderBest'), l10n('piclens_label_orderName'), l10n('piclens_label_orderID'), l10n('piclens_label_orderRand'), l10n('piclens_label_orderCat')); 23 //$sort_list = array('Defaut Piwigo', 'Croissant', 'Decroissant');24 22 $sort_list = array(l10n('piclens_label_sortPiwigo'), l10n('piclens_label_sortUp'), l10n('piclens_label_sortDown')); 25 23 26 //$thumb_list = array('Miniature', 'Normal');27 24 $thumb_list = array(l10n('piclens_label_TypeTN'), l10n('piclens_label_TypeNorm')); 28 //$normal_list = array('Miniature', 'Normal', 'High');29 25 $normal_list = array(l10n('piclens_label_TypeTN'), l10n('piclens_label_TypeNorm'), l10n('piclens_label_TypeHigh')); 30 //$nameformat_list = array('Nom vignette : taille', 'Nom vignette', 'Nom de l\'image'); 26 31 27 //$nameformat_list = array(l10n('piclens_label_Name1'), l10n('piclens_label_Name2'), l10n('piclens_label_Name3')); 32 //$descformat_list = array('Rien', 'Nom de l\'image', 'Description de l\'image');33 28 //$descformat_list = array(l10n('piclens_label_Desc1'), l10n('piclens_label_Desc2'), l10n('piclens_label_Desc3')); 34 29 … … 61 56 $me->my_config['piclens_rss_name'] = $_POST['piclens_rss_name']; 62 57 $me->my_config['piclens_rss_desc'] = $_POST['piclens_rss_desc']; 58 $me->my_config['piclens_exclude_double'] = isset($_POST['piclens_exclude_double']); 63 59 64 60 … … 147 143 $template->assign('PICLENS_RSS_NAME', $me->my_config['piclens_rss_name']); 148 144 $template->assign('PICLENS_RSS_DESC', $me->my_config['piclens_rss_desc']); 145 $template->assign('PICLENS_EXCLUDE_DOUBLE', $me->my_config['piclens_exclude_double'] ? 'checked="checked"' : '' ); 149 146 150 147 -
extensions/piclens/admin/rssfeed.tpl
r3614 r3619 134 134 </TD> 135 135 </TR> 136 <TR> 137 <TD > 138 - <input type="checkbox" name="piclens_exclude_double" {$PICLENS_EXCLUDE_DOUBLE}/> {'piclens_rsscfg_exclude_double'|@translate} 139 </TD > 140 <TD colspan="2"> 141 </TD> 142 </TR> 136 143 137 144 </TABLE> -
extensions/piclens/generate_rss.php
r3614 r3619 178 178 } 179 179 180 // Gestion des tags 181 elseif (($page['section']) == 'tags') 182 { 183 // $row = get_image_ids_for_tags($page['tags_id']); 184 // $cat need to bo not null... 185 array_push($cat, "1"); 186 $query = 'SELECT DISTINCT(tag.image_id) , img.id, img.file, img.date_available, img.date_creation, img.tn_ext, img.name, 187 img.comment, img.author, img.hit ,img.filesize, img.average_rate, img.has_high, img.path, 188 img.level , ic.category_id, cat.name AS catname, cat.comment AS catcomment, cat.rank, cat.status, 189 cat.visible, cat.uppercats, cat.permalink, cat.dir ' 190 .' FROM '.IMAGE_TAG_TABLE.' AS tag '."\n" 191 .' INNER JOIN '.IMAGES_TABLE.' AS img ON tag.image_id = img.id' 192 .' INNER JOIN '.IMAGE_CATEGORY_TABLE.' AS ic ON img.id = ic.image_id' 193 .' INNER JOIN '.CATEGORIES_TABLE.' AS cat ON ic.category_id = cat.id' 194 .' WHERE tag.tag_id IN ('.implode(',', $page['tag_ids']).') ' 195 .$forbidden 196 .' '.$conf['order_by'].';'; 197 } 198 199 180 200 elseif (($page['section']) == 'categories') 181 201 { … … 320 340 { 321 341 $result = pwg_query($query); 342 322 343 while ($row = mysql_fetch_assoc($result)) 323 344 { … … 329 350 && ((isset($row['catname']) ? !(substr_count($row['catname'], $piclens_extdesc_hidden)) : true)) 330 351 )) 331 array_push($pictures, $row); 352 { 353 // Suppression des doublons (même path) 354 if ($obj->my_config['piclens_exclude_double']) 355 { 356 $double = false; 357 foreach ($pictures as $key => $values) 358 // même path 359 if ($row['path'] == $values['path']) 360 $double=true; 361 362 // pas de double trouvé 363 if (!$double) 364 array_push($pictures, $row); 365 } 366 else 367 array_push($pictures, $row); 368 } 332 369 } 333 370 } 334 371 // Fin requetes recherches photos 335 372 336 373 337 374 // Creation du fichier xml (flux rss) 338 375 // It's a rss file … … 366 403 367 404 // Icone de la gallerie dans le flux RSS 368 // echo '<logo url="'.get_root_url().'template-common/favicon.ico"></logo>';369 405 echo "\n"; 370 406 echo '<atom:icon>'.$obj->root_site_piclens.'template-common/favicon.ico</atom:icon>'; 371 407 echo "\n"; 372 // <atom:link href="http://mywebsite.com/photos.rss" rel="self" type="application/rss+xml" />373 408 374 409 // Pour chacune des images, preparation du flux xml … … 544 579 echo "<link>" . $url . "</link>\n"; 545 580 546 // echo "<guid>" . $row['id'] . "\</guid>\n";547 581 echo "<guid isPermaLink=\"false\">\"" . $row['id'] . "\"</guid>\n"; 548 582 -
extensions/piclens/include/Piclens.class.php
r3410 r3619 47 47 { 48 48 49 // Page Tags 50 if (($page['section']) == 'tags' && $this->my_config['piclens_tags_active']) 51 { 52 $tags = ''; 53 foreach ($page['tag_ids'] as $id => $tag) 54 $tags .= '/'.$tag.'-'.$page['tags'][''.$id.'']['name']; 55 56 $piclnkMaster='<link rel="alternate"' 57 . ' href="'.$this->root_site_piclens.PICLENS_PATH.'piclens-rss.php?/tags' 58 .$tags 59 .'"' 60 .' type="application/rss+xml" title="" id="recent_pics"' 61 . ' >' . "\n"; 62 } 49 63 // Page images recentes 50 if (($page['section']) == 'recent_pics' && $this->my_config['piclens_recentpics_active'])64 elseif (($page['section']) == 'recent_pics' && $this->my_config['piclens_recentpics_active']) 51 65 { 52 66 $piclnkMaster='<link rel="alternate"' … … 250 264 || (($page['section']) == 'best_rated' && $this->my_config['piclens_bestrated_active']) 251 265 || (($page['section']) == 'favorites' && $this->my_config['piclens_favorites_active']) 266 || (($page['section']) == 'tags' && $this->my_config['piclens_tags_active']) 252 267 || (($page['section']) == 'categories') 253 268 ) … … 443 458 else if ($page['section'] == 'favorites' && $this->my_config['piclens_wall_spec_favorites']) 444 459 $rssfeed = $this->root_site_piclens.PICLENS_PATH.'piclens-rss.php?/favorites'; 460 else if ($page['section'] == 'tags' && $this->my_config['piclens_wall_spec_tags']) 461 { 462 $tags = ''; 463 foreach ($page['tag_ids'] as $id => $tag) 464 $tags .= '/'.$tag.'-'.$page['tags'][''.$id.'']['name']; 465 $rssfeed = $this->root_site_piclens.PICLENS_PATH.'piclens-rss.php?/tags'.$tags; 466 } 445 467 } 446 468 // Remplacement de la navigation -
extensions/piclens/include/default_values.inc.php
r3614 r3619 53 53 $piclens_default_values['piclens_bestrated_active'] = true; 54 54 $piclens_default_values['piclens_favorites_active'] = true; 55 $piclens_default_values['piclens_tags_active'] = true; 55 56 56 57 $piclens_default_values['piclens_wall_spec'] = false; // remplacement navigation image dans categories par le mur 3D … … 60 61 $piclens_default_values['piclens_wall_spec_bestrated'] = false; 61 62 $piclens_default_values['piclens_wall_spec_favorites'] = false; 63 $piclens_default_values['piclens_wall_spec_tags'] = false; 62 64 63 65 $piclens_default_values['piclens_wall_swflocal'] = false; // Flash swf local utilise pour le mur 3D (pas besoin du fichier crossdomain.xml mais pas de MAJ automatique du flash) … … 83 85 84 86 85 $piclens_default_values['piclens_rss_name'] = " %I2"; // Nom86 $piclens_default_values['piclens_rss_desc'] = " %I3"; // Description87 $piclens_default_values['piclens_rss_name'] = "Nom : %I2"; // Nom 88 $piclens_default_values['piclens_rss_desc'] = "(%I3)"; // Description 87 89 90 $piclens_default_values['piclens_exclude_double'] = false; // Suppression des doublons 88 91 ?> -
extensions/piclens/language/en_UK/plugin.lang.php
r3614 r3619 207 207 // Fin legende 208 208 209 $lang['piclens_tags_label'] = 'Tags'; 210 $lang['piclens_rsscfg_exclude_double'] = 'Suppress double picture in the feed (same path)'; 209 211 210 212 ?> -
extensions/piclens/language/fr_FR/plugin.lang.php
r3614 r3619 210 210 // Fin legende 211 211 212 $lang['piclens_tags_label'] = 'Tags'; 213 $lang['piclens_rsscfg_exclude_double'] = 'Suppression des doublons d\'image dans le flux (même répertoire d\'accès)'; 212 214 ?> -
extensions/piclens/main.inc.php
r3615 r3619 69 69 /* 0.3.6 --> Ajout parametres supplementaires du mur embeded */ 70 70 /* 0.4.0 --> Changement methode pour parametrer les noms et decriptions des images */ 71 /* Ajout integration piclens sur les tags */ 72 /* Ajout paramètre pour supprimer les doublons d'image dans le flux rss */ 71 73 72 74
Note: See TracChangeset
for help on using the changeset viewer.