« 返回到 Portlets

Wiki Portlet

Introduction #

Liferay includes in its bundle a portlet that allows creation of contents in the Wiki collaboration style. The Wiki Wiki concept was invented by Ward Cunningham and has seen since then lots of different implementations.

Nodes #

Liferay allows the organization of pages in groups called nodes. Each node acts as a whole wiki with its own set of permissions, recent changes list and listing of all pages.

With the introduction of the new permissions system in Liferay 4, the Wiki was gained a very powerful functionality that allows you either to use the wiki in the traditional way (open to anyone) or use it also as a tool to organize private information to certain organizations, locations or groups of people.

A node is created by clicking on the Add node button and filling the title and optionally the description. After creating a node an initial page called FrontPage is automatically created and can be edited clicking on the 'Edit Page' link in the bottom of the wiki window.

To create new pages you have to edit an existing page and use the CamelCase syntax as described next to create a link to the new page. Until the page is created instead of being converted to a link, the name of the new page will be preceeded by a question mark. Clinking on the question mark will create the page. Once it is created the page can be edited regularly and its name on the originating page will be converted to a link. Please note : This does not work inside the HTML Editor.

Editing modes #

Liferay wiki comes with three editing modes: Creole, HTML, and Classic.

Creole #

Creole was a syntax that came about through a growing dissatisfaction in the Wiki community of a non-standard language. Headed by Ward Cunningham, who invented the Wiki technology with C2, the Creole design team believed that "... markup should be easy to learn and easy to teach, as well as fast to type and should use readable markup which is non-destructive" (see article).

Creole syntax has been added into the suite of Wiki languages supported by Liferay since version 5.0. Some examples of its basic syntax include:

Text Styles

//italics//
**bold**

Headers

== Large heading ==
=== Medium heading ===
==== Small heading ===

Links

[[Link to a page]]
[[http://www.liferay.com|Link to website]]

Lists

* Item
** Subitem
# Ordered Item
## Ordered Subitem

Images

{{attached-image.png}}
{{Page Name/other-image.jpg|label}}

In-line CSS injection(Note: this is not officially part of the Creole 1.0 specification, but it works because Liferay's wiki is based on the JSPWiki engine. Used it only if you absolutely must)

%%(color:red) red%%  %%(color:blue)blue%%  %%(color:green)green%%

%%(color:red) red%% %%(color:blue)blue%% %%(color:green)green%%

%%(text-align:center)
**This line is centered**
%%

%%(text-align:center) This line is centered %%
Tables with more complex CSS injection:

||%%(text-align:left;display:block;)Left Heading%% ||%%(text-align:center;display:block;)Center Heading%% 
(break added for readability) ||%%(text-align:right;display:block;)Right Heading%%
|%%(text-align:left;display:block;)Left Cell 11%% |%%(text-align:center;display:block;)Center Cell 12%% 
(line break added for readability) |%%(text-align:right;display:block;)Right Cell 13%%
|%%(text-align:left;display:block;)Left Cell 21%% |%%(text-align:center;display:block;)Center Cell 22 
(line break added for readability) (longer for illustration)%% |%%(text-align:right;display:block;)Right Cell 23%%
|%%(text-align:left;display:block;)left%% |%%(text-align:center;display:block;)center%% 
(line break added for readability)|%%(text-align:right;color:red;display:block;)combine alignment and color%% 
%%(text-align:left;display:block;)Left Heading%% %%(text-align:center;display:block;)Center Heading%% %%(text-align:right;display:block;)Right Heading%%
%%(text-align:left;display:block;)Left Cell 11%% %%(text-align:center;display:block;)Center Cell 12%% %%(text-align:right;display:block;)Right Cell 13%%
%%(text-align:left;display:block;)Left Cell 21%% %%(text-align:center;display:block;)Center Cell 22 (longer for illustration)%% %%(text-align:right;display:block;)Right Cell 23%%
%%(text-align:left;display:block;)left%% %%(text-align:center;display:block;)center%% %%(text-align:right;color:red;display:block;)combine alignment and color%%

Other

<<TableOfContents>>
{{{ Preformatted }}}

For full syntax rules can be found at the Creole 1.0 spec.

HTML #

In this mode the text area incorporates an embedded HTML editor (by default FCKEditor) that allows the user to write the document in a WYSIWYG similar to how they work in Ms Word or Open Office (although somewhat more limited, of course).

Please note: When switching back and forth from Creole to HTML the format will not be converted automatically. You'll have to do it manually.

Classic #

The classic editing mode is the most usual for wikis and uses text conventions to format the text. The text is later converted to HTML to be presented. Liferay uses the Friki engine to do this conversion. It's syntax is described in:

This syntax is inspired and pretty much the same to that of the original Wiki. Documentation about that syntax can be found in:

Links are created by writting two or more words together (without spaces between them) and uppercasing the first letter of each of the words. This is known as CamelCase syntax.

 LinkExample

To create monospaced text write a blank or more spaces at the beginning of the line

 {{{   This would be converted to monospaced font}}}

To write italics put two single quotes at the beginning and at the end of the text

 {{{''italics''}}}

To write bold put three single quotes at the beginning and at the end of the text

 {{{'''bold'''}}}

Four dashes by themselves on a single text line create an horizontal line

 ----

Classic (Enhanced in 4.3.1+) #

While awaiting the integration of an alternative wiki engine (as has been discussed and often requested), we've made a few changes for the 'Classic Wiki' mode such that it's usability and familiarity should be much greater.

Instead of going the 'Classic Wiki' syntax direction, we've taken this 'Enhanced' version in the MediaWiki direction.

Here is a snapshot of the rules as they are now:

Added Media Wiki style internal links

 [ Page Name | Link Text ]

Features not shown are the same as they were.

References #

Image Gallery is one of Liferay's Out of The Box Portlets

0 附件
135230 查看
平均 (2 票)
满分为 5,平均得分为 1.5。
评论
讨论主题回复 作者 日期
How can I remove FRONT PAGE from each wiki... K Pink 2009年4月10日 上午11:37
Same question... Dmitry Babain 2009年5月29日 上午1:47
I used redirection for that purpose. Lorinc Nyitrai 2009年8月6日 上午7:14
It seems that it is not possible to switch back... Per Spilling 2009年6月11日 上午10:43
see http://issues.liferay.com/browse/LPS-5221 Claas Ruschmeyer 2009年10月3日 上午1:45
Is there a reason why the replies are not... Corné Aussems 2010年1月22日 上午1:36
I miss the fearure that makes all Wikis... Lorinc Nyitrai 2009年8月6日 上午7:11
Thank you, Brian. Helpful Wiki article. Jonas Yuan 2009年8月28日 下午5:07
Is there a way to link from one wiki page to... Robin Mitra 2010年2月17日 上午8:09
Found it by mistake! When adding a link, select... Robin Mitra 2010年2月17日 上午8:12
<a href="http://www.google.com/"... Alexia Biggs 2010年2月28日 下午5:26
Dear Team, it's is possible to keep the Revert... Senthil Chockalingam 2010年6月29日 上午2:18
how can i subscribe wiki for email notification... pooja shah 2010年8月4日 下午11:37
Is there anyway to change some settings to make... Puj Z 2010年8月31日 上午5:52
How can i remove "Front Page" heading from the... Sravani M 2010年11月5日 下午9:06
how can i give users the option to create new... Mohammed Azam 2010年11月25日 下午11:40
Is there a way to filter out, and view only... Ryan Paul Schultz 2011年1月20日 上午11:39
Liferay 6.0.6 CE - can't find Classic formats.... Vladimir Vladimirovich Druzenko 2011年8月7日 上午5:38
How does one implement Captcha in the Wiki? Bob Lyman 2011年9月1日 下午12:31
test Krishna Gadde 2011年9月22日 上午6:00
We have now invested 6 months in building an... Christine Sætre 2011年11月10日 上午2:54
How to zero-rise the "Views" for each page? sherry quik 2011年12月21日 上午7:50
good article Manikandan S 2012年1月10日 上午3:23
any body know how to make a backup and restore... enzo acosta 2014年1月31日 上午3:51

How can I remove FRONT PAGE from each wiki page?
thanks
在 09-4-10 上午11:37 发帖。
在 09-5-29 上午1:47 发帖。
It seems that it is not possible to switch back and forth between Creole and HTML editing mode in the Wiki Portlet. Is this a bug or a feature?
在 09-6-11 上午10:43 发帖。
I miss the fearure that makes all Wikis structured: the Category page. I suppose that the Child page feature is intended to be its replacement.
在 09-8-6 上午7:11 发帖。
I used redirection for that purpose.
在 09-8-6 上午7:14 发帖以回复 Dmitry Babain
Thank you, Brian.

Helpful Wiki article.
在 09-8-28 下午5:07 发帖。
see http://issues.liferay.com/browse/LPS-5221
在 09-10-3 上午1:45 发帖以回复 Per Spilling
Is there a reason why the replies are not hierarchical like MessageBoard?
在 10-1-22 上午1:36 发帖以回复 Claas Ruschmeyer
Is there a way to link from one wiki page to another by using the html FCKeditor? I couldn't find a way to do it.
在 10-2-17 上午8:09 发帖。
Found it by mistake! When adding a link, select "other" as the protocol and enter the page name in the url field. Simple enough!
在 10-2-17 上午8:12 发帖以回复 Robin Mitra
<a href="http://www.google.com/" rel="dofollow">nice</a>
在 10-2-28 下午5:26 发帖以回复 Robin Mitra
Dear Team,

it's is possible to keep the Revert option for Only for Admin(Owner)?
this.emoticonemoticon
在 10-6-29 上午2:18 发帖以回复 Alexia Biggs
how can i subscribe wiki for email notification (for updates or changes in wiki)
在 10-8-4 下午11:37 发帖以回复 Senthil Chockalingam
Is there anyway to change some settings to make the wiki content right-to-left for languages like Arabic?
在 10-8-31 上午5:52 发帖。
How can i remove "Front Page" heading from the wiki portlet.
在 10-11-5 下午9:06 发帖。
how can i give users the option to create new page add edit etc
在 10-11-25 下午11:40 发帖。
Is there a way to filter out, and view only those Wikis that you have either started, or edited in the past? Similar to viewing 'My Documents'.
在 11-1-20 上午11:39 发帖以回复 mohammed azam
Liferay 6.0.6 CE - can't find Classic formats. Only Creole and HTML.
Where is it?
在 11-8-7 上午5:38 发帖。
How does one implement Captcha in the Wiki?
在 11-9-1 下午12:31 发帖。
在 11-9-22 上午6:00 发帖。
We have now invested 6 months in building an enterprise wiki, using Creol wiki (with WYSIWYG). Problem is we have now discovered a number of number of bugs that make launch impossible.
(1) Wish we had known that you can't link to email addresses! This has to be an option even in the simplest web page, and works in Creol, but not in Liferay. If it does I haven't found any information on what we might have done wrong locally.
(2) Line breaks don't work as specified above;
(3) Permalinks anchors after headings link to the incorrect page if an internal link precedes them.
(4) ... and it is increasingly hard to find clear information on fix it yourself options or potential relief from these issues. http://bit.ly/sWIhbz
One JIRA post from Vincent Lu (http://bit.ly/tyP9v0) says "... removing the Creole Filter JAR from the Liferay Portal distribution in favor for the creole implementation from JSPWiki might solve the problems ..." but there is no further information from the community or on Liferay.com about this operation or other things one can try.
We like the Liferay product, but these latest issues are pretty frustrating.
在 11-11-10 上午2:54 发帖。
How to zero-rise the "Views" for each page?
在 11-12-21 上午7:50 发帖。
在 12-1-10 上午3:23 发帖以回复 sherry quik
any body know how to make a backup and restore of a wiki in liferay.
在 14-1-31 上午3:51 发帖。