Changeset 2779 for branches/2.0/template-extension/distributed
- Timestamp:
- Oct 19, 2008, 11:00:18 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.0/template-extension/distributed/samples/my-picture.tpl
r2479 r2779 1 1 {* $Id$ *} 2 <!-- This is a sample of template extensions --> 2 3 {if isset($errors)} 4 <div class="errors"> 5 <ul> 6 {foreach from=$errors item=error} 7 <li>{$error}</li> 8 {/foreach} 9 </ul> 10 </div> 11 {/if} 12 13 {if isset($infos)} 14 <div class="infos"> 15 <ul> 16 {foreach from=$infos item=info} 17 <li>{$info}</li> 18 {/foreach} 19 </ul> 20 </div> 21 {/if} 22 3 23 <div id="imageHeaderBar"> 4 24 <div class="browsePath"> 5 25 <a href="{$U_HOME}" rel="home">{'home'|@translate}</a> 6 { $LEVEL_SEPARATOR}{$SECTION_TITLE}26 {if !$IS_HOME}{$LEVEL_SEPARATOR}{$SECTION_TITLE}{/if} 7 27 {$LEVEL_SEPARATOR}{$current.TITLE} 8 28 </div> 29 <div class="imageNumber">{$PHOTO}</div> 30 {if $SHOW_PICTURE_NAME_ON_TITLE } 31 <h2>{$current.TITLE}</h2> 32 {/if} 9 33 </div> 10 34 … … 12 36 <div id="imageToolBar"> 13 37 <div class="randomButtons"> 38 {if isset($U_SLIDESHOW_START) } 39 <a href="{$U_SLIDESHOW_START}" title="{'slideshow'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/start_slideshow.png" class="button" alt="{'slideshow'|@translate}"></a> 40 {/if} 41 {if isset($U_SLIDESHOW_STOP) } 42 <a href="{$U_SLIDESHOW_STOP}" title="{'slideshow_stop'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/stop_slideshow.png" class="button" alt="{'slideshow_stop'|@translate}"></a> 43 {/if} 44 <a href="{$U_METADATA}" title="{'picture_show_metadata'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/metadata.png" class="button" alt="metadata" /></a> 45 {if isset($current.U_DOWNLOAD) } 46 <a href="{$current.U_DOWNLOAD}" title="{'download_hint'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/save.png" class="button" alt="{'download'|@translate}"></a> 47 {/if} 14 48 {if isset($PLUGIN_PICTURE_ACTIONS)}{$PLUGIN_PICTURE_ACTIONS}{/if} 49 {if isset($favorite) } 50 <a href="{$favorite.U_FAVORITE}" title="{$favorite.FAVORITE_HINT}"><img src="{$favorite.FAVORITE_IMG}" class="button" alt="favorite" title="{$favorite.FAVORITE_HINT}"></a> 51 {/if} 52 {if !empty($U_SET_AS_REPRESENTATIVE) } 53 <a href="{$U_SET_AS_REPRESENTATIVE}" title="{'set as category representative'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/representative.png" class="button" alt="{'representative'|@translate}"></a> 54 {/if} 55 {if isset($U_ADMIN) } 56 <a href="{$U_ADMIN}" title="{'link_info_image'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/preferences.png" class="button" alt="{'edit'|@translate}"></a> 57 {/if} 58 {if isset($U_CADDIE) }{*caddie management BEGIN*} 59 <script type="text/javascript"> 60 {literal}function addToCadie(aElement, rootUrl, id) 61 { 62 if (aElement.disabled) return; 63 aElement.disabled=true; 64 var y = new PwgWS(rootUrl); 65 66 y.callService( 67 "pwg.caddie.add", {image_id: id} , 68 { 69 onFailure: function(num, text) { alert(num + " " + text); document.location=aElement.href; }, 70 onSuccess: function(result) { aElement.disabled = false; } 71 } 72 ); 73 }{/literal} 74 </script> 75 <a href="{$U_CADDIE}" onclick="addToCadie(this, '{$ROOT_URL|@escape:'javascript'}', {$current.id}); return false;" title="{'add to caddie'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/caddie_add.png" class="button" alt="{'caddie'|@translate}"></a> 76 {/if}{*caddie management END*} 15 77 </div> 16 {include file= $FILE_PICTURE_NAV_BUTTONS}78 {include file='picture_nav_buttons.tpl'|@get_extent:'picture_nav_buttons'} 17 79 </div> <!-- imageToolBar --> 18 80 19 81 <div id="theImage"> 20 82 {$ELEMENT_CONTENT} 83 84 {if isset($COMMENT_IMG)} 85 <p>{$COMMENT_IMG}</p> 86 {/if} 87 88 {if isset($U_SLIDESHOW_STOP) } 89 <p> 90 [ <a href="{$U_SLIDESHOW_STOP}">{'slideshow_stop'|@translate}</a> ] 91 </p> 92 {/if} 21 93 22 94 </div>
Note: See TracChangeset
for help on using the changeset viewer.