Message-ID: <1217549047.13441.1406624095382.JavaMail.email@example.com> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_13440_1025175590.1406624095381" ------=_Part_13440_1025175590.1406624095381 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
Editablecontent module was born out of the recurring need to modify spec= ific textual segments. Most websites have "about", "privacy = policy", "what's new" etc. pages that contain largely textua= l content that is changed infrequently and often separate or after product = updates. Using a traditional, full-blown CMS for modifying the content is o= ften too cumbersome, as the CMS may not offer a suitable data API for pulli= ng the content out, the resource links (images etc.) may need to modified, = the CMS doesn't offer good enough performance for high volume read operatio= ns and/or the caches remain in stale state for too long. The answer is to m= odify the content on-line and in-place, backed by a database of your choice= . The editablecontent component allows you to simply surround a possibly ex= isting static text on a html page and make it editable with the right permi= ssions, automatically storing the edited contents in the database, with loc= alization support!
Here's how it looks like:
|When user is unauthenticat= ed||Content is being edited|
|When authenticated with th= e configured editor role|
An example page template:
The module uses HttpServletRequest.getRemoteUser() and Http= ServletRequest.isUserInRole(String role) for permission checks. Tapestry-security provide= s a built-in wrapper for handling these operations, but you don't h= ave to use tapestry-security with this module, instead you could e= asily provide your own advisor for HttpservletRequest if you like. The modu= le also keeps track of versions, however at the moment, there's no user int= erface for reverting to previous versions. Currently, JPA is the only persi= stence strategy implemented. For configuring JPA, see "Integrating with JPA", of Tapestry 5 documentation= .