[2721] | 1 | |
---|
| 2 | {* Example of resizeable *} |
---|
| 3 | {* |
---|
| 4 | {include file='include/autosize.inc.tpl'} |
---|
| 5 | *} |
---|
| 6 | |
---|
[2227] | 7 | {if isset($errors)} |
---|
[2101] | 8 | <div class="errors"> |
---|
[2227] | 9 | <ul> |
---|
| 10 | {foreach from=$errors item=error} |
---|
| 11 | <li>{$error}</li> |
---|
| 12 | {/foreach} |
---|
| 13 | </ul> |
---|
[2101] | 14 | </div> |
---|
[2227] | 15 | {/if} |
---|
| 16 | |
---|
| 17 | {if isset($infos)} |
---|
[2101] | 18 | <div class="infos"> |
---|
[2227] | 19 | <ul> |
---|
| 20 | {foreach from=$infos item=info} |
---|
| 21 | <li>{$info}</li> |
---|
| 22 | {/foreach} |
---|
| 23 | </ul> |
---|
[2101] | 24 | </div> |
---|
[2227] | 25 | {/if} |
---|
[859] | 26 | |
---|
[2902] | 27 | {if !empty($PLUGIN_PICTURE_BEFORE)}{$PLUGIN_PICTURE_BEFORE}{/if} |
---|
| 28 | |
---|
[859] | 29 | <div id="imageHeaderBar"> |
---|
[1128] | 30 | <div class="browsePath"> |
---|
[5021] | 31 | <a href="{$U_HOME}" rel="Home">{'Home'|@translate}</a> |
---|
[2759] | 32 | {if !$IS_HOME}{$LEVEL_SEPARATOR}{$SECTION_TITLE}{/if} |
---|
[2227] | 33 | {$LEVEL_SEPARATOR}{$current.TITLE} |
---|
[1128] | 34 | </div> |
---|
[2227] | 35 | <div class="imageNumber">{$PHOTO}</div> |
---|
| 36 | {if $SHOW_PICTURE_NAME_ON_TITLE } |
---|
| 37 | <h2>{$current.TITLE}</h2> |
---|
| 38 | {/if} |
---|
[859] | 39 | </div> |
---|
| 40 | |
---|
| 41 | <div id="imageToolBar"> |
---|
[2218] | 42 | <div class="randomButtons"> |
---|
[2227] | 43 | {if isset($U_SLIDESHOW_START) } |
---|
[2257] | 44 | <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> |
---|
[2227] | 45 | {/if} |
---|
| 46 | {if isset($U_SLIDESHOW_STOP) } |
---|
[5021] | 47 | <a href="{$U_SLIDESHOW_STOP}" title="{'stop the slideshow'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/stop_slideshow.png" class="button" alt="{'stop the slideshow'|@translate}"></a> |
---|
[2227] | 48 | {/if} |
---|
[5293] | 49 | {if isset($U_METADATA) } |
---|
[5021] | 50 | <a href="{$U_METADATA}" title="{'Show file metadata'|@translate}" rel="nofollow"><img src="{$ROOT_URL}{$themeconf.icon_dir}/metadata.png" class="button" alt="metadata"></a> |
---|
[5293] | 51 | {/if} |
---|
[2227] | 52 | {if isset($current.U_DOWNLOAD) } |
---|
[5021] | 53 | <a href="{$current.U_DOWNLOAD}" title="{'download'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/save.png" class="button" alt="{'download'|@translate}"></a> |
---|
[2227] | 54 | {/if} |
---|
| 55 | {if isset($PLUGIN_PICTURE_ACTIONS)}{$PLUGIN_PICTURE_ACTIONS}{/if} |
---|
| 56 | {if isset($favorite) } |
---|
[2265] | 57 | <a href="{$favorite.U_FAVORITE}" title="{$favorite.FAVORITE_HINT}"><img src="{$favorite.FAVORITE_IMG}" class="button" alt="favorite" title="{$favorite.FAVORITE_HINT}"></a> |
---|
[2227] | 58 | {/if} |
---|
| 59 | {if !empty($U_SET_AS_REPRESENTATIVE) } |
---|
[5021] | 60 | <a href="{$U_SET_AS_REPRESENTATIVE}" title="{'representative'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/representative.png" class="button" alt="{'representative'|@translate}"></a> |
---|
[2227] | 61 | {/if} |
---|
| 62 | {if isset($U_ADMIN) } |
---|
[5021] | 63 | <a href="{$U_ADMIN}" title="{'edit'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/preferences.png" class="button" alt="{'edit'|@translate}"></a> |
---|
[2227] | 64 | {/if} |
---|
[2429] | 65 | {if isset($U_CADDIE) }{*caddie management BEGIN*} |
---|
| 66 | <script type="text/javascript"> |
---|
| 67 | {literal}function addToCadie(aElement, rootUrl, id) |
---|
| 68 | { |
---|
| 69 | if (aElement.disabled) return; |
---|
| 70 | aElement.disabled=true; |
---|
| 71 | var y = new PwgWS(rootUrl); |
---|
| 72 | |
---|
| 73 | y.callService( |
---|
| 74 | "pwg.caddie.add", {image_id: id} , |
---|
| 75 | { |
---|
| 76 | onFailure: function(num, text) { alert(num + " " + text); document.location=aElement.href; }, |
---|
| 77 | onSuccess: function(result) { aElement.disabled = false; } |
---|
| 78 | } |
---|
| 79 | ); |
---|
| 80 | }{/literal} |
---|
| 81 | </script> |
---|
[5021] | 82 | <a href="{$U_CADDIE}" onclick="addToCadie(this, '{$ROOT_URL|@escape:'javascript'}', {$current.id}); return false;" title="{'caddie'|@translate}"><img src="{$ROOT_URL}{$themeconf.icon_dir}/caddie_add.png" class="button" alt="{'caddie'|@translate}"></a> |
---|
[2429] | 83 | {/if}{*caddie management END*} |
---|
[2218] | 84 | </div> |
---|
[2759] | 85 | {include file='picture_nav_buttons.tpl'|@get_extent:'picture_nav_buttons'} |
---|
[859] | 86 | </div> <!-- imageToolBar --> |
---|
| 87 | |
---|
| 88 | <div id="theImage"> |
---|
[2227] | 89 | {$ELEMENT_CONTENT} |
---|
| 90 | |
---|
| 91 | {if isset($COMMENT_IMG)} |
---|
| 92 | <p>{$COMMENT_IMG}</p> |
---|
| 93 | {/if} |
---|
| 94 | |
---|
| 95 | {if isset($U_SLIDESHOW_STOP) } |
---|
[859] | 96 | <p> |
---|
[5021] | 97 | [ <a href="{$U_SLIDESHOW_STOP}">{'stop the slideshow'|@translate}</a> ] |
---|
[859] | 98 | </p> |
---|
[2227] | 99 | {/if} |
---|
| 100 | |
---|
[859] | 101 | </div> |
---|
| 102 | |
---|
[5293] | 103 | {if $DISPLAY_NAV_THUMB} |
---|
[2227] | 104 | {if isset($previous) } |
---|
[5021] | 105 | <a class="navThumb" id="linkPrev" href="{$previous.U_IMG}" title="{'Previous'|@translate} : {$previous.TITLE}" rel="prev"> |
---|
[2479] | 106 | <img src="{$previous.THUMB_SRC}" alt="{$previous.TITLE}"> |
---|
[859] | 107 | </a> |
---|
[2227] | 108 | {/if} |
---|
| 109 | {if isset($next) } |
---|
[5021] | 110 | <a class="navThumb" id="linkNext" href="{$next.U_IMG}" title="{'Next'|@translate} : {$next.TITLE}" rel="next"> |
---|
[2479] | 111 | <img src="{$next.THUMB_SRC}" alt="{$next.TITLE}"> |
---|
[859] | 112 | </a> |
---|
[2227] | 113 | {/if} |
---|
[5293] | 114 | {/if} |
---|
[859] | 115 | |
---|
[5207] | 116 | <table id="standard" class="infoTable" summary="{'Some info about this picture'|@translate}"> |
---|
[5304] | 117 | {if $display_info.author} |
---|
[5108] | 118 | <tr id="Author"> |
---|
[2227] | 119 | <td class="label">{'Author'|@translate}</td> |
---|
| 120 | <td class="value">{if isset($INFO_AUTHOR)}{$INFO_AUTHOR}{else}{'N/A'|@translate}{/if}</td> |
---|
[859] | 121 | </tr> |
---|
[5304] | 122 | {/if} |
---|
| 123 | {if $display_info.created_on} |
---|
[5108] | 124 | <tr id="datecreate"> |
---|
[2227] | 125 | <td class="label">{'Created on'|@translate}</td> |
---|
| 126 | <td class="value">{if isset($INFO_CREATION_DATE)}{$INFO_CREATION_DATE}{else}{'N/A'|@translate}{/if}</td> |
---|
[859] | 127 | </tr> |
---|
[5304] | 128 | {/if} |
---|
| 129 | {if $display_info.posted_on} |
---|
[5108] | 130 | <tr id="datepost"> |
---|
[2227] | 131 | <td class="label">{'Posted on'|@translate}</td> |
---|
| 132 | <td class="value">{$INFO_POSTED_DATE}</td> |
---|
[859] | 133 | </tr> |
---|
[5304] | 134 | {/if} |
---|
| 135 | {if $display_info.dimensions} |
---|
[5108] | 136 | <tr id="Dimensions"> |
---|
[2227] | 137 | <td class="label">{'Dimensions'|@translate}</td> |
---|
| 138 | <td class="value">{if isset($INFO_DIMENSIONS)}{$INFO_DIMENSIONS}{else}{'N/A'|@translate}{/if}</td> |
---|
[859] | 139 | </tr> |
---|
[5304] | 140 | {/if} |
---|
| 141 | {if $display_info.file} |
---|
[5108] | 142 | <tr id="File"> |
---|
[2227] | 143 | <td class="label">{'File'|@translate}</td> |
---|
| 144 | <td class="value">{$INFO_FILE}</td> |
---|
[859] | 145 | </tr> |
---|
[5304] | 146 | {/if} |
---|
| 147 | {if $display_info.filesize} |
---|
[5108] | 148 | <tr id="Filesize"> |
---|
[2227] | 149 | <td class="label">{'Filesize'|@translate}</td> |
---|
| 150 | <td class="value">{if isset($INFO_FILESIZE)}{$INFO_FILESIZE}{else}{'N/A'|@translate}{/if}</td> |
---|
[859] | 151 | </tr> |
---|
[5304] | 152 | {/if} |
---|
| 153 | {if $display_info.tags} |
---|
[5108] | 154 | <tr id="Tags"> |
---|
[2227] | 155 | <td class="label">{'Tags'|@translate}</td> |
---|
| 156 | <td class="value"> |
---|
| 157 | {if isset($related_tags)} |
---|
[2295] | 158 | {foreach from=$related_tags item=tag name=tag_loop}{if !$smarty.foreach.tag_loop.first}, {/if} |
---|
[2413] | 159 | <a href="{$tag.URL}">{$tag.name}</a>{/foreach} |
---|
[2227] | 160 | {/if} |
---|
| 161 | </td> |
---|
[859] | 162 | </tr> |
---|
[5304] | 163 | {/if} |
---|
| 164 | {if $display_info.categories} |
---|
[5108] | 165 | <tr id="Categories"> |
---|
[2227] | 166 | <td class="label">{'Categories'|@translate}</td> |
---|
[859] | 167 | <td class="value"> |
---|
[2227] | 168 | {if isset($related_categories)} |
---|
[859] | 169 | <ul> |
---|
[2227] | 170 | {foreach from=$related_categories item=cat} |
---|
| 171 | <li>{$cat}</li> |
---|
| 172 | {/foreach} |
---|
[859] | 173 | </ul> |
---|
[2227] | 174 | {/if} |
---|
[859] | 175 | </td> |
---|
| 176 | </tr> |
---|
[5304] | 177 | {/if} |
---|
| 178 | {if $display_info.visits} |
---|
[5108] | 179 | <tr id="Visits"> |
---|
[2227] | 180 | <td class="label">{'Visits'|@translate}</td> |
---|
| 181 | <td class="value">{$INFO_VISITS}</td> |
---|
[859] | 182 | </tr> |
---|
[5304] | 183 | {/if} |
---|
[2480] | 184 | |
---|
[5304] | 185 | {if $display_info.average_rate and isset($rate_summary) } |
---|
[5108] | 186 | <tr id="Average"> |
---|
[2594] | 187 | <td class="label">{'Average rate'|@translate}</td> |
---|
| 188 | <td class="value" id="ratingSummary"> |
---|
| 189 | {if $rate_summary.count} |
---|
| 190 | {assign var='rate_text' value='%.2f (rated %d times, standard deviation = %.2f)'|@translate } |
---|
| 191 | {$pwg->sprintf($rate_text, $rate_summary.average, $rate_summary.count, $rate_summary.std) } |
---|
| 192 | {else} |
---|
[5021] | 193 | {'no rate'|@translate} |
---|
[2594] | 194 | {/if} |
---|
| 195 | </td> |
---|
| 196 | </tr> |
---|
| 197 | {/if} |
---|
[2480] | 198 | |
---|
| 199 | {if isset($rating)} |
---|
[5108] | 200 | <tr id="rating"> |
---|
[2480] | 201 | <td class="label"> |
---|
[5178] | 202 | <span id="updateRate">{if isset($rating.USER_RATE)}{'Update your rating'|@translate}{else}{'Rate this picture'|@translate}{/if}</span> |
---|
[2480] | 203 | </td> |
---|
| 204 | <td class="value"> |
---|
| 205 | <form action="{$rating.F_ACTION}" method="post" id="rateForm" style="margin:0;"> |
---|
| 206 | <div> |
---|
| 207 | {foreach from=$rating.marks item=mark name=rate_loop} |
---|
| 208 | {if !$smarty.foreach.rate_loop.first} | {/if} |
---|
| 209 | {if isset($rating.USER_RATE) && $mark==$rating.USER_RATE} |
---|
[3185] | 210 | <input type="button" name="rate" value="{$mark}" class="rateButtonSelected" title="{$mark}"> |
---|
[2480] | 211 | {else} |
---|
[3185] | 212 | <input type="submit" name="rate" value="{$mark}" class="rateButton" title="{$mark}"> |
---|
[2480] | 213 | {/if} |
---|
| 214 | {/foreach} |
---|
[5123] | 215 | <script type="text/javascript" src="{$ROOT_URL}themes/default/js/rating.js"></script> |
---|
[2480] | 216 | <script type="text/javascript"> |
---|
| 217 | makeNiceRatingForm( {ldelim}rootUrl: '{$ROOT_URL|@escape:"javascript"}', image_id: {$current.id}, |
---|
[5178] | 218 | updateRateText: "{'Update your rating'|@translate|@escape:'javascript'}", updateRateElement: document.getElementById("updateRate"), |
---|
[2480] | 219 | ratingSummaryText: "{'%.2f (rated %d times, standard deviation = %.2f)'|@translate|@escape:'javascript'}", ratingSummaryElement: document.getElementById("ratingSummary") {rdelim} ); |
---|
| 220 | </script> |
---|
| 221 | </div> |
---|
| 222 | </form> |
---|
| 223 | </td> |
---|
| 224 | </tr> |
---|
| 225 | {/if} |
---|
| 226 | |
---|
[5304] | 227 | {if $display_info.privacy_level and isset($available_permission_levels) } |
---|
[5108] | 228 | <tr id="Privacy"> |
---|
[2594] | 229 | <td class="label">{'Privacy level'|@translate}:</td> |
---|
| 230 | <td class="value"> |
---|
| 231 | <script type="text/javascript"> |
---|
| 232 | {literal}function setPrivacyLevel(selectElement, rootUrl, id, level) |
---|
| 233 | { |
---|
| 234 | selectElement.disabled = true; |
---|
| 235 | var y = new PwgWS(rootUrl); |
---|
| 236 | y.callService( |
---|
| 237 | "pwg.images.setPrivacyLevel", {image_id: id, level:level} , |
---|
| 238 | { |
---|
[4513] | 239 | method: "POST", |
---|
[2594] | 240 | onFailure: function(num, text) { selectElement.disabled = false; alert(num + " " + text); }, |
---|
| 241 | onSuccess: function(result) { selectElement.disabled = false; } |
---|
| 242 | } |
---|
| 243 | ); |
---|
| 244 | }{/literal} |
---|
| 245 | </script> |
---|
| 246 | <select onchange="setPrivacyLevel(this, '{$ROOT_URL|@escape:'javascript'}', {$current.id}, this.options[selectedIndex].value)"> |
---|
| 247 | {foreach from=$available_permission_levels item=level} |
---|
| 248 | <option value="{$level}"{if $current.level==$level} selected="selected"{/if}>{$pwg->l10n($pwg->sprintf('Level %d',$level))}</option> |
---|
| 249 | {/foreach} |
---|
| 250 | </select> |
---|
| 251 | </td></tr> |
---|
| 252 | {/if} |
---|
| 253 | |
---|
[859] | 254 | </table> |
---|
| 255 | |
---|
[2227] | 256 | {if isset($metadata)} |
---|
[5112] | 257 | <table id="Metadata" class="infoTable2" summary="{'Some more (technical) info about this picture'|@translate}"> |
---|
[2227] | 258 | {foreach from=$metadata item=meta} |
---|
[5109] | 259 | <tr id="{$meta.TITLE}"> |
---|
[2227] | 260 | <th colspan="2">{$meta.TITLE}</th> |
---|
[859] | 261 | </tr> |
---|
[2227] | 262 | {foreach from=$meta.lines item=value key=label} |
---|
[5109] | 263 | <tr id="{$label}" > |
---|
[2227] | 264 | <td class="label">{$label}</td> |
---|
| 265 | <td class="value">{$value}</td> |
---|
[859] | 266 | </tr> |
---|
[2227] | 267 | {/foreach} |
---|
| 268 | {/foreach} |
---|
[859] | 269 | </table> |
---|
[2227] | 270 | {/if} |
---|
[859] | 271 | |
---|
| 272 | |
---|
| 273 | <hr class="separation"> |
---|
| 274 | |
---|
[2227] | 275 | {if isset($COMMENT_COUNT)} |
---|
[859] | 276 | <div id="comments"> |
---|
[2780] | 277 | {if $COMMENT_COUNT > 0} |
---|
| 278 | <h3>{$pwg->l10n_dec('%d comment', '%d comments',$COMMENT_COUNT)}</h3> |
---|
| 279 | {/if} |
---|
[3182] | 280 | {if !empty($navbar) }{include file='navigation_bar.tpl'|@get_extent:'navbar'}{/if} |
---|
[859] | 281 | |
---|
[2481] | 282 | {if isset($comments)} |
---|
[3445] | 283 | {include file='comment_list.tpl'} |
---|
[2481] | 284 | {/if} |
---|
[859] | 285 | |
---|
[2481] | 286 | {if isset($comment_add)} |
---|
| 287 | <form method="post" action="{$comment_add.F_ACTION}" class="filter" id="addComment"> |
---|
| 288 | <fieldset> |
---|
[5021] | 289 | <legend>{'Add a comment'|@translate}</legend> |
---|
[2481] | 290 | {if $comment_add.SHOW_AUTHOR} |
---|
[5021] | 291 | <label>{'Author'|@translate}<input type="text" name="author"></label> |
---|
[2481] | 292 | {/if} |
---|
[5178] | 293 | <label>{'Comment'|@translate}<textarea name="content" id="contentid" rows="5" cols="80">{$comment_add.CONTENT}</textarea></label> |
---|
[3185] | 294 | <input type="hidden" name="key" value="{$comment_add.KEY}"> |
---|
[2481] | 295 | <input class="submit" type="submit" value="{'Submit'|@translate}"> |
---|
| 296 | </fieldset> |
---|
| 297 | </form> |
---|
| 298 | {/if} |
---|
[1167] | 299 | </div> |
---|
[2227] | 300 | {/if} {*comments*} |
---|
[2205] | 301 | |
---|
[2352] | 302 | {if !empty($PLUGIN_PICTURE_AFTER)}{$PLUGIN_PICTURE_AFTER}{/if} |
---|