General Actions:
Log-in
Register
Wiki:
Main wiki
▼
:
Document Index
»
Space:
Blog
▼
:
Document Index
»
Page:
Management
Search
default
Page Actions:
Export
▼
:
Export as PDF
Export as RTF
Export as HTML
More actions
▼
:
Print preview
View Source
Main wiki
»
The Wiki Blog
»
Manage blogs on this wiki
Wiki source code of
Manage blogs on this wiki
Last modified by
Administrator
on 2012/03/21 17:41
Content
·
Comments
(0)
·
Annotations
(0)
·
Attachments
(0)
·
History
·
Information
Show line numbers
{{include document="Blog.BlogCode"/}} {{velocity filter="none"}} {{html clean="false" wiki="true"}} #if($hasAdmin) ## ## ## List existing blogs. ## TODO: Display the number of articles in each blog ## TODO: Provide some management links: delete, edit title, configure... ## = $msg.get('xe.blog.manage.existing') = #foreach($item in $xwiki.wrapDocs($xwiki.searchDocuments(", BaseObject obj where obj.name = doc.fullName and obj.className = '$blogClassname'"))) #getBlogTitle($item $title) #if($title != '') * [[$title>>$item.fullName]] #else * [[$item.displayTitle>>$item.fullName]] <p/> #end #end ## ## ## New blog ## = $msg.get('xe.blog.manage.createnew') = #set($title = "$!request.blogTitle") #if($title != '') #set($space = "$!request.blogSpace") #if($space == '') #warning($msg.get('xe.blog.manage.nospace')) #else #if("$!request.blogType" == 'main') #set($blogDocName = "${space}.WebHome") #else #set($blogDocName = "${space}.Blog") #end #set($title = $escapetool.url($title)) #set($parent = 'Main.WebHome') $response.sendRedirect($xwiki.getURL($blogDocName, 'save', "parent=${parent}&title=${escapetool.url($title)}&template=${blogTemplate}&${blogClassname}_0_title=${escapetool.url($title)}&form_token=$!{request.getParameter('form_token')}")) #end #end ## ## Show the form <form action="${xwiki.getURL('Blog.Management')}" id="newBlog" method="post"> <div> <input type="hidden" name="form_token" value="$!{services.csrf.getToken()}" /> <dl> <dt><label for="blogSpace">$msg.get('xe.blog.manage.space')</label></dt> <dd><input type="text" name="blogSpace" id="blogSpace" value=""/></dd> <dt><label for="blogTitle">$msg.get('xe.blog.manage.title')</label></dt> <dd><input type="text" name="blogTitle" id="blogTitle" value="$msg.get('xe.blog.manage.blogtitle')"/></dd> <dt><label for="blogType">$msg.get('xe.blog.manage.blogtype')</label></dt> <dd><select name="blogType" id="blogType"> <option value="inner" selected="selected">$msg.get('xe.blog.manage.inside')</option> <option value="main">$msg.get('xe.blog.manage.main')</option> </select></dd> </dl> <input type="submit" value="${escapetool.xml($msg.get('xe.blog.manage.create'))}"/> </div> </form> #else ## !hasAdmin #xwikimessageboxstart($msg.get('error') $msg.get('notallowed')) #xwikimessageboxend() #end {{/html}} {{/velocity}}
Recent Blog Posts
First blog post
Blog Categories
News
(1)
Other
(0)
Personal
(0)
Blog Archive
2009
(1)