General Actions:
Log-in
Wiki:
CreativeIT
▼
:
Document Index
»
Space:
BBCode
▼
:
Document Index
»
Page:
TopicAClassSheet
Search
Page Actions:
Export
▼
:
Export as PDF
Export as RTF
Export as HTML
More actions
▼
:
Print preview
View Source
TopicAClassSheet
Wiki source code of
TopicAClassSheet
Last modified by
Holger Dick
on 2009/04/20 10:21
Content
·
Comments
(0)
·
Attachments
(0)
·
History
·
Information
Show line numbers
#set ($showcomments = "no") <style type="text/css"> #includeTopic('BBCode.SkinA') </style> {pre} <script type="text/javascript"> function quote(id) { $('BBCode.PostClass_postcontent').value = "-quote:"+id+"-" + $('BBCode.PostClass_postcontent').value; } function setquote() { var s = $('BBCode.PostClass_postcontent').value var matches = s.match(/-quote:message[0-9]*-/); for (var i=0; i < matches.length; i++) { var oldmatch = matches[i]; var newmatch = matches[i].replace(/-quote:(message[0-9]*)-/, "$1"); s = s.replace(oldmatch, "<blockquote>" + $(newmatch).innerHTML + "</blockquote>"); } $('BBCode.PostClass_postcontent').value = s; return false; //return cancelCancelEdit(); } </script> {/pre} #if($request.parent && $request.parent!="") #set($parent=$request.parent) #else #set($parent=$doc.parent) #end <input type="hidden" name="parent" value="$parent" /> #set($class = $doc.getObject("BBCode.TopicClass").xWikiClass) <input type="hidden" name="title" value="" /> #if ($context.action == 'inline') $msg.bb_entertopictitle<br /> $doc.display('topictitle') $msg.bb_entertopicdescription<br /> $doc.display('topicdescription') #template('tagedit.vm') #set($newtopictitle = $request.nicetopictitle) #if($newtopictitle) #set($newtopictitle = $newtopictitle.replaceAll('"',"'")) <script type="text/javascript"> var nicetopictitle = "${newtopictitle}"; {pre} document.forms.inline["BBCode.TopicClass_0_topictitle"].value = nicetopictitle; document.forms.inline["title"].value = nicetopictitle; {/pre} </script> #end #if($doc.isNew() == 'false') #set($title = $doc.getValue('topictitle', $doc.getObject('BBCode.TopicClass'))) <script type="text/javascript"> var nicetopictitle = "${title}"; {pre} document.forms.inline["title"].value = nicetopictitle; {/pre} </script> #end #else #set($postindex = 0) 1.1.1.1 $xwiki.getUserName($doc.fullName, false)'s Wall <table class="topictable"> #set($postclass = $doc.getObjects('BBCode.PostClass')) <tr> <td colspan="2"> <span class="bbdatatext"> $postclass.size() entries on the wall </span> </td> </tr> #if ($postclass.size() == 0) <tr class="evenpost"><td colspan=2><h4>No one has written on $xwiki.getUserName($doc.fullName, false)'s wall yet. Be the first to write on this wall!</h4></td></tr> #else #foreach($item in $postclass) #set ($postauthor = $xwiki.getUserName($doc.display('postauthor', $item), true)) #if ($doc.getValue('postcontent', $item) != '') #set ($postindex = $postindex + 1) <tr class="#if($postindex % 2 == 0) evenpost #else oddpost #end"> <td id="posttd"> #set ($localpostauthor = $doc.display('postauthor', $item)) #set ($index = $localpostauthor.indexOf(":")) #set ($index = $index + 1) #set ($localpostauthor = $localpostauthor.substring($index)) <div class="avatar"> <a href="$xwiki.getURL($localpostauthor)"> #useravatar($localpostauthor) </a> </div></td> <td id="posttd"> <div id="message$item.number"> <span class="bbdatatext"> <a name=$postindex href="#$postindex">$postindex</a> - $msg.Posted on $doc.display('postdate', $item) by $postauthor | <a href="#postmessage" onclick="quote('message$item.number')"> $msg.Quote this post </a> | #if($context.user == $doc.display('postauthor', $item) || $xwiki.hasAdminRights() == 'true' || $context.user == $doc.getCreator()) <a class="red" href="$doc.getURL("objectremove", "classname=BBCode.PostClass&classid=${item.number}&xredirect=${request.getRequestURL()}")">$msg.Delete Post</a> #end #end </div> <div class="postcontent"> $doc.display('postcontent', $item) </div> </td> </tr> #end #end <tr> <td colspan=2> #if ($context.user == 'XWiki.XWikiGuest') <span class="bbdatatext"> $msg.bb_needloginmessage </span> #else #set ($lastpostid = $postclass.size() + 1) <span class="bbsmalltitle"> <a name=postmessage href="#postmessage"> $msg.Post Message </a> </span> <form method="post" action="$doc.getURL("objectadd")" onsubmit="setquote();"> <input type="hidden" name="xredirect" value="$doc.getURL()#$lastpostid" /> <input type="hidden" name="classname" value="BBCode.PostClass" /> <input type="hidden" name="BBCode.PostClass_postauthor" value="$context.user" /> <textarea rows="10" cols="65" id="BBCode.PostClass_postcontent" name="BBCode.PostClass_postcontent" /></textarea><br /> <input type="submit" value="Write on the wall" /> </form> #end </td> </tr> </table> #end
Quick Links
Home
Index
What's New
Blog
Calendar
Photo Albums
Sandbox
Tags
Bulletin Board
My Recent Modifications
PamelaJennings
|
rwakkary
|
HaledenSands
|
ByronLahey