Hi,
within an application we are using the binding framework (Cocoon 2.1.8) to
bind a form to a very simple value object (which is someting similar to a
bookmark, i.e. a id and a title field. The form is prefilled by application
like this
var code= cocoon.parameters.code;
var title = cocoon.parameters.title;
var bookmark = new Packages.mypackage.Bookmark();
bookmark.setCode(code);
if (cocoon.log.isDebugEnabled()) {
cocoon.log.debug("[addBookmark()] Title: " + title);
}
bookmark.setTitle(title);
if (cocoon.log.isDebugEnabled()) {
cocoon.log.debug("[addBookmark()] Bookmark Title: "
+ bookmark.getTitle());
}
form.load(bookmark);
form.showForm("addBookmark-form");
form.save(bookmark);
if (cocoon.log.isDebugEnabled()) {
cocoon.log.debug("[addBookmark()] Bookmark Title: "
+ bookmark.getTitle());
}
If the string stored in variable title contains special characters (e.g.
– or –) they are gone after saving the form. I.e. the first two
debug messages are displayed correctly whereas the third debug message
contains a ? whereever a ndash occurs in the original text. The text is
displayed correctly within the form input field as well. This might be a
encoding problem. Can anybody help me?
The binding is very simple:
<fb:context xmlns:fb="http://apache.org/cocoon/forms/1.0#binding" path="/">
<fb:value id="code" path="code"/>
<fb:value id="title" path="title"/>
</fb:context>
Any help appreciated,
Kai
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]