Hi everybody,
I have added a bit of example code on the date picker application page
on xwiki.org, hopefully someone will find it useful.
http://code.xwiki.org/xwiki/bin/view/Applications/DatePickerApplication
Dean Sellers applications engineer
rinstrum smart weighing
Ph: +61 7 3216 7166 Fax: +61 7 3216 6211
dean.sellers(a)rinstrum.com
41 Success St, Acacia Ridge, QLD, 4110
www.rinstrum.com
Hi,
On Fri, Apr 17, 2009 at 1:58 PM, Marius Dumitru Florea <
mariusdumitru.florea(a)xwiki.com> wrote:
> Hi Jonas
>
> Jonas Almfeldt wrote:
> [snip]
>
>> Where can I find those templates? in the .war file or in the database?
>>
>
> Yes, in the war, in templates directory. Have you changed editwysiwygnew.vm
> or wysiwyginput.vm?
>
No haven't.
I have now deployed the same .war file in both environments and the instance
running in Tomcat works fine with the rendering in the wysiwyg editor, but
the instance running in WAS environment does not. :-(
> [snip]
>
>> This means the XWiki syntax is no converted to XHTML before loading
>> the editor. Can you try a simpler example just to be sure? For
>> instance to this:
>>
>> * edit a new/empty page
>> * type a word like "bug"
>> * select the word
>> * click the bold button on the tool bar
>> * save and edit again
>>
>> Do you get **bug** in the WYSIWYG editor? If so, then cancel the
>> edit. The "bug" is in bold in view mode right? Then please append
>> "xpage=wysiwyginput" to the query string of your URL and tell me the
>> output. For instance:
>>
>> http://localhost:8080/xwiki/bin/view/Sandbox/Test?xpage=wysiwyginput
>>
>> I suspect the output is **bug** right?
>>
>>
>> Yes, the output is: **bug**\\
>>
>>
>> Now if you append also "render" like in:
>>
>>
>> http://localhost:8080/xwiki/bin/view/Sandbox/FF?xpage=wysiwyginput&render
>> <
>> http://localhost:8080/xwiki/bin/view/Sandbox/FF?xpage=wysiwyginput&render
>> >
>>
>> is the "bug" in bold?
>>
>>
>> No :-( the output of ...?xpage=wysiwyginput&render is still: **bug**\\
>>
>
> Can you try this:
>
> * edit a NEW page with the Wiki editor and past this content:
>
> -----8<-----
> {{velocity}}
> #set($mydoc = $xwiki.getDocument("Sandbox.FF"))
> $mydoc.getRenderedContent($mydoc.content, $mydoc.syntaxId)
> {{/velocity}}
> ----->8-----
>
> * replace Sandbox.FF with the space and the page where you wrote **bug**.
> Save and view. What does it display? I get:
>
> <p><strong>bug</strong></p>
>
I also get:
<p><strong>bug</strong></p>
>
>> Some additional details:
>> The WAS 6.1 jvm has java version 1.5.0 btw.
>> My local Tomcat runs with the JRE of jdk1.5.0_08.
>>
>> I also forgot to mention to the list that this problem is not specific to
>> 1.8.1. It happens when I test with 1.8 also. (same wiki db content used,
>> created with 1.8 stable and the 1.8 XAR archive as a base).
>>
>> [snip]
>
> Thanks,
> Marius
>
Hi again,
In making an edit on xwiki.org I noticed some strange behaviour and I am
hoping someone can help me solve it, or at least explain it.
What I wanted to do was post an example that involved some javascript
with a literal array inside, like:
dateFormat : {pre}[["dd","mm","yyyy"],"/"]{/pre}
So to include this in the page you would use
{code}
dateFormat : {pre}[["dd","mm","yyyy"],"/"]{/pre}
{code}
It appears though the the {pre} tags break the {code} macro, is there a
workaround or something I am missing here?
Dean Sellers applications engineer
rinstrum smart weighing
Ph: +61 7 3216 7166 Fax: +61 7 3216 6211
dean.sellers(a)rinstrum.com
41 Success St, Acacia Ridge, QLD, 4110
www.rinstrum.com
Hi list,
I have a really weird bug which is quite annoying and I don't find any
solution to it :
I want to edit a page in inline mode. I have a form to select the page
to edit with a button. I use the $xwiki.getURL() method to get the right
URL. When i select my page and click on the edit button, I have an
invalid URL error and i am deconnected. What is weird is that if I
reconnect and actualize the page I can access it. The second weird thing
is that I use exactly the same method to edit other pages form other
forms in the same first page and I do not have the problem. I am quite
lost with this issue. I tried to recreate the URL as a string but I have
the same problem.
I am thinking maybe this is a known bug in xwiki. If not maybe i am
missing something somewhere. Please open my eyes on the obvious i am
missing in my code :
<FORM method=POST action="">
<input type="hidden" name="backlog" value="${backlogId}" />
<input type="hidden" name="webname" value="Project" />
<input type="hidden" name="name" value="backlog" />
<input type="hidden" name="domain" value="${domainId}" />
<input type="hidden" name="cut" value="${cut}" />
Select topic : <SELECT name="topic">
#foreach ($item in $topiclist)
#set
($topic=$xwiki.getDocument(${item}).getObject("XWiki.TopicClass"))
<OPTION VALUE="${topic.id}">$topic.get("name")</OPTION>
#end
</SELECT>
<input type="button" value="Select"
onclick='{this.form.action="../../view/" + this.form.webname.value + "/"
+ this.form.name.value + "?backlog=" + this.form.backlog.value +
"&domain=" + this.form.domain.value + "&topic=" +
this.form.topic.value.substring(this.form.topic.value.lastIndexOf("${separator}")+1)
+ "&cut=" + this.form.cut.value; this.form.submit(); }'/>
<input type="button" value="Edit"
onclick='{url="Project."+this.form.topic.value;
this.form.action="${xwiki.getURL(url, "inline")}"; this.form.submit(); }' />
</FORM>
Note that the problem is only with the Edit button, the other is working
fine.
Thanks in advance for your help.
Jean.
--
----
Jean Couteau
Code Lutin - http://www.codelutin.com
44 Bd des Pas Enchantés - 44230 St-Sébastien/Loire
Tél : 02 40 50 29 28 - Fax : 09 59 92 29 28
Hi,
I am using XWiki with external database with my own data. I am using SQL plugin.
When I run this simple script:
------------------------------------------------------------------------
#set ($mydb=$xwiki.sql.getDatabase("jdbc/xwiki_conference"))
$mydb.executeUpdate("UPDATE table SET title = 'ěščřžýáí' WHERE id = 1");
------------------------------------------------------------------------
- I get "?š??žýáí" saved in the database.
My web.xml and xwiki.cfg are set to UTF-8, database has utf8_general_ci as encoding.
What else should I change to save the characters properly?
--
View this message in context: http://n2.nabble.com/Encoding-problem-with-external-database-tp2645316p2645…
Sent from the XWiki- Users mailing list archive at Nabble.com.
Hi Maurius,
On Fri, Apr 17, 2009 at 12:47 PM, Marius Dumitru Florea <
mariusdumitru.florea(a)xwiki.com> wrote:
> Hi Jonas,
>
> Jonas Almfeldt wrote:
>
>> Hi Maurius and Guillaume,
>>
>> I'm sending this to you in order to not spam the mailing list. We can post
>> final results to the list if/when we have a solution.
>>
>
> AFAIK no one complained so far about the increasing number of mails on the
> users lists.
>
Ok, good :-)
>
>> The scenario you described in your email reproduces the error for me, each
>> time, when running hte xwiki instance in WebSphere Application Server 6.1
>> environment.
>>
>> I have now tested some more with the 1.8.1 stable version.
>>
>> I get different results when running the scenario you described in my
>> local test environment based on Tomcat 5.5 and when running it on the server
>> side (WAS).
>>
>> Configurations:
>>
>> Local setup
>> ==========
>> *Tomcat 5.5 + Oracle 9.2.1 locally on my Win XP pc.
>> * Oracle jdbc driver: ojdbc14.jar (for Oracle 10 G)
>> * downloaded
>> http://repository.jboss.com/maven2/net/jcip/jcip-annotations/1.0/jcip-annot…
>> and saved as xwiki/WEB-INF/lib/jcip-annotations-1.0.jar (this was a
>> missing dependancy when I deployed it in the hosted set up on WAS, and I
>> want the war files to be as similar as possible except for the db
>> configuration part and log paths, so I included this in the local set up
>> also, although not needed. It seems to be included in the JRE/SDK or in
>> Tomcat already)
>> * Database content (wiki content) imported from XAR file i created from a
>> complete export of the information in the wiki instance running in the
>> "hosted setup".
>> I'm not having the problem with this setup.
>>
>> Hosted setup
>> ==========
>> * WebSphere Application Server 6.1 + Remote Oracle 10 G.
>> * Oracle jdbc driver: ojdbc14.jar (for Oracle 10 G)
>> * downloaded
>> http://repository.jboss.com/maven2/net/jcip/jcip-annotations/1.0/jcip-annot…
>> and saved as xwiki/WEB-INF/lib/jcip-annotations-1.0.jar (this was a
>> missing dependancy when I deployed it in the hosted set up on WAS)
>> Question: Would it be possible that the proper jcip-annotations-1.0.jar
>> can be included in the official .war distribution of XWiki in the future,
>> since the jcip-annotations classes seem to be required for xwiki to work
>> (out of the box at least)?
>> * Database content was created with the previous xwiki 1.8 stable release.
>>
>> This setup induces the wysiwyg xwiki/2.0 parsing problem.
>>
>
> I don't think this problem is related to the application server or the
> database used, nor even to the imported XAR. It should be caused by the
> xwiki-rendering jars you have in your WEB-INF/lib directory or by the
> WYSIWYG velocity templates.
>
Where can I find those templates? in the .war file or in the database?
>
>> When running the scenario in the "hosted setup" the following happens:
>>
>> Create new document, wysiwyg editor opens by default, (syntax: xwiki/2.0
>> is selected but grayed out in the wiki syntax chooser):
>>
>> * typed "Heading 1"
>> * applied "Title 1" style
>> * pressed Enter twice (to go out of the heading)
>> * clicked the bold button
>> * typed "bold text"
>> * pressed Enter twice (to create a new paragraph)
>> * typed "bold text" again
>> * saved (everything was fine)
>> * edited again (everything was NOT fine)
>>
>> In the wysiwyg editor I get:
>>
>> ---------------8<-------------
>> = Heading 1 = **bold text** **bold text**
>> --------------->8---------------
>>
>
> This means the XWiki syntax is no converted to XHTML before loading the
> editor. Can you try a simpler example just to be sure? For instance to this:
>
> * edit a new/empty page
> * type a word like "bug"
> * select the word
> * click the bold button on the tool bar
> * save and edit again
>
> Do you get **bug** in the WYSIWYG editor? If so, then cancel the edit. The
> "bug" is in bold in view mode right? Then please append "xpage=wysiwyginput"
> to the query string of your URL and tell me the output. For instance:
>
> http://localhost:8080/xwiki/bin/view/Sandbox/Test?xpage=wysiwyginput
>
> I suspect the output is **bug** right?
>
Yes, the output is: **bug**\\
>
> Now if you append also "render" like in:
>
> http://localhost:8080/xwiki/bin/view/Sandbox/FF?xpage=wysiwyginput&render
>
> is the "bug" in bold?
No :-( the output of ...?xpage=wysiwyginput&render is still: **bug**\\
Some additional details:
The WAS 6.1 jvm has java version 1.5.0 btw.
My local Tomcat runs with the JRE of jdk1.5.0_08.
I also forgot to mention to the list that this problem is not specific to
1.8.1. It happens when I test with 1.8 also. (same wiki db content used,
created with 1.8 stable and the 1.8 XAR archive as a base).
>
>> When upgrading to 1.8.1, I did not apply the xwiki enterprise 1.8.1 XAR
>> archive.
>>
>> I'm also getting quite a lot of error messages/warning messages from xwiki
>> in the system out log of the WAS.
>> Maybe this has something to do with the error?
>> An extract of the reoccurring errors is attached to this email.
>>
>
> The errors are not related to the WYSIWYG editor.
>
> Thanks,
> Marius
>
>
>> What do you think about this?
>>
>> All help is appreciated :-)
>>
>> Kind regards,
>> Jonas
>>
>> On Thu, Apr 16, 2009 at 3:24 PM, Marius Dumitru Florea <
>> mariusdumitru.florea(a)xwiki.com <mailto:mariusdumitru.florea@xwiki.com>>
>> wrote:
>>
>> Hi,
>>
>> Jonas Almfeldt wrote:
>> > Hi,
>> >
>> > I hope someone out there can help me with this very strange
>> problem with the
>> > editors.
>> >
>> > I have WYSIWYG as the default editor, and have edited the
>> xwiki.properties
>> > and set xwiki/2.0 as default editor syntax.
>> >
>> > Scenario:
>> >
>> > I create a new page. Wysiwyg editor is default.
>> > Editing the following content:
>> >
>> > Heading 1
>> > bold text
>> > bold text
>> >
>> > And saving.
>>
>> Can you tell me the exact steps to reproduce the problem. Can you
>> reproduce the problem each time? I tried the following:
>>
>> * typed "Heading 1"
>> * applied "Title 1" style
>> * pressed Enter twice (to go out of the heading)
>> * clicked the bold button
>> * typed "bold text"
>> * pressed Enter twice (to create a new paragraph)
>> * typed "bold text" again
>> * saved (everything was fine)
>> * edited again (everything was fine)
>> * went to Wiki editor and got:
>>
>> ---------------8<---------------
>> = Heading 1 =
>>
>> **bold text**
>>
>> **bold text**
>> --------------->8---------------
>>
>> So I can't reproduce this way.
>>
>> Thanks,
>> Marius
>>
>> > It looks nice when viewing the new page, with "Title 1"
>> formatting of the
>> > heading line and bold text on the second and third lines.
>> >
>> > But when I chose to edit the page again, the wysiwyg editor
>> appears, with
>> > the following faulty content:
>> >
>> > = heading 1 = **bold text line 1** **bold text line 2**\\ \\
>> >
>> > Hitting the Preview button from wysiwyg editor shows the same
>> result, raw
>> > xwiki/2.0 syntax, minus the original line breaks in the preview
>> mode.
>> >
>> > If I instead of preview change to the Wiki editor mode, the
>> content is
>> > escaped:
>> >
>> > ~= heading 1 = ~*~*bold text line 1~*~* ~*~*bold text line
>> 2~*~*~\~\ ~\~\
>> >
>> > And if cycling between the editors once more from there, even
>> more escape
>> > ~ characters occur.
>> >
>> > What am I doing wrong? config issue? or is this a bug? wysiwyg
>> editor
>> > appears not to be able to parse xwiki/2.0 syntax in 1.8.1?
>> >
>> > Details:
>> >
>> > * XWiki 1.8.1 stable
>> > * WebSphere Application Server 6.1 fixpack 21
>> >
>> > Kind regards,
>> > Jonas
>> > _______________________________________________
>> > users mailing list
>> > users(a)xwiki.org <mailto:users@xwiki.org>
>> > http://lists.xwiki.org/mailman/listinfo/users
>> _______________________________________________
>> users mailing list
>> users(a)xwiki.org <mailto:users@xwiki.org>
>> http://lists.xwiki.org/mailman/listinfo/users
>>
>>
>>
>> ------------------------------------------------------------------------
>>
>>
Kind regards,
Jonas
Hi,
I'm in the process of evaluating XWiki and I'm trying to integrate it
with our SSO.
I've so far written a class that extends XWikiAuthServiceImpl and I'm
seeing calls to checkAuth and showLogin, but I don't really understand
the logic behind those different calls. checkAuth seems to be called
very frequently with XWiki.XWikiGuest as the user even though I
returned a valid XWikiUser after the call that followed the
authentication.
Is there a document that explains what the different methods in
XWikiAuthService do and when they are called?
Any help or pointer would be appreciated.
Mathias.
Hello,
I´m looking for a dynamic 'Database List' at my Wiki.
I wan´t to select with the first 'Database List' the category and then
select multiple
items of sub categories in the second 'Database List'.
The second 'Database List' has to show the actual sub categories
dependent of the selected first 'Database List'.
Database:
+Category_1
|-Subcategory_1_1
|-Subcategory_1_2
|-Subcategory_1_3
|-Subcategory_1_4
+Category_2
|-Subcategory_2_1
|-Subcategory_2_2
|-Subcategory_2_3
|-Subcategory_2_4
+Category_3
.
.
.
.
I´m testing the 'Database Tree' but when multiselect is enabled I can
select items in all Categories.
Is there a possibility to realize this with standard classes?
Have I got to use a script like java script or something similar.
Have somebody an example or some information how to design this on a
xwiki database?
Thank you very much!
Best Regrades
Juergen