Wiki source code of Sandbox

Version 20.1 by Jip-jan Alunkel on maio 08, 18:23

Hide last authors
Jip-jan Alunkel 16.1 1
Jip-jan Alunkel 19.1 2 {{velocity}}
Jip-jan Alunkel 20.1 3 #if($xcontext.user != 'XWiki.XWikiGuest')
4 #if($request.xredirect)
Jip-jan Alunkel 19.1 5 $response.sendRedirect($request.xredirect)
6 #else
Jip-jan Alunkel 20.1 7 ## $response.sendRedirect($xwiki.getURL($services.model.resolveDocument('', 'default', $doc.documentReference.extractReference('WIKI'))))
Jip-jan Alunkel 19.1 8 #end
9 #elseif($doc.fullName != 'XWiki.XWikiLogin')
10 #set($qs = "$!{request.queryString}")
11 #if(!$request.getParameter('xredirect'))
12 #set($qs = "xredirect=$escapetool.url($doc.getURL('view'))&${qs}")
13 #end
14 $response.sendRedirect($xwiki.getURL('XWiki.XWikiLogin', 'login', $qs))
15 #else
Jip-jan Alunkel 18.1 16
Jip-jan Alunkel 19.1 17 ## Login page
18 ##template("startpage.vm")
19 ##<div class="main layoutsubsection">
20 ##<div id="mainContentArea">
21 <form id="loginForm" action="$doc.getURL('loginsubmit')" method="post" class="xform">
22 <input type="hidden" name="xredirect" value="$!{escapetool.xml($request.xredirect)}"/>
23 #if("$!request.srid" != '')
24 <input type="hidden" name="srid" value="$!escapetool.xml($request.srid)"/>
25 #end
26 <input type="hidden" name="form_token" value="$!{services.csrf.getToken()}"/>
Jip-jan Alunkel 18.1 27
Jip-jan Alunkel 19.1 28 #xwikimessageboxstart($services.localization.render('login') '')
29 #set($message = $xcontext.message)
30 #if($message)
31 <!-- previous login errors -->
32 #error($services.localization.render($message))
33 #end
34 #set($authFailureStrategyMessage = $services.security.authentication.getErrorMessage($request.j_username))
35 #if ("$!authFailureStrategyMessage" != '')
36 #error($authFailureStrategyMessage)
37 #end
38 #set ($supplementaryForm = $services.security.authentication.getForm($request.j_username))
39 <label for="j_username">$services.localization.render('username')</label>
40 #set ($forgotUsernameURL = $services.security.authentication.getAuthenticationURL('retrieveusername', $NULL))
41 #if("$!forgotUsernameURL" != "")
42 <span class="xAdditional"><a href="$forgotUsernameURL" tabindex="500">$services.localization.render('xe.admin.forgotUsername.loginMessage')</a></span>
43 #end
44 <span class="input-group">
45 <span class="input-group-addon">$services.icon.renderHTML('user')</span>
46 <input class="form-control" type="text" id="j_username" size="60" name="j_username" value="" tabindex="100"/>
47 </span>
48 <label for="j_password">$services.localization.render('password')</label>
49 #set ($resetPasswordUrl = $services.security.authentication.getAuthenticationURL('resetpassword', $NULL))
50 #if("$!resetPasswordUrl" != '')
51 <span class="xAdditional"><a href="$resetPasswordUrl" tabindex="600">$services.localization.render('xe.admin.passwordReset.loginMessage')</a></span>
52 #end
53 <span class="input-group">
54 <span class="input-group-addon">$services.icon.renderHTML('lock')</span>
55 <input type="password" id="j_password" size="60" name="j_password" value="" tabindex="200"/>
56 </span>
57 <label class="xHint" for="rememberme">
58 <input id="rememberme" type="checkbox" name="j_rememberme" value="true" tabindex="300"/> $services.localization.render('remembermeonthiscomp')
59 </label>
60 #if ("$!supplementaryForm" != "")
61 <div id="dedicated-auth-failures-field">
62 $supplementaryForm
63 </div>
64 #end
65 <input type="submit" class="btn btn-primary col-xs-12" value="$services.localization.render('login')" tabindex="400"/>
66 #xwikimessageboxend()
67 </form>
Jip-jan Alunkel 16.1 68
Jip-jan Alunkel 19.1 69 ## Ensure that the username field of the login form has the focus to make it easy for users to log in quickly
70 <script type="javascript">
71 //<![CDATA[
72 document.forms.loginForm.j_username.focus();
73 //]]>
74 </script>
75 #template("endpage.vm")
76 #end
77 {{/velocity}}
78
79
Jip-jan Alunkel 1.1 80 The sandbox is a part of your wiki that you can freely modify. It's meant to let you practice editing. You will discover how page editing works and create new pages. Simply click on **Edit** to get started!
81
82 {{info}}
83 Don't worry about overwriting or losing stuff when editing the page, you can always roll back to the first version of the page from the "History" tab at the bottom of the page.
84 {{/info}}
85
86 If you want to give a look to the underlying [[XWiki Syntax>>XWiki.XWikiSyntax]], you can click on "Wiki code" in the "Show" menu or click on the "Source" tab when editing the page.
87
88 Here are a number of test pages you can play with:
89
90 * [[Sandbox Test Page 1>>Sandbox.TestPage1]]
91 * [[Sandbox Test Page 2>>Sandbox.TestPage2]]
92 * [[Sandbox Test Page 3>>Sandbox.TestPage3]]
93
94 Below is a demonstration of the [[XWiki Syntax>>XWiki.XWikiSyntax]] you can use in wiki pages (headings, images, tables).
95
96 = Headings =
97
98 XWiki offers 6 levels of headings. You can use them to structure your pages.
99
100 == Level 2 Heading ==
101
102 === Level 3 Heading ===
103
104 ==== Level 4 Heading 4 ====
105
106 ===== Level 5 Heading 5 =====
107
108 ====== Level 6 Heading 6 ======
109
110 = Styles =
111
112 Basic styles are supported in XWiki:
113
114 * **Text in Bold**
115 * //Text in Italics//
116 * __Text in Underline__
117 * --Text in Strikethrough--
118 * Text in ,,subscript,,
119 * Text in ^^superscript^^
120
121 = Lists =
122
123 You can create various types of lists in your wiki pages:
124
125 == Unordered list ==
126
127 * Level 1
128 ** Level 2
129 *** Level 3
130 ** Level 2
131 * Level 1
132
133 == Numbered list ==
134
135 1. Item
136 11. Subitem
137 111. Item
138 1. Subitem
139
140 == Mixed list ==
141
142 1. Item 1
143 11. Item 2
144 11*. Item 3
145 11*. Item 4
146 1. Item 5
147
148 = Tables =
149
150 You can create tables right into wiki pages:
151
152 == Table with headers in the top row ==
153
154 |= table header |= table header |= table header
155 | cell | cell | cell
156 | cell | cell | cell
157
158 == Table with headers in the top row and left column ==
159
160 |= table header |= table header |= table header
161 |= table header | cell | cell
162 |= table header | cell | cell
163
164 = Links =
165
166 XWiki allows you to create links to other pages in your wiki or on the web:
167
168 * [[WebHome]] -> links to the homepage of the current space
169 * [[Sandbox Home>>WebHome]] -> links can have labels
170 * [[Wiki Home>>Main.WebHome]] -> a link can use the SpaceName.PageName format to link to a page located in another space
171 * [[http://www.xwiki.org]] -> you can link to wiki pages or to external websites
172 * [[XWiki.org Website>>http://www.xwiki.org]] -> link labels work for exernal links too
173
174 You can also create links to attachments:
175
176 attach:XWikiLogo.png
177
178 = Images =
179
180 You can insert images in your wiki pages:
181
Jip-jan Alunkel 13.1 182 [[image:XWikiLogo.png]]
Jip-jan Alunkel 1.1 183
184 = Macros =
185
186 Macros allow you to make wiki content look better and to add additional features to your wiki. Here are 2 examples of how macros can be used in wiki pages:
187
188 == Warning Macro ==
189
190 This macro allows you to draw users' attention to a specific piece of information:
191
192 == Table of Contents ==
193
194 This macro automatically generates a table of contents of your wiki page based on headings:
195
196 {{toc/}}