Photo Album Class Sheet
Log-in
|
XWiki
:
WebHome
>
Welcome to the Class Editor
>
PhotoAlbumClass
>
Photo Album Class Sheet
Top Menu
Show
:
Comments
Attachments
History
Information
Stampa
:
Stampa
Anteprima di stampa
Esporta come PDF
Esporta in formato RTF
Esporta come HTML
Esporta in formato XAR
Wiki source code of
Photo Album Class Sheet
Show line numbers
#set($obj = $doc.getObject("XWiki.PhotoAlbumClass", 0)) #if(!$obj) ## String type is more specific than Object type. We should avoid ambiguous method call ## see http://java.sun.com/docs/books/jls/clarifications-2-2nd-ed.html (JLS 15.12.2.2) #set($obj = "") #end <br /> 1 $doc.display("title", $obj) $doc.display("description", $obj) #if($context.action != "inline") #set($diapo = $request.get("diapo")) #if(!$diapo) #set($diapo="all") #end #if($diapo=="all") #macro(photosAlbum2 $height) #set($current = 0) #foreach ($attach in $doc.attachmentList) #set($current = $current + 1) <a href="$doc.getURL("view","diapo=$current")" > <img src="$doc.getAttachmentURL($attach.filename, "download", "height=${height}")" height="${height}" alt="photo ${current}" /> </a> #end #end ## Compute the size of the thumbnails. If there’s no height property specified default to 150 #if(!$obj.getProperty("height")) #set($height = 150) #else #set($height = $doc.display("height", "view", $obj)) #end #photosAlbum2($height) #else #set($current = 0) #set($height = 400) #foreach ($attach in $doc.attachmentList) #set($current = $current + 1) #set($scurrent = "$current") #if("$diapo" == "$current") #set($prev = ($current - 1)) #set($next = ($current + 1)) <a href="$doc.getAttachmentURL($attach.filename,"download")" > <img src="$doc.getAttachmentURL($attach.filename, "download", "height=${height}")" height="${height}" /> </a> #end #end #if($prev==0) #set($prev = $doc.attachmentList.size()) #end #if($next==$doc.attachmentList.size()+1) #set($next = 1) #end #if(!$prev) #set($prev = 1) #set($next = 1) #end <br /> ~~[Previous Photo>${doc.name}?diapo=$prev] [Next Photo>${doc.name}?diapo=$next]~~ #end <br /> ~~<a href="$doc.getURL("attach")">Add Photos</a> <a href="$doc.getURL("inline")">Modify the Album</a> [All Photos>${doc.name}?diapo=all] [Diaporama>${doc.name}?diapo=1]~~ #end #set($showattachments = 0)
Search
Quick Links
Wiki Dashboard
Document Index
Blog
Sandbox
My Recent Modifications
dany
|
marco