Re: [xwiki-users] Velocity code in XWiki Enterprise 1.9.1.21780

2009-07-22 Thread Sergiu Dumitriu
Marc Lijour wrote:
 I did not find how to submit this fully as a comment to  
 http://platform.xwiki.org/xwiki/bin/view/DevGuide/FAQTutorial 

What do you mean by that? Logged in users can post comments, and I see 
that you do have a user account on xwiki.org.

-- 
Sergiu Dumitriu
http://purl.org/net/sergiu/
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Velocity code in XWiki Enterprise 1.9.1.21780

2009-07-22 Thread Marc Lijour
On Wednesday 22 July 2009 02:26:48 Sergiu Dumitriu wrote:
 Marc Lijour wrote:
  I did not find how to submit this fully as a comment to
  http://platform.xwiki.org/xwiki/bin/view/DevGuide/FAQTutorial

 What do you mean by that? Logged in users can post comments, and I see
 that you do have a user account on xwiki.org.

I did not find how to escape the code (which contains things as {{velocity}}). 
The parser can not bite it. I only submitted a portion of the comment.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Velocity code in XWiki Enterprise 1.9.1.21780

2009-07-22 Thread Jean Couteau
Marc Lijour a écrit :
 On Wednesday 22 July 2009 02:26:48 Sergiu Dumitriu wrote:
   
 Marc Lijour wrote:
 
 I did not find how to submit this fully as a comment to
 http://platform.xwiki.org/xwiki/bin/view/DevGuide/FAQTutorial
   
 What do you mean by that? Logged in users can post comments, and I see
 that you do have a user account on xwiki.org.
 

 I did not find how to escape the code (which contains things as 
 {{velocity}}). 
 The parser can not bite it. I only submitted a portion of the comment.
 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users

   
If you put it between the {pre} and {/pre} tags it does not escape ?

-- 

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 

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Velocity code in XWiki Enterprise 1.9.1.21780

2009-07-22 Thread Sergiu Dumitriu
Marc Lijour wrote:
 On Wednesday 22 July 2009 02:26:48 Sergiu Dumitriu wrote:
 Marc Lijour wrote:
 I did not find how to submit this fully as a comment to
 http://platform.xwiki.org/xwiki/bin/view/DevGuide/FAQTutorial
 What do you mean by that? Logged in users can post comments, and I see
 that you do have a user account on xwiki.org.
 
 I did not find how to escape the code (which contains things as 
 {{velocity}}). 
 The parser can not bite it. I only submitted a portion of the comment.

Since that is the 1.0 syntax, you should place it inside:

{code}
your code here
{code}

-- 
Sergiu Dumitriu
http://purl.org/net/sergiu/
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] Velocity code in XWiki Enterprise 1.9.1.21780

2009-07-21 Thread Marc Lijour
Hi,

I have the brand new XWiki Enterprise 1.9.1.21780. I noticed that the class 
wizard has issues 
(http://xwiki.markmail.org/message/kl7vi6p2dlc3ouwr?q=FAQTutorial#query:FAQTutorial+page:1+mid:zyimlrxfkx3uff6x+state:results),
 
but I did create a class, a class sheet and a class template manually. I also 
added an empty object to the class.

Because the Velocity code is not interpreted the same way in syntax xwiki 2.0, 
I followed the syntax help guide included in the XWiki instance and I 
protected the code as follows:
{{velocity}}
## replace Main with the Space where you want your documents to be created
## replace the default parent with the one of your choice
## Save this template using the 'Save' button
#set( $class = $doc.name.substring(0,$doc.name.indexOf(Class)))
#set($defaultparent = XWiki.${class}Class)
#set($defaultweb = LSQ)
#includeForm(XWiki.ClassSheet)
{{/velocity}} 

The Velocity code is parsed but it produce HTML that is not parsed by the Wiki 
page. It is displayed as-is:

h1 id=HClass3ATermeClassspanClass: TermeClass/span/h1p/
The first thing to do is to a 
href=/xwiki/bin/edit/LSQ/TermeClass?xpage=editclassEdit the Class/a to 
add properties to it.p/
h2 id=HCreateanewdocumentspanCreate a new document/span/h2p/
To create a new document, you should first choose a name for you documentp/
form action= id=newdoc method=post
div
input type=hidden name=parent value=XWiki.TermeClass/
input type=hidden name=template value=LSQ.TermeClassTemplate/
input type=hidden name=sheet value=1/
Space: input type=text name=webname value=LSQ size=8/
Document: input type=text name=name value=Name of your document/
br/
br/
input type=button value=Create this document onclick='if 
(updateName(this.form.name)) {this.form.action=../../inline/ + 
this.form.webname.value + / + this.form.name.value; this.form.submit(); }'/
/div
/formp/
h2 id=HSheetandTemplatespanSheet and Template/span/h2p/
ul class=star
liSheet: span class=wikilinka 
href=/xwiki/bin/view/LSQ/TermeClassSheetTerme Class Sheet/a/span/li
liTemplate: span class=wikilinka 
href=/xwiki/bin/view/LSQ/TermeClassTemplateTerme Class 
Template/a/span/li
lispan class=wikilinka 
href=/xwiki/bin/view/XWiki/ClassSheet?xpage=codeView the sample code to 
show the document list and create new documents/a/span/li
/ul
h2 id=HExistingdocumentsspanExisting documents/span/h2p/ 

Is there a workaround that to make the page parse this HTML properly or to 
produce an equivalent display?

It would be nice to also let people know at 
http://platform.xwiki.org/xwiki/bin/view/DevGuide/FAQTutorial (completing 
tapaya's remark) -I could do that if I knew the answer.

Thanks

Marc
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users