[xwiki-users] How to perform global content refactoring with xeclipse

2009-10-24 Thread Valdis Vītoliņš
Hello!
I'm experimenting with xeclipse to perform global xwiki content
refactoring.
Idea is following: get local xwiki copy in files on disk, then perform
find/replace using regular expressions on files
and upload back to xwiki.
(It could be possible using simple import/export though it is more error
prone and it cant be done at once due to maximum importing file limit.)

Though I couldn't do that. It seems after refreshing local content is
overwritten from xwiki, if file changes are not performed in editor.
Can anybody explain how it could/should be done?

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


Re: [xwiki-users] problem with FAQ tutorial .. space assignment?

2009-11-16 Thread Valdis Vītoliņš
> I've been told the url http://localhost/xwiki/bin/view/FAQ/ is equivalent 
> to http://localhost/xwiki/bin/view/FAQ/WebHome/ but I'm a little shaky on 
> that point.


For Xwiki tailing slash is the same as WebHome page. So description
above is not correct.
Correct explanation is following:
http://localhost/xwiki/bin/view/FAQ/ is the same as
http://localhost/xwiki/bin/view/FAQ/WebHome without tailing slash.
For other pages URL always finishes with Pagename, not slash, e.g.
http://localhost/xwiki/bin/view/FAQ/Page1
http://localhost/xwiki/bin/view/FAQ/Page2 etc.

http://localhost/xwiki/bin/view/FAQ/WebHome/ is the same as
http://localhost/xwiki/bin/view/FAQ/WebHome/WebHome
(in this case 1st "WebHome" is space under "Main" space, but 2nd
"WebHome" is page in "WebHome" space).

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


Re: [xwiki-users] [ANN] XWiki Enterprise 2.1 Milestone 1 released

2009-11-19 Thread Valdis Vītoliņš
According to Unix style, there is only move.
Actually the same is true for Xwiki.
Though some users tend to feel rename more convenient :-p

Valdis

> On 11/19/2009 05:05 PM, Ecaterina Valica wrote:
> > not necessarily with a separator - but could in the last place - as a final
> > action.
> >
> > another question is: we can simulate a Move action with the Rename - would
> > be nice if we had this move action more explicit?
> 
> What would be the difference between Move and Rename?
> 


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


Re: [xwiki-users] Could not initialize main XWiki context

2009-11-23 Thread Valdis Vītoliņš
Did you add mysql-connector-...jar file in the /WEB-INF/lib folder?
Valdis


> I have installed the enterprise xwiki.war completed all intructions for
> Tomcat Servlet and MySQL Database configuration. When I try to connect from
> my browser the error occurs below. The Wiki is running on a hosted tomcat
> webserver.
> 
> I've found the general error alot but not with the following line code:
> Wrapped Exception: Could not parse mapping document from resource
> xwiki.hbm.xml
> 
> I thought the error might be related to some mistakes in the
> hibernate.cfg.xml
> 
> Name of database: 24_xwiki
> Password: xwiki123
> 
>  name="connection.url">jdbc:mysql://localhost/xwiki?useServerPrepStmts=false
> 24_xwiki
> xwiki123
>  name="connection.driver_class">com.mysql.jdbc.Driver
> org.hibernate.dialect.MySQLDialect
> 
> 
> I'm a newbie concerning web hosting so thanks for any help as I' ve got
> stuck since Saturday :(
> 
> javax.servlet.ServletException: com.xpn.xwiki.XWikiException: Error number 3
> in 0: Could not initialize main XWiki context
> Wrapped Exception: Error number 3001 in 3: Cannot load class
> com.xpn.xwiki.store.migration.hibernate.XWikiHibernateMigrationManager from
> param xwiki.store.migration.manager.class
> Wrapped Exception: Error number 0 in 3: Exception while hibernate execute
> Wrapped Exception: Could not parse mapping document from resource
> xwiki.hbm.xml
> 
> org.apache.struts.action.RequestProcessor.processException(RequestProcessor.java:535)
> 
> org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:433)
> 
> org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
>   org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
>   org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
>   javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>   javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> 
> com.xpn.xwiki.wysiwyg.server.filter.ConversionFilter.doFilter(ConversionFilter.java:152)
>   com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:117)
>   
> com.xpn.xwiki.plugin.webdav.XWikiDavFilter.doFilter(XWikiDavFilter.java:68)
> 
> com.xpn.xwiki.web.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:295)
> 
> com.xpn.xwiki.web.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112)
> 
> root cause
> 
> com.xpn.xwiki.XWikiException: Error number 3 in 0: Could not initialize main
> XWiki context
> Wrapped Exception: Error number 3001 in 3: Cannot load class
> com.xpn.xwiki.store.migration.hibernate.XWikiHibernateMigrationManager from
> param xwiki.store.migration.manager.class
> Wrapped Exception: Error number 0 in 3: Exception while hibernate execute
> Wrapped Exception: Could not parse mapping document from resource
> xwiki.hbm.xml
>   com.xpn.xwiki.XWiki.getMainXWiki(XWiki.java:339)
>   com.xpn.xwiki.XWiki.getXWiki(XWiki.java:400)
>   com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:135)
>   com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:115)
> 
> org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
> 
> org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
>   org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
>   org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:414)
>   javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
>   javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
> 
> com.xpn.xwiki.wysiwyg.server.filter.ConversionFilter.doFilter(ConversionFilter.java:152)
>   com.xpn.xwiki.web.ActionFilter.doFilter(ActionFilter.java:117)
>   
> com.xpn.xwiki.plugin.webdav.XWikiDavFilter.doFilter(XWikiDavFilter.java:68)
> 
> com.xpn.xwiki.web.SavedRequestRestorerFilter.doFilter(SavedRequestRestorerFilter.java:295)
> 
> com.xpn.xwiki.web.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:112)
> 
> 
> -- 
> View this message in context: 
> http://n2.nabble.com/Could-not-initialize-main-XWiki-context-tp4051328p4051328.html
> Sent from the XWiki- Users mailing list archive at Nabble.com.
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Encoding questions

2009-11-23 Thread Valdis Vītoliņš
All progressive mankind is gone to UTF-8 long time ago, exception is
Americans and West-Europeans, especially if they run Windows servers;-)
So, my advice would be to migrate both systems to UTF-8. 

But you can try to run some velocity/groovy script invoking iconv on the
fly.
Something like:
#set($cont= $xwiki.getURLContent("${url}view/${name}"))
## invoke iconv on $cont
$cont

Valdis

> Hi everybody
> 
> We have an Xwiki production platform which includes the documentation of 2 of 
> our applications. Infortunately, they don't nécessarely speak to each other.
> 
> The xwiki configuration file indicates that the encoding is ISO-8859-1 which 
> works fine till now.
> 
> But one of the two applications wishes to give a XAR with xml files in 
> ISO-8859-15...
> 
> Here is my question : can I put two encodings in the configuration file like 
> "xwiki.encoding=ISO-8859-1,ISO-8859-15" to allow multiple encodings for 
> different spaces ?
> 
> Thanks in advance
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Encoding questions

2009-11-24 Thread Valdis Vītoliņš
Yes, it will invoke iconv on every page.
If you worry about performance, it should be addressed by page caching,
using either Java (such as OScache), or web server (e.g. Apache cache).

Another solution could be tweaking header meta tags, but I don't know
how to do this in xwiki. Can anybody comment this?

Valdis

> Hi
> 
> You're right, we're locate din West Europe and run on Windows...
> That's the way.
> 
> As far as I understand your answer, it seems to work on page calls. But does 
> it mean that it will call iconv on the fly for every page ?
> 
> TIA
> 
> Fred
> 
> -Message d'origine-
> De : users-boun...@xwiki.org [mailto:users-boun...@xwiki.org] De la part de 
> Valdis Vitolinš
> Envoyé : lundi 23 novembre 2009 18:11
> À : XWiki Users
> Objet : Re: [xwiki-users] Encoding questions
> 
> All progressive mankind is gone to UTF-8 long time ago, exception is
> Americans and West-Europeans, especially if they run Windows servers;-)
> So, my advice would be to migrate both systems to UTF-8. 
> 
> But you can try to run some velocity/groovy script invoking iconv on the
> fly.
> Something like:
> #set($cont= $xwiki.getURLContent("${url}view/${name}"))
> ## invoke iconv on $cont
> $cont
> 
> Valdis
> 
> > Hi everybody
> > 
> > We have an Xwiki production platform which includes the documentation of 2 
> > of our applications. Infortunately, they don't nécessarely speak to each 
> > other.
> > 
> > The xwiki configuration file indicates that the encoding is ISO-8859-1 
> > which works fine till now.
> > 
> > But one of the two applications wishes to give a XAR with xml files in 
> > ISO-8859-15...
> > 
> > Here is my question : can I put two encodings in the configuration file 
> > like "xwiki.encoding=ISO-8859-1,ISO-8859-15" to allow multiple encodings 
> > for different spaces ?
> > 
> > Thanks in advance
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> 
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Probaly cracked Xwiki

2009-12-03 Thread Valdis Vītoliņš
Hello,
I'd just like to wan you that it seems my Xwiki site has been cracked
few hours ago.
One notable change is that copyright string now is "Copyright 2004-2007
(c) XPertNet and Contributing Authors"
I'm still investigating, reason, but please be watchful you also.

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


Re: [xwiki-users] Probaly cracked Xwiki

2009-12-03 Thread Valdis Vītoliņš
After investigation I found that somebody somehow
deleted /xwiki/bin/admin/XWiki/XWikiPreferences object.
So here is question: how can I find, which xwiki document was deleted?
(It is easy to find which document was added or modified, but not so
about deleted ones).

Valdis

> Hello,
> I'd just like to wan you that it seems my Xwiki site has been cracked
> few hours ago.
> One notable change is that copyright string now is "Copyright 2004-2007
> (c) XPertNet and Contributing Authors"
> I'm still investigating, reason, but please be watchful you also.
> 
> Valdis
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] upgrading standalone xwiki?

2009-12-07 Thread Valdis Vītoliņš
Don't these errors appear because database connector is not added in
WEB-INF/lib?
Wouldn't it better to include it in xwiki war file to avoid such
mistakes?

Valdis


> hi folks,
> 
> can anyone point me to a step-by-step example of upgrading a standalone 
> xwiki?
> 
> replacing the contents of ${XWIKI_HOME}/webapps/xwiki/ with 
> xwiki-enterprise-web-2.1-rc-1.war & copying back the hibernate.cfg.xml 
> and xwiki.cfg has resulted in:
> 
> Problem accessing /xwiki/bin/view/Main/. Reason:
> 
>  Error number 3 in 0: Could not initialize main XWiki context
> Wrapped Exception: Error number 3001 in 3: Cannot load class 
> com.xpn.xwiki.store.migration.hibernate.XWikiHibernateMigrationManager 
> from param xwiki.store.migration.manager.class
> Wrapped Exception: Error number 0 in 3: Exception while hibernate execute
> Wrapped Exception: Could not parse mapping document from resource 
> xwiki.hbm.xml
> 
> 
> 
> i'm upgrading  2.0.3  to 2.1RC1
> 
> sorry if this is covered in a FAQ - the upgrade Xwiki Core from 
> 
>  
> isn't very explicit
> 
> any suggestions?
> 
> regards
> 
> p
> 
> --
> Peter Lees
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Xwiki 2.1 custom style guidlines

2010-01-04 Thread Valdis Vītoliņš
Xwiki 2.1 style management is in intermediate state between standalone
css file and online editor.
Though currently many style editing possibilities have been
dropped/trivialized in comparison to 1.8.
Question is: what is the best approach to add necessary additional style
elements?

Thanks!
Valdis

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


[xwiki-users] # in place of UTF characters for PDF export

2010-01-05 Thread Valdis Vītoliņš
Can anybody say what is problem that PDF export still (xwiki 2.2.1)
shows # for UTF characters (e.g. for Latvian āčēģīķļņōŗšūž).
See attached PDF.

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


[xwiki-users] Your experience about storage requirements and performance of customized Xwiki solutions

2010-01-11 Thread Valdis Vītoliņš
Hello,
I'm thinking abut another custom solution based on xwiki.
Though I'm worried about storage consumption and performance if there
will be >10k objects with ~10 string attributes.

My experience with quite small solutions
(few hundreds of objects http://odo.lv/Recipes/Recipes1_en and
http://www.ante.lv/xwiki/bin/view/Arts.Songs/ )
required using of apache cache.

I know that http://l10n.xwiki.org/xwiki/bin/view/L10N/ is quite slow,
but don't know why.

Can you share your experience/recommendations, how to build it in the
right way?

Thanks in advance,
Valdis

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


Re: [xwiki-users] Export and Backup of Wiki Instance

2010-01-12 Thread Valdis Vītoliņš
I use following settings for JVM (e.g. options for tomcat)
JAVA_OPTS="-Djava.awt.headless=true -Xms256m -Xmx512m
-XX:MaxPermSize=256m"

I found Xar handy for moving data from one (test) instance to another
(production),
though for full backup I use MySQL dump.

Backup: mysqldump -u root -ppassword --opt xwiki > xwiki.sql
Restore: mysql -u root -ppassword -Dxwiki < xwiki.sql

Valdis

> Hi,
> 
> No i am not using WEBDAV. Its a fresh installation of Xwiki and i have only
> created about 4 pages so far.
> 
> Here are the steps i took to install it.
> 
> - Installed Tomcat 6.0
> - Installed Xwiki Enterprise 2.1.1
> - set up the hibernate configuration to mysql
> - Installed the default set of wiki pages which provide the blog, spaces etc
> (i.e. xwiki-enterprise-wiki-2.1.1.xar )
> - Created a couple of wiki pages to test it.
> 
> Thats all i have done so far and is what i am trying to export. I must
> mention that i did not change any configuration in Tomcat in terms of how
> much memory is allocated to tomcat. Everything is at their default values.
> 
> I have seen in several wiki configuration that they recommend increasing the
> amount of memory allocated to tomcat. Do you think that maybe i need to play
> around with the memory allocation within Tomcat?
> 

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


[xwiki-users] Create custom object using URL get/post/put

2010-01-13 Thread Valdis Vītoliņš
I'm investigating how to use curl or ~like this to create custom object
for application integration (it should be authenticated, which seems no
problem).

I'm studying
http://platform.xwiki.org/xwiki/bin/view/Features/XWikiRESTfulAPI

It is possible to retrieve custom object, but I couldn't find how to add
them.
How it could be done?

Thanks in advance,
Valdis


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


Re: [xwiki-users] Blogs in 2.1.1

2010-01-15 Thread Valdis Vītoliņš
I also use xwiki through apache proxy. Mention bug can be easily found
but is not the only one.
When I started to investigate and fix all broken HTML bugs, I got tired
and downgraded Blog to previously used 1.8,
because too many of "one-liner" 2.1.1 Blog constructs produced incorrect
HTML through the proxy.

We can join efforts, I you wish, to try to make it working. 

Valdis

> Hi,
> 
> I just migrated my instance from 2.0.3 to 2.1.1, and imported new xar,
> including all Blog pages.
> 
> My instance is available either directly, or through a reverse proxy for
> larger scope:
> Reverse Proxy (Apache) <-> Proxy (Apache) <-> Wiki (tomcat)
> 
> Viewing, editing and posting new blog entries when using url of proxy or
> directly tomcat works perfectly.
> 
> Posting, when using url of reverse proxy, does not work because when
> clicking "create" button, the following url is used :
> http://r-wiki.company.com/test/bin/view/Blog/ class=?entrySpace=Blog&entryTitle=jbtests
> 
> Browsing the wiki and editing pages through our reverse proxy always worked
> perfectly, and posting blogs was not an issue since now. I think it's linked
> to urls replacement in syntax 2.0, and the fact that it considers urls local
> or external, but I'm not sure.
> 
> Any help appreciated,
> 
> Thanks,
> Jeremie
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Blogs in 2.1.1

2010-01-15 Thread Valdis Vītoliņš
http://test.odo.lv/Blog/ 
Credentials for testing I've sent separately.

Valdis

> Can you give me an example, so that I know what to look for?

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


[xwiki-users] Custom properties for XWikiUsers class

2010-01-26 Thread Valdis Vītoliņš
For custom application I need to add more properties
for ../xwiki/bin/edit/XWiki/XWikiUsers?editor=class 
Is it acceptable/recommended way or other (more complicated?) approach
would be better?
Do you have any experience?

Thanks in advance,
Valdis
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Registered Users

2010-01-28 Thread Valdis Vītoliņš
Did you try to watch XWiki space?

Valdis

> Is there anyway to get email notifications when new users register?  I 
> figured I would put a watch on the preferences, but that didn't seem to help.
> 
> Any help would be appreciated.
> 
> Jared Parrish
> Network Administrator
> Travelhost, Inc.
> 972-556-0541 ext 152
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] PDF with UTF characters

2010-02-01 Thread Valdis Vītoliņš
I'm investigating issue http://jira.xwiki.org/jira/browse/XWIKI-4724
Now I can generate right PDF using separate FOP with additional
configuration files and invocation parameters.
Though I don't know, how to invoke it in such way from Xwiki.

Do you have any suggestions/ideas?

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


Re: [xwiki-users] PDF with UTF characters

2010-02-04 Thread Valdis Vītoliņš
I learned how to add custom TTF font and metrics for FOP.
Test project can be downloaded from http://odo.lv/ftp/temp/FOP.zip
There are FOP jars and "Lucida Sans Unicode" TTF font with generated
metrics file.
Metrics can be created using generate_font_metrics.bat script. Test PDF
can be generated with test1.bat script. 

Now questions are:
How can I invoke customized FOP with additional parameter for my config
file from Xwiki?
Or how can I change default font From "Times-Roman" to "Lucida Sans
Unicode"?

Valdis

> On 02/01/2010 09:47 PM, Valdis Vītoliņš wrote:
> > I'm investigating issue http://jira.xwiki.org/jira/browse/XWIKI-4724
> > Now I can generate right PDF using separate FOP with additional
> > configuration files and invocation parameters.
> > Though I don't know, how to invoke it in such way from Xwiki.
> >
> > Do you have any suggestions/ideas?
> 
> I gave a workaround in a comment on that issue, in case somebody else is 
> interested in this problem and wants an answer.
> 


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


Re: [xwiki-users] Custom properties for XWikiUsers class

2010-02-04 Thread Valdis Vītoliņš
> >> For custom application I need to add more properties
> >> for ../xwiki/bin/edit/XWiki/XWikiUsers?editor=class
> >> Do you have any experience?
> > - Create a XWiki.ExtendUserClass holding your properties
> > - Add an object from this class to your user profiles
> > - Use it to store information
> 
> I also recommend this, but there's a problem: creating a new user only 
> adds the XWikiUsers object, since it doesn't create documents based on a 
> template. This means that somewhere you'll have to add this object.
> 
> A solution is to put a check in the user sheet, similar to what is done 
> for WebPreferences and a missing XWikiPreferences object.
> 
> #if(!$doc.getObject('XWiki.ExtendUserClass'))
>$response.sendRedirect($doc.getURL('objectadd', 
> 'classname=XWiki.ExtendUserClass'))
> #end


This works (though need not to be scared and save it)
for user's wiki document content another line should be added to show
data properly:
#includeForm("XWiki.XWikiUsersExtSheet")

Do you have any ideas about this?

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


Re: [xwiki-users] Custom properties for XWikiUsers class

2010-02-04 Thread Valdis Vītoliņš
> > >> For custom application I need to add more properties
> > >> for ../xwiki/bin/edit/XWiki/XWikiUsers?editor=class
> > >> Do you have any experience?
> > > - Create a XWiki.ExtendUserClass holding your properties
> > > - Add an object from this class to your user profiles
> > > - Use it to store information
> > 
> > I also recommend this, but there's a problem: creating a new user only 
> > adds the XWikiUsers object, since it doesn't create documents based on a 
> > template. This means that somewhere you'll have to add this object.
> > 
> > A solution is to put a check in the user sheet, similar to what is done 
> > for WebPreferences and a missing XWikiPreferences object.
> > 
> > #if(!$doc.getObject('XWiki.ExtendUserClass'))
> >$response.sendRedirect($doc.getURL('objectadd', 
> > 'classname=XWiki.ExtendUserClass'))
> > #end
> 
> 
> This works (though need not to be scared and save it)
> for user's wiki document content another line should be added to show
> data properly:
> #includeForm("XWiki.XWikiUsersExtSheet")

Solved this adding this line at the end of
"/xwiki/bin/edit/XWiki/XWikiUserSheet" ;-)

Valdis


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


Re: [xwiki-users] PDF with UTF characters

2010-02-04 Thread Valdis Vītoliņš
Many thanks Sergiu!
I solved this. My comments are inline.

> Even the FOP developers say that generating font metrics is not needed, 
> and deprecated. FOP should correctly find and use system fonts, and 
> should correctly work with TTF fonts.

I checked this and that's correct. 

> The problem is that FOP doesn't 
> find the fonts provided by XWiki because Tomcat doesn't use an URI 
> scheme that FOP understands. You can extract 
> WEB-INF/lib/xwiki-core-XYZ.java#fop-config.xml into WEB-INF/classes and 
> adjust the  settings so that you manually specify the path to the 
> right font files. The syntax for the config xml should be on the FOP site.

Copied Courier_New.ttf and  Times_New_Roman.ttf
into ../webapps/xwiki/WEB-INF/fonts

Added following lines to
the ../webapps/xwiki/WEB-INF/classes/fop-config.xml
  
...

   


   


...
  

> Extract xhtml2fo.xsl from WEB-INF/lib/xwiki-core-XYZ.jar into 
> WEB-INF/classes and search for the line:
> 
> FreeSerif,serif

Changed FreeSerif,serif to Times New Roman and FreeMono,monospace to Courier New

Ran PDF export, got
exception ... /usr/share/tomcat5.5/.fop/fop-fonts.cache (No such file or
directory)...
mkdir /usr/share/tomcat5.5/.fop/
chown tomcat5:root /usr/share/tomcat5.5/.fop/
chmod 775 /usr/share/tomcat5.5/.fop/

restarted tomcat
and viola!
It is working now!

Valdis

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


[xwiki-users] Avoid adding of XWiki.TagClass object for custom object

2010-02-05 Thread Valdis Vītoliņš
For Xwiki custom objects there is no need to add XWiki.TagClass object
for wiki document.
How easy it could be adjusted to not add XWiki.TagClass object for these
documents,
or it isn't worth to investigate/do that?

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


Re: [xwiki-users] Avoid adding of XWiki.TagClass object for custom object

2010-02-05 Thread Valdis Vītoliņš
> > For Xwiki custom objects there is no need to add XWiki.TagClass object
> > for wiki document.
> > How easy it could be adjusted to not add XWiki.TagClass object for these
> > documents,
> 
> Pretty complicated, this class was somehow hardcoded in the core (bad 
> design decision), but it should be fixed, since I don't like it either.
> 
> > or it isn't worth to investigate/do that?
> 
> Does it cause problems for you? Can't it be ignored?

Thanks.
In general it can be easily ignored, I only worry  about disk space and
performance in future.
So if it will appear important, workaround will be to delete them
afterwards ;-)

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


Re: [xwiki-users] Favicon?

2010-02-05 Thread Valdis Vītoliņš
You need to ensure your web server provides favicon form
http://hostname/favicon.ico 
For apache it would be /var/www/favicon.ico

As xwiki is under /xwiki/... directory it is not related to xwiki.

Valdis

> Hi is it possible to use a favicon for our wiki?
> 
> If yes, in which directory should the logo.ico file go?
> 
> Thanks in advance,
> 
> Xavier
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Variable is shown in input field when other document is inline mode

2010-02-08 Thread Valdis Vītoliņš
I'd like to show different links in panel depending on Xwiki user's
Company field.
Following code does this
#set($myCompany='')
#set($obj=$xcontext.getUser())
#set($objdoc = $xwiki.getDocument($obj))
#set($myCompany = $objdoc.company)

$myCompany

Though when wiki document is opened in inline editing mode,
variable is shown in input text field.
To test this, put code in document then open it in inline mode.
This seems related to standard xwiki behavior.

How it could be solved in different way?

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


Re: [xwiki-users] Login Style

2010-02-10 Thread Valdis Vītoliņš
Provide view rights for unregistered user for used ColorTheme document.

Valdis

> Hi Ben,
> 
> On Fri, Oct 2, 2009 at 4:08 PM, Ben Stewart wrote:
> 
> > Greetings Folks,
> > I have setup XEM with application etc to deploy multiple wiki's and it is
> > working a treat. Only one problem though. Most of our wiki instances are for
> > private access only.
> >
> > So under RIGHTS I have checked "Prevent unregistered users from viewing
> > pages, regardless of the page or space rights" which works exactly how I
> > would expect it too except for one thing, the style does not cary from the
> > wiki onto the login page.
> >
> > I am only new to the xwiki world, if somebody could point me in the right
> > direction (documentation etc) that would be great.
> >
> 
> That's because the style is located in the XWiki.DefaultSkin page. Since
> guests are by definition not allowed to see that page, its style doesn't
> apply.
> 
> You can't really correct the problem easily AFAIK... Since you checked the
> box I don't think adding the view right to unregistered users on the
> XWiki.DefaultSkin page will work but you can still try it out.
> 
> Guillaume
> 
> 
> > Thanks
> > Ben
> >
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> >
> >
> 
> 


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


[xwiki-users] Code snippet to get associated class name for custom object

2010-02-10 Thread Valdis Vītoliņš
Can somebody provide code snippet
how to got associated class name for documents in space
which have added custom objects?

e.g. this simply list different objects in space
{{velocity}}
#set($hql = "where doc.space='Custom' order by doc.name asc")
#set($results = $xwiki.searchDocuments($hql, 0, 0))
#foreach ($item in $results)
* [[$item]]
#end
{{/velocity}}

and I'd like to get class names for different types of listed
docs/objects

Thanks in advance,
Valdis

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


Re: [xwiki-users] Code snippet to get associated class name for custom object

2010-02-10 Thread Valdis Vītoliņš
Maybe it is bad design for custom solution, but for management
simplicity I store different objects
(values for database lists for form selections) in the same space.

Now they are quite many and listing class name for this object would
help.
Your code require iteration over all used classes, and searching for
appropriate documents.
I assume, more efficient way would be starting from documents and
finding their classes.

Another solution would be adding prefix in names, to distinguish them,
but this requires data changes.

Valdis

> On 02/10/2010 05:43 PM, Valdis Vītoliņš wrote:
> > Can somebody provide code snippet
> > how to got associated class name for documents in space
> > which have added custom objects?
> >
> > e.g. this simply list different objects in space
> > {{velocity}}
> > #set($hql = "where doc.space='Custom' order by doc.name asc")
> > #set($results = $xwiki.searchDocuments($hql, 0, 0))
> > #foreach ($item in $results)
> > * [[$item]]
> > #end
> > {{/velocity}}
> >
> > and I'd like to get class names for different types of listed
> > docs/objects
> >
> > Thanks in advance,
> > Valdis
> 
> I'm not sure I understand the question. Do you want to list all 
> documents in a space having an object from a given type?
> 
> ", BaseObject obj where doc.space='Custom' and obj.name=doc.fullName and 
> obj.className='Custom.MyClass'"
> 
> 
> 


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


[xwiki-users] Adding custom object using Xwiki REST service

2010-02-10 Thread Valdis Vītoliņš
Now I have more tricky question -- how to add custom object using Xwiki
REST service.
By browsing existing ones I assume, I can create linked custom object
using POST before, and get object id.
Then I add wiki document using PUT and set relation to previously
created object.

Is it right approach to test?
Are there more recommendations beside
http://platform.xwiki.org/xwiki/bin/view/Features/XWikiRESTfulAPI

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


Re: [xwiki-users] XWord Server URL ?

2010-02-12 Thread Valdis Vītoliņš
Tomcat port number usually is 8180.
Check /usr/share/tomcatx.x/conf/server.xml or /etc/tomcatx.x/server.xml
(or find file server.xml)
and then look for ..HTTP/1.1 Connector on port.. number.

Valdis

> Hi,
> 
> I have installed XOffice 1.1 M1 to edit files on my XWiki 2.1.1.
> 
> My previous XOffice tests were done against a stand alone jetty setup.
> The Server URL was just a simple http://localhost:8090. Now that I
> have deployed XWiki on Tomcat 6.0 I can't seem to figure out the
> Server URL to enter in XWord. For now I use the URL
> http://localhost:8090/xwiki-enterprise-web-2.1.1 in my browser to
> login.
> 
> What am I missing ?
> 
> Thanks
> Simon Glet
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Display a well rendered field

2010-02-15 Thread Valdis Vītoliņš
It seems your default editor is WYSIWYG, but text field is simple text.
You need to set textarea field to FullyRenderedText (Xwiki 1.x version)
or WYSIWYG (2.x version) mode.

Valdis


> Hello all,
> 
> I have a class with text fields. When i want to display the value of one of 
> them, i only have a very long string.
> How can i display it with nice rendering (bold, colors, etc) ? (In edit mode 
> i have the WYSIWYG editor)
> 
> Thank you 
> 
> Christophe Périnaud
> Windows Server 2003 SP2 in a VMWare instance
> Oracle 10g
> Java 1.6.0_12
> Xwiki 2.0.3 from the pack Jetty/HSQL
> 
> 
> 
> 
> This e-mail is intended only for the addressee named above. It does not bind 
> the sender, except in the case of an existing written convention with the 
> addressee. This e-mail may contain material that is confidential and 
> privileged for the sole use of the intended recipient. Any review, reliance 
> or distribution by others or forwarding without express permission is 
> strictly prohibited and may be unlawful. If you are not the intended 
> recipient, please contact the sender and delete all copies.
> 
> While reasonable precautions have been taken to ensure that this e-mail and 
> any attachments are free from any computer virus or similar defect, no 
> liability will be accepted in that respect. Anyone accessing this e-mail must 
> take their own precautions as to security and virus protection.
> 
> KBL European Private Bankers S.A., 43 boulevard Royal L-2955 Luxembourg, 
> R.C.S. Luxembourg B 6395, T (352) 47 97 1
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Display a well rendered field

2010-02-15 Thread Valdis Vītoliņš
Standard ClassSheet template has simpler syntax:
$doc.display("propertyname")

e.g.
{{velocity}}
## You can modify this page to customize the presentation of your
object.
## At first you should keep the default presentation and just save the
document.
= Īsziņa $doc.name =

#set($class = $doc.getObject('Custom.IszinaClass').xWikiClass)
#foreach($prop in $class.properties)
|$prop.prettyName| $doc.display($prop.getName())
#end
{{/velocity}}

and it works seamlessly.
Valdis 

> Thanks Valdis. 
> 
> > 
> > I check the class in the class editor and for this textarea, i don't see 
> > how to change the rendering. Is it in the class or in the call to display 
> > the field ? (i use $doc.display($fieldName, "view") )
> > 
> > I use Xwiki 2.0.3
> > 
> > > -Message d'origine-
> > > De : users-boun...@xwiki.org [mailto:users-boun...@xwiki.org] 
> > > De la part de Valdis Vitolinš
> > > Envoyé : lundi 15 février 2010 13:03
> > > À : XWiki Users
> > > Objet : Re: [xwiki-users] Display a well rendered field
> > > 
> > > It seems your default editor is WYSIWYG, but text field is 
> > > simple text.
> > > You need to set textarea field to FullyRenderedText (Xwiki 
> > > 1.x version)
> > > or WYSIWYG (2.x version) mode.
> > > 
> > > Valdis
> > > 
> > > 
> > > > Hello all,
> > > > 
> > > > I have a class with text fields. When i want to display the 
> > > value of one of them, i only have a very long string.
> > > > How can i display it with nice rendering (bold, colors, 
> > > etc) ? (In edit mode i have the WYSIWYG editor)
> > > > 
> > > > Thank you 
> > > > 
> > > > Christophe Périnaud
> > > > Windows Server 2003 SP2 in a VMWare instance
> > > > Oracle 10g
> > > > Java 1.6.0_12
> > > > Xwiki 2.0.3 from the pack Jetty/HSQL

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


Re: [xwiki-users] Readable only

2010-02-15 Thread Valdis Vītoliņš
Set /xwiki/bin/admin/XWiki/XWikiPreferences?editor=globaladmin§ion=Rights
Unregistered Users: View (yes) only rights.

Valdis

> I would like to have a wiki, which is readable only for unregistered users.
> How can I get rid of the edit button (section) of headers?
> 
> Stefan Bachert
> 
> __
> Do You Yahoo!?
> Sie sind Spam leid? Yahoo! Mail verfügt über einen herausragenden Schutz 
> gegen Massenmails. 
> http://mail.yahoo.com 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] How the change a color on a ColorTheme

2010-02-15 Thread Valdis Vītoliņš

At first, choose color theme in 
/xwiki/bin/admin/XWiki/XWikiPreferences?editor=globaladmin§ion=Presentation
Be careful by changing settings. They can be different for each space.
Be sure you are changing settings for all xwiki (Wiki administration).

Then change chosen one in xwiki/bin/view/ColorThemes/ e.g.
/xwiki/bin/view/ColorThemes/DefaultColorTheme

Color theme is customized Xwiki document. To change it open it in edit
mode,
then change and save.

Valdis

> How the change a color on a ColorTheme?
> 
> I opened one of the ColorTheme. I dont have any idea to chance the color 
> value.
> In the XWiki doc is a screen dump of the ColorTheme with a button and some 
> kind of color selector.
> However, I never see this in my XWiki in life?
> 
> 
> Stefan Bachert
> 
> __
> Do You Yahoo!?
> Sie sind Spam leid? Yahoo! Mail verfügt über einen herausragenden Schutz 
> gegen Massenmails. 
> http://mail.yahoo.com 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] [Call for comments] Edit UI redesign

2010-02-15 Thread Valdis Vītoliņš
As I see that A and B ar not mutually exclusive but complementary.
Correct me If I'm wrong.

Probably when B is used, then panels (at least left panels) should not
be shown at all.

Valdis


> Hi XWiki Users,
> 
> Please help the dev team solve a UI design dilemma. Your feedback is 
> very important, we really need the point of view of all categories of users.
> 
> 
> The context:
> 
> We wish to get rid of the editor panels and integrate their 
> corresponding functionality in the editor itself. There are several 
> reasons for doing this (having all the editor functions in one place, 
> without depending on the panels that might or might not be in the 
> database, having the possibility to integrate the editors in view mode 
> without functionality loss, etc).
> 
> 
> The proposals:
> 
> A) http://dev.xwiki.org/xwiki/bin/Design/ImprovedEdit#HVariantA
> All the information from the side panels is inserted in the main editor 
> in semantically related places
>- the language/translation can be chosen from the content menu
>- the user can change the parent document  by editing the hierarchy
>- the included documents are listed above the content
>- the document syntax can be selected from a field placed near the 
> content textarea; a link to the syntax help page is provided in the same 
> place. Note that the included documents and the page syntax are only 
> visible in the wiki editing mode. Users editing pages in wysiwyg are not 
> bothered with such details.
> 
> B) http://dev.xwiki.org/xwiki/bin/Design/ImprovedEdit#HVariantB
> All the information from the side panels is grouped in an "Advanced 
> options" zone, hidden by default and displayable on the right. This 
> variant is highly similar to what we currently have in edit mode, with 
> the additional possibility to hide it to gain more horizontal space.
> 
> 
> Please comment on these proposals, telling us which works better for 
> you. New ideas are also welcome.
> 
> 
> Thanks in advance for your feedback, which will help us move forward.
> 


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


[xwiki-users] Search criteria for Livetable macro

2010-02-18 Thread Valdis Vītoliņš
What is syntax to add filtering criteria for livetable macro?
http://code.xwiki.org/xwiki/bin/view/Macros/LiveTableMacro
http://platform.xwiki.org/xwiki/bin/view/DevGuide/LiveTable

It seems there should be possibility to add something for $options = ...
part.

Thanks,
Valdis


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


Re: [xwiki-users] Search criteria for Livetable macro

2010-02-18 Thread Valdis Vītoliņš
It seems what I need,
though I couldn't find working templates for back-end macros.
>From pages
http://dev.xwiki.org/xwiki/bin/view/Drafts/XWikiGridComponentTutorial
http://platform.xwiki.org/xwiki/bin/view/DevGuide/LiveTable

I got GridExtensionResultMacros and LiveTableResultsMacros, though
neither  worked for me.

Where can I get necessary macros, to get it working?
(I use xwiki 2.1.1.25889)

Valdis


> If I understand the question correctly, the solution is to insert your 
> own FROM and WHERE info in the search query, as follows:
> 
> ...
> #gridresultwithfilter("" $request.collist.split(",") ", StringProperty 
> examplename" "and examplename.id.id=obj.id and 
> examplename.name='examplename' and doc.space='Tutorials' and 
> doc.name<>'WebHome' and doc.name<>'WebPreferences'")
> ...
> 
> The last 2 parameters are the ones you're looking for. Be sure to add 
> the initial comma in the FROM parameter and the initial "and" in the 
> WHERE parameter.
> 
> See this page for more info (though I think it needs to be expanded with 
> a more exhaustive list of queryable object fields):
> 
> http://platform.xwiki.org/xwiki/bin/view/DevGuide/velocityHqlExamples
> 
> -Joshua
> 
> Valdis Vītoliņš wrote:
> > What is syntax to add filtering criteria for livetable macro?
> > http://code.xwiki.org/xwiki/bin/view/Macros/LiveTableMacro
> > http://platform.xwiki.org/xwiki/bin/view/DevGuide/LiveTable
> > 
> > It seems there should be possibility to add something for $options = ...
> > part.
> > 
> > Thanks,
> > Valdis
> > 
> > 
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Adding custom object using Xwiki REST service

2010-02-18 Thread Valdis Vītoliņš
It can be done in once by setting all object properties (including
template, field names an dvalues).

At first look at code of the xwiki generated submission form, and get
names of all fields.
Then add name=value for properties (e.g. using curl with GET):
curl -u user:password -d
"parent=MyWood.Iszinas&template=Custom.IszinaTemplate&sheet=1&spaceName=MyWood&Custom.IszinaClass_0_datums=18.02.2010+18%3A06%3A44&Custom.IszinaClass_0_darbinieks=%24user&Custom.IszinaClass_0_tips=Custom.Ienakosa&Custom.IszinaClass_0_telefons=26563205&Custom.IszinaClass_0_teksts=&docName=S-100218-180644&action_save=Saglab%C4%81t+un+skat%C4%ABt"
  http://localhost/xwiki/bin/inline/MyWood/S-100218-180645

Do not forget to include ...&action_save=Button_label at the end.
If list boxes are used, use ids for them, not label values.
see more http://curl.haxx.se/ 

Valdis

> Now I have more tricky question -- how to add custom object using Xwiki
> REST service.
> By browsing existing ones I assume, I can create linked custom object
> using POST before, and get object id.
> Then I add wiki document using PUT and set relation to previously
> created object.
> 
> Is it right approach to test?
> Are there more recommendations beside
> http://platform.xwiki.org/xwiki/bin/view/Features/XWikiRESTfulAPI
> 
> Thanks,
> Valdis
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Adding custom object usinf groovy or velocity

2010-02-18 Thread Valdis Vītoliņš
Following velocity allows to create simpe xwiki document:
#set ($mydoc = $xwiki.getDocument("Sandbox.Test1"))
$mydoc.setContent("sdfsdf")
$mydoc.save()

But How can I create custom object?

http://hans.gerwitz.com/projects/snipsnap-to-xwiki
shows some ideas but I can't make it working for me.

Another (awkward) way would be executing external curl command.
How can I do this?

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


Re: [xwiki-users] Adding custom object usinf groovy or velocity

2010-02-18 Thread Valdis Vītoliņš
Many thanks,
that works!

Valdis

> Try this:
> 
> #set($newObj = $doc.newObject("SpaceName.ClassName")) ## creates a new
> object 
> #set($ok = $newObj.set("PropName", $propValue)) ## sets a property in
> the new object
> #set($ok = $doc.save()) ## save the document, and the new object
> 
> 
> On Thu, Feb 18, 2010 at 8:33 PM, Valdis Vītoliņš
>  wrote:
> 
> Following velocity allows to create simpe xwiki document:
> #set ($mydoc = $xwiki.getDocument("Sandbox.Test1"))
> $mydoc.setContent("sdfsdf")
> $mydoc.save()
> 
> But How can I create custom object?
> 
> http://hans.gerwitz.com/projects/snipsnap-to-xwiki
> shows some ideas but I can't make it working for me.
> 
> Another (awkward) way would be executing external curl
> command.
> How can I do this?
> 
> Thanks,
> Valdis
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
> 
> 
> -- 
> Flavius Olaru
> 


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


Re: [xwiki-users] Group Access Rights, File Retrieve, and Livetable Options

2010-02-19 Thread Valdis Vītoliņš
There is another macro #gridresultwithfilter()  similar to live table,
but with query options.
http://dev.xwiki.org/xwiki/bin/view/Drafts/XWikiGridComponentTutorial
http://platform.xwiki.org/xwiki/bin/view/DevGuide/LiveTable

Though it is not documented and I cannot prepare working examples.

For search criteria testing probably will help
http://code.xwiki.org/xwiki/bin/view/Snippets/HQLQueryTesterSnippet

Keep notified about your investigations.

Valdis

> Hey,
> 
> I have a few questions on a variety of topics
> 
> 1. Is there a method that returns the access rights for a given group? I 
> tried to use method hasAccessLevel to return the access rights (at the group 
> level) but it seems that the method only applies for users and not groups.
> To expand on this thought, where are all the group names stored? I've been 
> using hasAccessLevel using XWiki.{groupname} as the parameter, so I am not 
> sure whether I am calling it right.
> 
> 2. It seems that no one has addressed Mike Davis's question, but since I also 
> need to do something similar to what he brought up, I'd like to bring it up 
> again:
> 
> Mike Davis said:
>  "2) Is there a way to remotely access a sql 2005 database from an xwiki
> script?  A groovy wrapper for java jdbc or something.  I want to query
> the database and put the results in a livetable, but the db lives on a
> completely separate server."
> 
> I understand that accessing files depends on the web server you are running 
> xwiki on, but I am almost clueless on how to access information on another 
> server from a web server. I'm not sure if I am asking the right people, but 
> if someone would like to enlighten me, I'd greatly appreciate it.
> 
> 3. Regarding Livetable, I need to create a (huge) table that includes the 
> User field and well as the AllDocs field. What I am trying to do is create a 
> table that will display the access rights for a given user and given 
> document. Livetable is obviously the best option for this kind of task 
> because of its organization, but it seems that I can only use one classname 
> and either display AllDocs or Users on the livetable, not both. 
> 
> Thank you,
> 
> Felix
> 
> 
>   
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Getting a user preference as a list

2010-02-23 Thread Valdis Vītoliņš
Method to get chosen list is .getListValue('value')

Valdis

> Hello,
> 
> I'm trying to get the value of a property in XWikiPreferences of type 
> Database List that has mutiple-select capability. When I do 
> $xwiki.getUserPreference("property_name"), it returns a string that is a 
> representation of the value, so something like:
> 
> [Value1, Value2, Value4]
> 
> However, I need this to be a list so I can check if 
> property.contains("Value4"). Is there an easy way to get a list from a 
> preference, or do I need to go into the XWikiPreferences page, grab the 
> object and get the value from there?
> 
> Thanks,
> 
> Joshua Rieken
> System Software Developer
> 
> Reynolds and Reynolds
> 6700 Hollister | Houston, Texas 77040
> office 713.718.1800 ext. 72459 | mobile 806.584.3004
> joshua_rie...@reyrey.com
> 
> MAKING BUSINESS BETTER.
> 
> NOTE: The information contained in this e-mail is personal and confidential 
> and may be protected by the attorney-client privilege and/or the work product 
> doctrine. It is for the sole use of the intended recipient. Any review, 
> reliance, or distribution by others or forwarding without express permission 
> is strictly prohibited. If you are not the intended recipient, please contact 
> the sender and delete all copies.
> 
> 
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Translations

2010-02-24 Thread Valdis Vītoliņš
I can share my experience as localizer for Xwiki in Latvian.

> Hi,
> some texts used in the login dialog are neither in 
> ApplicationResources_de.properties nor in ApplicationResources.properties
> nor in i10n.xwiki.org. And using i10n.xwiki.org is very ugly and inefficient. 
> You can drink a cup of coffee after sending a request

First few thousand of lines I translated offline using resource file and
it was imported by Ludovic Dubost.
Further improvements/additions I do online. Provided search was not good
enough for me, so I helped to improve it.
Actually I'd like to change it once more because for me searching by
(poorly) translated text, not the key is more usual. What do you think?

To solve issue that site is quite slow, it should be investigated about
caching possibilities, or import/export tool would be nice, but somebody
needs to develop it.
Though, if so many people can live with Windows, i10n.xwiki.org is not
the worst one, which teaches us to manage our time with computer
accordingly ;-)

> The following text is part of the login dialog 
> key:remembermeonthiscomp found in i10n, ApplicationResources(de,default)
> Text:Auf diesem Computer angemeldet bleiben
> 
> However, there are translated texts like "Forgot your username?". Obviously 
> they are not used at this place.
> it seems on the long run I have to check the code directly.

Currently not all labels are made to use external resources, but it is
changing incrementally.

Valdis

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


Re: [xwiki-users] Search for translations

2010-02-24 Thread Valdis Vītoliņš
> >> Actually I'd like to change it once more because for me searching by
> >> (poorly) translated text, not the key is more usual. What do you think?
> >
> > Yes good idea. I could easily do a extended search form I guess like:
> >
> > o search in translated
> > o search in original
> > o search in key

It is already implemented in
http://l10n.xwiki.org/xwiki/bin/view/L10N/Search
I  propose to change "Search translation" field shown in home page 
from key to translated text in panel
http://l10n.xwiki.org/xwiki/bin/view/L10NCode/SearchPanel 
(I have no edit rights to do it myself).


> Hmm i never tried the search before now and indeed it's very slow i
> will see if i can do something to improve it.


Good luck in your investigation!
Valdis
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Translations discussion

2010-02-24 Thread Valdis Vītoliņš
Will the new page
http://l10n.xwiki.org/xwiki/bin/view/Discussions/German
be ok?

Valdis

> Hi,
> 
> id also like to suggest, that we come to some form of cooperation in doing
> the german translation since i did most part of it till yet (and hope that
> not all of it is incorrect german :).
> 
> One question to the developers is there a possibility to have a editable
> page or space in the translation wiki wher translators could share their
> thougts and keep a terminology for their language.
> 
> Thanks
> hel.
> 
> 
> 
> -
> semantic-web.hel.at
> h...@hel.at
> 


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


Re: [xwiki-users] Where to improve the translation, resource file or l10i.xwiki.org

2010-02-28 Thread Valdis Vītoliņš
> Hi,
> 
> I have some question about translation.
> 
> 1. Is the ApplicationResources_zh.properties exported from
> l10i.xwiki.org? But I find the resources file in xwiki 2.2.1 release
> package is not the same as the resource file I get from
> l10i.xwiki.org.

*.properties file generated from l10i.xwiki.org is the most recent one.
IMHO it is regularly 
imported to the xwiki releases, but if active localization is going, it
is always older.

> 2. I think the (Total translations = Empty translations + Outdated
> translations + Translations to review), but in the site I found it is
> not equal all the time, for example,
> Simplified Chinese (zh),
>   Total translations: 2425
>   Empty translations: 477
>   Outdated translations: 29
>   Translations to review: 1454
> 477 + 29 + 1454 = 1960 != 2425. Does this mean the missing 465 items
> are Validated? What is the relationship between total empty and
> outdate translations.

I'm not mathematician and don't care abut sums. I care only care about
empty and outdated ones.

> 3. If I want to improve the translation. Do I modify the resource file
> and submit a patch or I just edit l10i.xwiki.org.

IMHO xwikians don't have elegant tool and they do it manually, so
incremental updates are better done online
in l10i.xwiki.org site.

Valdis

> Thanks.
> 
> Wang Ning
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Localization testing howto for review

2010-03-01 Thread Valdis Vītoliņš
Please review localization testing page
http://l10n.xwiki.org/xwiki/bin/view/L10N/TranslationTesting
Update/move (add links to it) where it is necessary.

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


Re: [xwiki-users] [Proposal] Improving the User Guide documentation

2010-03-01 Thread Valdis Vītoliņš
One of problem with xwiki is that resources are quite distributed.
Due to virtual wikis for www.xwiki.com, www.xwiki.org, dev.xwiki.org,
l10n.xwiki.org
even I am confused (though I have started using xwiki quite long time
ago)
where to find info (except for google) and where to put new entries
(except for comments).

So I see 2 options here, 
1. aggressively normalized content chunks with (as much as possible)
links between them
(it seems current approach but needs more normalizing and linking).
2. very centralized approach with one super entry point (domain
name/page/space),
where all necessary info can be found.

Valdis 


> On Mar 1, 2010, at 11:08 AM, Thomas Mortagne wrote:
> 
> > On Mon, Mar 1, 2010 at 10:58, Silvia Rusu  wrote:
> >> 
> >> Hello,
> >> 
> >> I would like to propose we update the User Guide documentation so that it's
> >> more helpful to users that start using XWiki, whether they are programmers
> >> or not. The purpose of the guide is to get users up to speed with the XWiki
> >> basics, to gather these resources in one place.
> >> 
> >> You can find my proposal for the user guide here:
> >> http://dev.xwiki.org/xwiki/bin/view/Drafts/UserGuide
> >> 
> >> Please feel free to make suggestions for other pages to be included or
> >> changes you think should be made. Remember this is not a TOC for all the
> >> documentation, but rather a selection of links to help you get started with
> >> XWiki.
> > 
> > It should maybe be renamed as "Get Started with XWiki" instead of
> > "User Guide" then.
> 
> Actually it's meant to be a full User Guide to replace the current page at 
> http://enterprise.xwiki.org/xwiki/bin/view/UserGuide/
> (the existing Getting Started guide would disappear).
> 
> Basically the idea is to have a single user guide that starts with some basic 
> feature explanations (the getting started part) and that increases in 
> complexity as you progress through the guide.
> 
> Thanks
> -Vincent
> 
> >> Thanks,
> >> Silvia
> >> 
> >> -
> >> Silvia Rusu
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Questions about XWiki: translations for macros

2010-03-05 Thread Valdis Vītoliņš
>- objects can not be translated (see
> XWIKI-69).
>In my words a page can not be translated if it uses a template. Using
>conditions in macros is not a good workaround for end-users. Is there
>another way to implement this feature ? Do you have any recommendations ?
The approach should be similar to used in Livetable macro. See
http://code.xwiki.org/xwiki/bin/view/Macros/LiveTableMacro

Then in some xwiki page e.g. /xwiki/bin/view/Custom/MacroTranslations
create content:
...
field=Translation
...
hopefully it will work if you will translate page in necessary languages

open 
/xwiki/bin/admin/XWiki/XWikiPreferences?editor=globaladmin§ion=Programming 
and in the field Internationalization Document Bundles set: 
Custom.MacroTranslations


N.B. to Xwikiers

Actually such approach should be supported and documented for
internationalization of new/staged/custom/contributed macros.

Valdis

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


Re: [xwiki-users] Is there a way to modify the values of the options in the select element (html) associated with a Static List?

2010-03-10 Thread Valdis Vītoliņš
Why don't you use database list?
IMHO this is better, especially because then user can modify values
without changing design.
So, use them if there are no other design constraints.

Valdis

> Hi,
> 
> 
> 
> Is there a way to modify the values of the options in the select element
> (html) associated with a Static List?
> 
> I noticed that the values are the same as the text that is shown on the
> list.
> 
> I have:
> 
> * name="SSI-Internal.CreateIssue_0_priority" size="1">*
> 
> *  Show Stopper*
> 
> *  Must Have*
> 
> *  Should Have*
> 
> *  Could Have*
> 
> *  Not In
> Roadmap*
> 
> **
> 
> I want something like:
> 
> * name="SSI-Internal.CreateIssue_0_priority" size="1">*
> 
> *  Show Stopper*
> 
> *  Must Have*
> 
> *  Should Have*
> 
> *  Could Have*
> 
> *  Not In Roadmap*
> 
> **
> 
> 
> 
> I am using the following code to modify the values:
> 
> 
> 
> *valdoc = xwiki.getDocument("SSI-Internal.CreateIssue")*
> 
> *ok = valdoc.updateObjectFromRequest("SSI-Internal.CreateIssue")*
> 
> *
> valdoc.getxWikiClass().get("priority").getPropertyClass().setValues(“a|b|c”)
> *
> 
> 
> 
> Thanks,
> 
> 
> 
> Abel
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Xwiki integration with SMS

2010-03-17 Thread Valdis Vītoliņš
I'm investigating how to integrate Xwiki with SMS sending software.
(see http://en.wikipedia.org/wiki/Short_message_peer-to-peer_protocol )
Have you any thoughts recommendations regarding to tools
(http://smppapi.sourceforge.net/ http://code.google.com/p/jsmpp/ )
approaches, etc?

Thanks in advance,
Valdis
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] xwiki Macro using groovy

2010-03-18 Thread Valdis Vītoliņš
Some time ago we have implemented some proof of concept in:
http://www.ante.lv/xwiki/bin/view/References/
Feel free to investigate it and steal ideas.
(I can provide XAR file, if you are interested).

Valdis

> Hi everyone,
> 
> Thanks so much for your quick answer on my previous question.
> 
> I am trying to write a bibliography/cite macro (I am happy to share
> once it dies something useful). I am writing the macro in a wiki page
> and I am using groovy as scripting language.
> 
> I would like to have access to the URL of an attachment of the page
> the macro is used on. I am doing so by using
> 
> doc.getAttachmentURL(  );
> 
> however, the URL uses the page the Macro is saved in, not the page the
> macro is used on. I think I managed this before using velocity.
> So my question: what would be the right way of accessing the Document
> of the page the macro is placed on?
> 
> 
> Thanks for your help,
> --Alaina
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Is it possible to upgrade a stand alone xwiki enterprise to version 2.2.3

2010-03-23 Thread Valdis Vītoliņš
All pages which are created as new will not be touched.
If you have changed existing Xwiki documents, look at
http://lists.xwiki.org/pipermail/users/2009-December/018731.html

Valdis
P.S. Where is moved content of
http://www.xwiki.org/xwiki/bin/view/FAQ/WhoCanIUpdateXWIKIFromAnOlderVersion ?


> I have a previous version (not sure which one anymore, but it is a few
> months old, not more) of XWiki Enterprise installed as standalone (my IT
> supplier is crap, I know) and I would like to upgrade to the latest version
> (i.e keeping the layout changes I made, which are light ones, but more
> importantly all the pages created already!).
> 
> Is it possible?
> 
> Thanks in advance,
> 
> Xavier
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Is it possible to upgrade a stand alone xwiki enterprise to version 2.2.3

2010-03-23 Thread Valdis Vītoliņš
If customized pages are not too many, you can prepare global Xwiki
export (xar file),
upgrade xwiki instance, then import xar file and select only necessary
pages to import.
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/ImportExport

That should be manageable.

Valdis

> thanks
> 
> that looks a bit complicated for me
> 
> too bad ...
> 
> On Tue, Mar 23, 2010 at 7:37 PM, Sergiu Dumitriu  wrote:
> 
> > On 03/23/2010 07:30 PM, Valdis Vītoliņš wrote:
> > > All pages which are created as new will not be touched.
> > > If you have changed existing Xwiki documents, look at
> > > http://lists.xwiki.org/pipermail/users/2009-December/018731.html
> > >
> > > Valdis
> > > P.S. Where is moved content of
> > >
> > http://www.xwiki.org/xwiki/bin/view/FAQ/WhoCanIUpdateXWIKIFromAnOlderVersion?
> >
> > Name corrected:
> >
> > http://www.xwiki.org/xwiki/bin/FAQ/HowCanIUpdateXWIKIFromAnOlderVersion
> >
> > >
> > >> I have a previous version (not sure which one anymore, but it is a few
> > >> months old, not more) of XWiki Enterprise installed as standalone (my IT
> > >> supplier is crap, I know) and I would like to upgrade to the latest
> > version
> > >> (i.e keeping the layout changes I made, which are light ones, but more
> > >> importantly all the pages created already!).
> > >>
> > >> Is it possible?
> > >>
> > >> Thanks in advance,
> > >>
> > >> Xavier
> >
> >
> > --
> > Sergiu Dumitriu
> > http://purl.org/net/sergiu/
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> >
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] XWiki Logo Challenge

2010-03-26 Thread Valdis Vītoliņš
+3 Proposal 19
+2 Proposal 5
+1 Proposal 16 B

Valdis

> Hi Community,
> 
> The XWiki Logo proposal period is now closed, many thanks to everyone 
> who participated. It is now the time to vote the new logo amongst the 19 
> proposals available here:
> 
> http://dev.xwiki.org/xwiki/bin/Community/LogoChallenge#HProposals
> 
> You can send your vote:
> - on the mailing list, by replying to this e-mail
> - on twitter, in the format: #xwikilogo 
> 
> Don't hesitate to nominate several proposals if you feel that they are 
> really close and you cannot decide for just one. Sometimes, a bunch of 
> fuzzy opinions can lead to a more accurate result.
> 
> IMPORTANT:
> Before choosing a logo based on your personal preference, please try to 
> also ask yourself the following questions:
> - Is it distinctive?
> - Is it easy to remember and recognize?
> - Is the design scalable? Could it (or parts of it) be successfully used 
> in a 16X16 icon? Would it look good on a very large poster?
> - Can it be used (as it is, or adapted) on both light and dark backgrounds?
> - What would it look like in black and white (not just grayscale)? It's 
> ok if some details are lost, but it needs to still look attractive and 
> keep the main features.
> 
> Motivating your vote also helps better understand what qualities a logo 
> evokes in people's minds.
> 
> Also note that the designs are not final, the selected proposal will be 
> further tweaked and perfected, so don't discard a logo just for minor flaws.
> 
> If several proposals come close to being selected, we could organize a 
> second round of voting.
> 
> Please send us your votes before March 31st.
> 
> 
> On 03/01/2010 05:57 PM, Jean-Vincent Drean wrote:
> > Hi XWikiers!
> >
> > It's time to inject new blood in XWiki.org. While discussing about
> > improving its look&  feel we thought it would be a good time to create
> > a new logo for XWiki.org as it's an important part of a website
> > design.
> > We borrowed the current logo from XWiki.com some time ago and, in
> > order to keep the distinction between the company and the Open-Source
> > project clear, we think XWiki.org websites and projects need their own
> > logo.
> >
> > As you may know, we love proposals, that's why we'd like to make the
> > logo design an open challenge, anyone interested can join and a vote
> > amongst the community will determine the winner. Even if the main
> > purpose of the challenge is to have fun, the person whose design gets
> > selected will receive XWiki goodies, including his logo printed on a
> > t-shirt obviously :) The designer of the selected logo will enter the
> > Hall Of Fame, and last but not least reward : the design will be
> > spread wide (XWiki Enterprise is more than 1 downloads/month and
> > XWiki.org web site more than 5 visits a month).
> >
> > The challenge takes place there:
> > http://dev.xwiki.org/xwiki/bin/view/Community/LogoChallenge
> 


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


[xwiki-users] Unneded Blog RSS pages

2010-03-26 Thread Valdis Vītoliņš
I'm looking at access logs and found that my site through all historical
development has 3 blog RSS feeds:

Main/BlogRss - not linked from anywhere but created in 2005
Blog/GlobalBlogRss - linked from global site RSS feed (another is
WebRSS)
Blog/BlogRss - linked from Links panel.

Probably two of them could be removed (i.e. set redirect for some time,
and remove later),

but which one conforms to standard?

Valdis


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


Re: [xwiki-users] FW: A new Wiki install

2010-03-31 Thread Valdis Vītoliņš
I'm still wondering why people run Java applications on Windows. Running
on Linux is much easier.
Don't get me wrong. In 2001 I did presentation in international
conference recommending Sharepoint as a new powerful tool for
collaboration
and knowledge exchange. But that was looong time ago, and I've switched
to Linux and wikis.

In multinational corporations there is "policy" developed by corporate
headquarters 10 years ago that server could be any but Windows,
though I've seen many "underground/semi official" Linux servers "for
customer projects" and that number is growing.

Xwiki runs on windows but from this mailing list I know how tricky
quirks may happen from time to time,
as developers and most of users don't test it.

Valdis


> I have been testing the stand alone enterprise on a windows x64 server 2003 
> box.(still some config and planning to iron out)
> I am ready to make the leap to the enterprise WAR with the jetty container 
> and SQL 2005 as the DB.
> What I need to know is how using X64 and X32 will affect what I do. What are 
> the limitations or advantages of using  sql server/web OS in X64 or X32.
> My production server is windows server 2003 X32?
> 
> Any suggestions are most welcome.
> Many Thanks
> 
> Clinton
> 
> Clinton Louw / Invision Inc | Systems Engineer
> *: 2160 Satellite Blvd.Suite 225 Duluth, GA 30096
> *: 770-325-0457 | *: 
> clinton.l...@invisioninc.com
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] Your ideas to save number in custom object using Groovy code?

2010-04-09 Thread Valdis Vītoliņš
I'm trying to save custom object values, and can only for strings using
advanced script from
http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial 
For Number type (tried integer and long), I couldn't save value in any
way. Tried explicitly define as 
int daudzums
and 
daudzums = Integer.parseInt(string)

I exhausted my ideas and would like to get some more :-/

Exception:
2010-04-09 19:07:40,254
[http://85.254.250.23/xwiki/bin/preview/MyWood/S-100409-181257]
ERROR .AbstractFlushingEventListener  - Could not synchronize database
state with session 
org.hibernate.StaleObjectStateException: Row was updated or deleted by
another transaction (or unsaved-value mapping was incorrect):
[com.xpn.xwiki.objects.IntegerProperty#

4
]
at
org.hibernate.persister.entity.AbstractEntityPersister.check(AbstractEntityPersister.java:1769)
at
org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2412)
at
org.hibernate.persister.entity.AbstractEntityPersister.updateOrInsert(AbstractEntityPersister.java:2312)
at
org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2612)
at
org.hibernate.action.EntityUpdateAction.execute(EntityUpdateAction.java:96)
at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:279)
at
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:263)
at
org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:168)
at
org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:298)
at
org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:338)
at
org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
at
com.xpn.xwiki.store.XWikiHibernateBaseStore.endTransaction(XWikiHibernateBaseStore.java:854)
at
com.xpn.xwiki.store.XWikiHibernateBaseStore.endTransaction(XWikiHibernateBaseStore.java:825)
at
com.xpn.xwiki.store.XWikiHibernateStore.saveXWikiDoc(XWikiHibernateStore.java:598)
at
com.xpn.xwiki.store.XWikiCacheStore.saveXWikiDoc(XWikiCacheStore.java:181)
at
com.xpn.xwiki.store.XWikiCacheStore.saveXWikiDoc(XWikiCacheStore.java:174)
at com.xpn.xwiki.XWiki.saveDocument(XWiki.java:1325)
at com.xpn.xwiki.api.Document.saveDocument(Document.java:1751)
at com.xpn.xwiki.api.Document.save(Document.java:1715)
at com.xpn.xwiki.api.Document.save(Document.java:1704)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite
$PojoCachedMethodSiteNoUnwrapNoCoerce.invoke(PojoMetaMethodSite.java:229)
at
org.codehaus.groovy.runtime.callsite.PojoMetaMethodSite.call(PojoMetaMethodSite.java:52)
at
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:40)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:117)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:121)
at LoggingEventListener.createIzstrade(Script15.groovy:105)
at LoggingEventListener$createIzstrade.callCurrent(Unknown Source)
at
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:44)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:143)
at LoggingEventListener.doSMS(Script15.groovy:79)
at LoggingEventListener$doSMS.callCurrent(Unknown Source)
at
org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:44)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:143)
at
org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:151)
at LoggingEventListener.onEvent(Script15.groovy:27)
at
org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:269)
at
org.xwiki.observation.internal.DefaultObservationManager.notify(DefaultObservationManager.java:243)
at com.xpn.xwiki.XWiki.saveDocument(XWiki.java:1352)
at com.xpn.xwiki.web.SaveAction.save(SaveAction.java:176)
at com.xpn.xwiki.web.SaveAction.action(SaveAction.java:193)
at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:213)
at com.xpn.xwiki.web.XWikiAction.execute(XWikiAction.java:115)
at
org.apache.struts.acti

Re: [xwiki-users] Your ideas to save number in custom object using Groovy code?

2010-04-09 Thread Valdis Vītoliņš
Investigating
http://platform.xwiki.org/xwiki/bin/view/DevGuide/DatabaseSchema and
trying other number formats got it working for float (xwikifloats
table).
Groovy code:
..
Float daudzums
daudzums = Float.parseFloat(string)
...

Actually I need only integer eg 11 in place of 11.0 but this is minor
issue.
I suspect there is some misuse between int and Integer for integer
types.

Valdis

> I'm trying to save custom object values, and can only for strings
> using advanced script from
> http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial 
> For Number type (tried integer and long), I couldn't save value in any
> way. Tried explicitly define as 
> int daudzums
> and 
> daudzums = Integer.parseInt(string)
> 
> I exhausted my ideas and would like to get some more :-/
> 
> Exception:

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


Re: [xwiki-users] XWiki Logo Challenge, Round 2

2010-04-12 Thread Valdis Vītoliņš
Agree that small icon for
http://dev.xwiki.org/xwiki/bin/download/Community/LogoChallengeRound2/final1.png
looks good, but for bigger sizes it looks for me as squirrel with
flightskin :-)

Therefore I choose 16 with straight W as it seems more ordered.
http://dev.xwiki.org/xwiki/bin/download/Community/LogoChallengeRound2/16-default-straight.png

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


Re: [xwiki-users] Creating class properties with groovy

2010-04-12 Thread Valdis Vītoliņš
Similar question has appeared in this list earlier with no good answer.
Though I suspect, this approach seems necessary is due to weak design.
Can you describe use case why it seems necessary in place of database
list,
where you can set hql query for filtering necessary elements?

Valdis

> I want to create properties for a new class on a blank document with groovy.  
> I can do the following:
> 
> def doc = xwiki.getDocument("space.docname")
> c = doc.getxWikiClass();
> 
> and look at elements of a class that already exists by doing:
> 
> prop = c.get('propertyname')
> 
> propToEdit = prop.getPropertyClass
> 
> propToEdit.setValues('a|b|c')
> 
>  
> 
> But, how can I add a new property to a class that has no existing 
> properties/fields?
> 
>  
> 
> Thanks,
> 
> -Mike
> 
> _
> The New Busy is not the old busy. Search, chat and e-mail from your inbox.
> http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_3
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] [xwiki-devs] XWiki Logo Challenge, Round 2

2010-04-14 Thread Valdis Vītoliņš
Readability is better, but for me upper right backgoing "serif"  for w
seems unnecessary.
In place of (ascii art):
\//  \
/\\/\/iki

only in this way:
\/
/\\/\/iki

Then X can be bigger and w can be aligned with k. 
What do you think? 

Valdis

> I completely agree with Marius, I would also add that since this is a
> Community project, it should have a Community logo !
> Since 16 has receive many votes now, and that I also agree with
> Vincent,
> Ludovic and others, it is not readable enough, I have made an
> alternative
> design: W-angle. My feeling was that the W is difficult to read, so my
> proposal try to keep the style and reworked it. There is also small
> changes
> in spacing, and a different powered by button.
> 
> Here is almost all that was requested in a proposal with this
> variable:
> http://dev.xwiki.org/xwiki/bin/download/Community/LogoChallengeRound2/16%2Dwangle%2Ddefault.png
> 
> I really hope that if the logo 16 is chosen, my proposal could help in
> mitigating the disappointment of those that really find it
> unacceptable.
> 
> WDYT ?
> 
> Denis 
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] [xwiki-devs] XWiki Logo Challenge, Round 2

2010-04-20 Thread Valdis Vītoliņš
We should believe in evolution, not in intelligent design ;-)

For me topology (i.e. shapes of character) looks good, though I'd like
right part for w parallel to slope parts of "X" and "k", with "iki" size
adjusted accordingly
(probably they need to be smaller then).

Wouldn't it be better?

Valdis

> Hello,
> 
> What do you think about this:
> http://dev.xwiki.org/xwiki/bin/download/Community/LogoChallengeRound2/16-variation-engineering.png
> ?
> 
> Raluca.
> ...
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


[xwiki-users] $response.sendRedirect with status 301

2010-04-22 Thread Valdis Vītoliņš
Xwiki allows to redirect from one xwiki page to other using
$response.sendRedirect("http://new_url";) code.
Though response header status ir 302 (found, i.e. moved temporarily),
but I need 301 (moved permanently).
Is it way to set this status for response?

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


Re: [xwiki-users] Why the "created" and "last modified" time are wrong?

2010-04-28 Thread Valdis Vītoliņš
Please add following code in some page (xwiki 1.0 syntax)

$datetool.get('dd.MM. HH:mm')

Save and check what date is shown in page.

If shown time is wrong, then server simply doesn't have correct time
and/or time zone.

Valdis

> Hi All,
> 
> I have installed "XWiki Enterprise 2.2.1.27354" on my laptop, and found that
> after created or modified the document, the "created" and "last modified"
> time are wrong!
> 
> For example, my local time is "2010/04/28, 22:08", but the "date" of the
> document I just created is "2010/04/28, 09:38".  My local time zone is
> "Beijing, China", UTC/GMT +8 hours.
> 
> How could I solve this issue? You comments are welcome!
> 
> Island
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] help

2010-05-10 Thread Valdis Vītoliņš
Xwiki doesn't send e-mail directly but rather use SMTP server (sendmail,
postfix in Linux systems) which by default
runs on the same host where Xwiki and listens on port No 25.
Go on Xwiki- Administer Xwiki- General and there should be ~ like:
...
SMTP
Server: 127.0.0.1
Port:25 or nothing (as 25 is default value).
I have no clue how to set up SMTP server on Mac,
but you can set external SMTP server e.g. some of what you use for your
e-mail.

Valdis

> hello !!
> 
>   i want to work on Xwiki Workspace and when i'm trying to invit users by
> Mail i got this message:
> 
> *Error number 101007 in 101: Sending notification email failed Wrapped
> Exception: Could not connect to SMTP host: 587, port: 25*
> 
> I am a beginner and i have no idea of what i have to do .
> 
> by the way, i'm working on MAc OSX 10.5.8, and my FAI is FREE. i don't know
> if it change something.
> 
> 2 questions :
> 
> 1-how can i fix this and send mail invitatation to new users?
> 2-can you explain me how to go from the intranet to the internet?
> 
> thanks and long life to Xwiki ;)


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


[xwiki-users] Problem with velocity code structuring macro invocation and variables

2013-03-28 Thread Valdis Vītoliņš
I'm working with several forms and struggle with Velocity code
organisation.
1. I'd like to put the same code for e.g. regexp form validation in one
page and just include it from other (ClassSheet) pages.  Following
http://platform.xwiki.org/xwiki/bin/view/DevGuide/Creating+a+form+with
+validation+and+tooltips valdidation works fine, when
#macro(showallerrors) macro is included in ClassSheet page, though it
doesn't work, when macro in ClassSheet is included from other file (e.g.
putting macro in VelocityScripts page and writing in ClassSheet:
{{include reference="VelocityScripts"/}} or {{include document...)

It works though, if macro is put in ../xwiki/templates/macros.vm file.

2. As velocity cannot use passing variables by reference, I'd like to
create own "global" velocity variable similar to $isGuest, $hasComment,
$hasAdmin, etc. I tried to set this in xwikivars.vm, but it didn't
work. 

Any suggestions are welcome.

Thanks!
Valdis


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


Re: [xwiki-users] Problem with velocity code structuring macro invocation and variables

2013-03-28 Thread Valdis Vītoliņš
> 1. I'd like to put the same code for e.g. regexp form validation in one
> page and just include it from other (ClassSheet) pages.  Following
> http://platform.xwiki.org/xwiki/bin/view/DevGuide/Creating+a+form+with
> +validation+and+tooltips valdidation works fine, when
> #macro(showallerrors) macro is included in ClassSheet page, though it
> doesn't work, when macro in ClassSheet is included from other file (e.g.
> putting macro in VelocityScripts page and writing in ClassSheet:
> {{include reference="VelocityScripts"/}} or {{include document...)
> It works though, if macro is put in ../xwiki/templates/macros.vm file.
Found it out myself. Trick was, that include section should be before
velocity in ClassSheet. E.g.
{{include reference="VelocityScripts"/}}
{{velocity}}
...
> 
> 2. As velocity cannot use passing variables by reference, I'd like to
> create own "global" velocity variable similar to $isGuest, $hasComment,
> $hasAdmin, etc. I tried to set this in xwikivars.vm, but it didn't
> work.
Found that I can set value in cookie with Groovy:
{{groovy}}
import javax.servlet.http.*
Cookie mycookie = new Cookie("mycookie","myvalue")
mycookie.setPath("/")
mycookie.setMaxAge(-1)
xcontext.getContext().getResponse().addCookie(mycookie)
{{/groovy}}

and then I can get it as global value in xwikivars.vm
#set($myvalue=$xwiki.getUserPreferenceFromCookie('mycookie'))

And then I can get $myvalue from any other page.

Valdis

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


Re: [xwiki-users] SSO/SAML: issue with example provided on Github

2013-03-29 Thread Valdis Vītoliņš
Nicolas,
If you'd be able to rebuild this module that it at least compiles and
does something, I'd also be interested in trying it and contributing to
its development.

Valdis
> Hi Nicolas,
> 
> If I remember correctly I wrote this authenticator and I think it requires
> some code in XWiki pages to manage the redirects but I don't think I have
> this code anymore.
> Plus it was for one custom SAML server and has not been tested with
> multiple ones.
> 
> In any case it's a good basis for starting a SAML authenticator.
> If you are coding against a more widespread SAML server, do contribute your
> code :)
> You can takeover the module fully as no backwards compatibility is needed.
> 
> Ludovic
...

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


Re: [xwiki-users] SSO/SAML: issue with example provided on Github

2013-03-29 Thread Valdis Vītoliņš
I agree in general,
but devil is in details.

If I have usual time constrained project, and have to ship something in,
say, two months; then I have to develop anything that works, not the
best solution. I have looked to some of these projects, though currently
integration with these requires too much learning project internalities
to be achievable in short-term project.
I'd like to help build something, that could be deployable by putting
some jar file and writing settings in xwiki.cfg, but I'm not experienced
enough and have no time to go in long and deep custom development.

Valdis 
> Just a comment.. (I'm a list watcher 99.9% of the time)
> 
> XWIKI will work just fine with SAML products that engage at the
> container level.. You just use a HTTP auth type authenticator which 
> there are a few out there in the contributions area.
> 
> My advice would be to NOT write to the SAML protocol where this gets
> really intricate.. but to just let the known to work SAML products do
> their thing. Pulling the SAML bits into XWIKI does not buy you anything
> intricate to the product and just adds much more room for error on the
> authenticator.
> 
> People wanting to implement their own SAML stack inside 'web appX'
> is a topic that always comes up on some of the lists I'm on and the 
> SAML people always say there is really no reason to do this.. o
> 
> IMO leave the SAML bits to saml products** and use a http authenticator
> that you like.
> 
> ** Just to name a few:
>   - http://simplesamlphp.org/ ,
>   - http://shibboleth.net/ ,
>   - https://github.com/guanxi/guanxi-sp-guard ,
> 
> 
> --
> thanks
>   kevin.foote
> 
> On Fri, 29 Mar 2013, Valdis Vītoliņš wrote:
> 
> > Nicolas,
> > If you'd be able to rebuild this module that it at least compiles and
> > does something, I'd also be interested in trying it and contributing to
> > its development.
> >
> > Valdis
> >> Hi Nicolas,
> >>
> >> If I remember correctly I wrote this authenticator and I think it requires
> >> some code in XWiki pages to manage the redirects but I don't think I have
> >> this code anymore.
> >> Plus it was for one custom SAML server and has not been tested with
> >> multiple ones.
> >>
> >> In any case it's a good basis for starting a SAML authenticator.
> >> If you are coding against a more widespread SAML server, do contribute your
> >> code :)
> >> You can takeover the module fully as no backwards compatibility is needed.
> >>
> >> Ludovic
> > ...
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> >
> ___ users mailing list 
> users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] How to package all necessary jars for xwiki-authentication-saml?

2013-03-29 Thread Valdis Vītoliņš
Thanks, Thomas,
I tried
https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
again and now it compiled successfully. Though when tried to access WebHome 
page I got
exception, from which IMHO important part is:
...
Caused by: 
java.lang.NoClassDefFoundError:org/opensaml/xml/security/credential/Credential

And I assume it is because I didn't put all necessary jar files in lib folder.
Knowing bash better than J2EE, I copied all files which I got from 
~/m2/repository to /lib,
but then Xwiki didn't start at all...

How can I build  xwiki-authentication-saml with all necessary dependencies?

Thanks, and happy Easter!
Valdis








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


Re: [xwiki-users] SSO/SAML: issue with example provided on Github

2013-04-01 Thread Valdis Vītoliņš
Kevin,
can you provide some links to specific how-tos, which some web-savvy
SAML-beginner could follow?
I started with this option, but then struck with too many velocity code
for checking how to differ all these Xwiki.Guests each to other...
Now I'm checking
https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
Which I managed to work. Xwkik-authentication-saml will require more
work with SAML implementation itself, though I can rely on Xwiki
built-in security then.

Valdis
> If that is really the case then sticking xwiki in a tomcat container and
> fronting with apache / mod_shib and using http authenticator is by far the 
> simplest way to get SAML auth to your Xwiki.. this would take about a 
> day or two assuming you have a working SAML environment Identity Provider /
> Federation wise.
> 
> re/writing a true SAML compliant authenticator is (im going to bet) far
> more time consuming.. you have to deal with all the constraints and bit
> level SAML which is where the brunt of the security comes from.. and the
> registration and management of metadata.. etc.. etc..
> 
> 
> --
> thanks
>   kevin.foote
> 
> On Fri, 29 Mar 2013, Valdis Vītoliņš wrote:
> 
> > I agree in general,
> > but devil is in details.
> >
> > If I have usual time constrained project, and have to ship something in,
> > say, two months; then I have to develop anything that works, not the
> > best solution. I have looked to some of these projects, though currently
> > integration with these requires too much learning project internalities
> > to be achievable in short-term project.
> > I'd like to help build something, that could be deployable by putting
> > some jar file and writing settings in xwiki.cfg, but I'm not experienced
> > enough and have no time to go in long and deep custom development.
> >
> > Valdis 
> >> Just a comment.. (I'm a list watcher 99.9% of the time)
> >> 
> >> XWIKI will work just fine with SAML products that engage at the
> >> container level.. You just use a HTTP auth type authenticator which 
> >> there are a few out there in the contributions area.
> >> 
> >> My advice would be to NOT write to the SAML protocol where this gets
> >> really intricate.. but to just let the known to work SAML products do
> >> their thing. Pulling the SAML bits into XWIKI does not buy you anything
> >> intricate to the product and just adds much more room for error on the
> >> authenticator.
> >> 
> >> People wanting to implement their own SAML stack inside 'web appX'
> >> is a topic that always comes up on some of the lists I'm on and the 
> >> SAML people always say there is really no reason to do this.. o
> >> 
> >> IMO leave the SAML bits to saml products** and use a http authenticator
> >> that you like.
> >> 
> >> ** Just to name a few:
> >>   - http://simplesamlphp.org/ ,
> >>   - http://shibboleth.net/ ,
> >>   - https://github.com/guanxi/guanxi-sp-guard ,
> >> 
> >> 
> >> --
> >> thanks
> >>   kevin.foote
> >> 
> >> On Fri, 29 Mar 2013, Valdis Vītoliņš wrote:
> >> 
> >> > Nicolas,
> >> > If you'd be able to rebuild this module that it at least compiles and
> >> > does something, I'd also be interested in trying it and contributing to
> >> > its development.
> >> >
> >> > Valdis
> >> >> Hi Nicolas,
> >> >>
> >> >> If I remember correctly I wrote this authenticator and I think it 
> >> >> requires
> >> >> some code in XWiki pages to manage the redirects but I don't think I 
> >> >> have
> >> >> this code anymore.
> >> >> Plus it was for one custom SAML server and has not been tested with
> >> >> multiple ones.
> >> >>
> >> >> In any case it's a good basis for starting a SAML authenticator.
> >> >> If you are coding against a more widespread SAML server, do contribute 
> >> >> your
> >> >> code :)
> >> >> You can takeover the module fully as no backwards compatibility is 
> >> >> needed.
> >> >>
> >> >> Ludovic
> >> > ...
> >> >
> >> > ___
> >> > users mailing list
> >> > users@xwiki.org
> >> > http://lists.xwiki.org/mailman/listinfo/users
> >> >
> >> ___ users mailing list 
> >> users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users
> >
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> ___ users mailing list 
> users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] How to package all necessary jars for xwiki-authentication-saml?

2013-04-01 Thread Valdis Vītoliņš
Thanks, Thomas!
I managed to get it working. With "mvn dependency:copy-dependencies" I
got bunch of jars, most of them were older versions of these which my
Xwiki 4.5 had already (If it could be improved with adjusted dependency
versions, it would be great.) I didn't use them, except those which
seemed "new ones". Now my Xwiki runs with some warnings, but at least it
works. Of course, it doesn't work with specific SAML identity provider,
but this is another story.

Valdis
> You would need to modify the pom.xml for this but no need to create a
> big jar (it's also not very clean). You can use mvn
> dependency:copy-dependencies to get all dependencies of your jar in
> target/dependencies and select the one you don't have in your XE
> instance. Make sure to pull first because I modified a bit the
> opensaml dependency which was "provided".
> 
> On Fri, Mar 29, 2013 at 10:29 PM, Valdis Vītoliņš
>  wrote:
> > Thanks, Thomas,
> > I tried
> > https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
> > again and now it compiled successfully. Though when tried to access WebHome 
> > page I got
> > exception, from which IMHO important part is:
> > ...
> > Caused by: 
> > java.lang.NoClassDefFoundError:org/opensaml/xml/security/credential/Credential
> >
> > And I assume it is because I didn't put all necessary jar files in lib 
> > folder.
> > Knowing bash better than J2EE, I copied all files which I got from 
> > ~/m2/repository to /lib,
> > but then Xwiki didn't start at all...
> >
> > How can I build  xwiki-authentication-saml with all necessary dependencies?
> >
> > Thanks, and happy Easter!
> > Valdis
> >
> >
> >
> >
> >
> >
> >
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> 
> 
> 


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


[xwiki-users] How to solve Xwiki SAML authentication

2013-04-11 Thread Valdis Vītoliņš
I found out that Xwiki SAML module from
https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
differs significantly from what I have. It works according to:
http://docs.oasis-open.org/wsfed/federation/v1.2/os/ws-federation-1.2-spec-os.html
And is implemented in .Net:
http://msdn.microsoft.com/en-us/library/ee517291.aspx
http://msdn.microsoft.com/en-us/library/bb498017.aspx
http://msdn.microsoft.com/en-us/library/bb608217.aspx

Even though by standard I should use location parameter in response
parameters, actually it can be invoked with GET/POST parameters, e.g.
simply by following:
https://...gov.lv/.../default.aspx?wa=wsignin1.0&wtrealm=http%3A%2F%
2F11.22.33.44%2Fxwiki
where gov.lv is authentication federation service, and  11.22.33.44 is
my xwiki site.

Then after authentication service redirects back to xwiki with POST
parameters:
wa=
wsignin1.0
wresult=
=
http://docs.oasis-open.org/ws-sx/ws-trust/200512";>


http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";>2013-04-11T12:41:15.525Z
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";>2013-04-11T13:41:15.525Z

http://schemas.xmlsoap.org/ws/2004/09/policy";>
http://www.w3.org/2005/08/addressing";>
http://11.22.33.44/xwiki



http://...gov.lv/trust";
IssueInstant="2013-04-11T12:41:15.525Z"
xmlns:saml="urn:oasis:names:tc:SAML:1.0:assertion">


http://11.22.33.44/xwiki





urn:oasis:names:tc:SAML:1.0:cm:bearer



http://schemas.xmlsoap.org/ws/2005/05/identity/claims";>
112233-12345

http://schemas.xmlsoap.org/ws/2005/05/identity/claims";>
VALDIS

http://schemas.xmlsoap.org/ws/2005/05/identity/claims";>
VĪTOLIŅŠ





urn:oasis:names:tc:SAML:1.0:cm:bearer




http://www.w3.org/2000/09/xmldsig#";>

http://www.w3.org/2001/10/xml-exc-c14n#"; />
http://www.w3.org/2000/09/xmldsig#rsa-sha1"; />


http://www.w3.org/2000/09/xmldsig#enveloped-signature"; />
http://www.w3.org/2001/10/xml-exc-c14n#"; />

http://www.w3.org/2000/09/xmldsig#sha1"; />
HU3/uQFbvSciSkPXxQURI+hUkNU=


...

http://www.w3.org/2000/09/xmldsig#";>

...






...Bla, bla, bla...
=

Am I right, that I need to change:

1. showLogin() where most of authRequest.set... seems unnecessary,

2. checkSAMLResponse() where I need to do
request.getParameter("wresult") and somehow extract out necessary data
and check them from this XML.

Thanks for any hints!
Valdis



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


[xwiki-users] Body attributes are lost when apache proxy filter is used

2013-04-22 Thread Valdis Vītoliņš
I'm working on shortening Xwiki instance URLs
(see details in http://odo.lv/Recipes/XwikiShortURLs_en )
and strangely I can't do it for newer Xwiki instance
(it works for odo.lv which uses 2.7 version).

I found out that HTML is broken, when proxy server rewrites hyperlinks for 
preduced XHTML
(SetOutputFilter proxy-html
ProxyHTMLURLMap /xwiki/bin/view/ /
direcives in apache2.conf)

Then it changes .. to simple .. element without attributes.

Only weakly related thing I found is that could be related is:
http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxybadheader

I suspect it somehow is related on how header is finished and body is started.
Can you suggest any ideas?

Thanks!
Valdis





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


Re: [xwiki-users] Body attributes are lost when apache proxy filter is used — solved

2013-04-24 Thread Valdis Vītoliņš
I found that problem was too many continuous spaces between tags in
header part.

If amount of spaces was more than 1000, mod_proxy_html module wrongly
assumed that head part is finished, arbitrary closed head and opened
body without attributes (and then ignored original one).

As the most part of spaces is produced by colorThemeInit.vm foreach
loops, I replaced each pair of leading spaces with only one.
(Note that increasing ProxyHTMLBufSize didn't help.)

Valdis

> On Mon, Apr 22, 2013 at 8:17 PM, Valdis Vītoliņš  
> wrote:
> > I'm working on shortening Xwiki instance URLs
> > (see details in http://odo.lv/Recipes/XwikiShortURLs_en )
> > and strangely I can't do it for newer Xwiki instance
> > (it works for odo.lv which uses 2.7 version).
> >
> > I found out that HTML is broken, when proxy server rewrites hyperlinks for 
> > preduced XHTML
> > (SetOutputFilter proxy-html
> > ProxyHTMLURLMap /xwiki/bin/view/ /
> > direcives in apache2.conf)
> >
> > Then it changes .. to simple .. element without attributes.
> >
> > Only weakly related thing I found is that could be related is:
> > http://httpd.apache.org/docs/2.2/mod/mod_proxy.html#proxybadheader
> >
> 
> > I suspect it somehow is related on how header is finished and body is 
> > started.
> 
> We have web standards validation tests that ensure the HTML produced
> for the default wiki pages (at least) is valid, so I believe this is a
> bug in the proxy filter. You can pass the HTML produced by your wiki
> page to an XHTML validator like http://validator.w3.org/ to double
> check.
> 
> Hope this helps,
> Marius
> 
> > Can you suggest any ideas?
> >
> > Thanks!
> > Valdis
> >
> >
> >
> >
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] java.lang.ClassCastException: com.xpn.xwiki.doc.XWikiAttachment cannot be cast to com.xpn.xwiki.api.Attachment

2013-04-25 Thread Valdis Vītoliņš
I'm writing custom listener to send e-mail after document updates
according to:
http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial 
and: 
http://xwiki.475771.n2.nabble.com/Send-an-email-in-an-event-listener-td7579175.html

Although adding attachment is working in Velocity as described in:
http://extensions.xwiki.org/xwiki/bin/view/Extension/Mail+Sender+Plugin 

Similar approach in Groovy raises exception:

java.lang.ClassCastException: com.xpn.xwiki.doc.XWikiAttachment cannot
be cast to com.xpn.xwiki.api.Attachment
at
com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.createMimeMultipart(MailSenderPlugin.java:391)
 ~[xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.createMimeMessage(MailSenderPlugin.java:327)
 ~[xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMails(MailSenderPlugin.java:726)
 ~[xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMail(MailSenderPlugin.java:673)
 ~[xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMail(MailSenderPlugin.java:659)
 ~[xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPluginApi.sendMail(MailSenderPluginApi.java:171)
 [xwiki-platform-mailsender-4.5.jar:na]
at
com.xpn.xwiki.plugin.mailsender.MailSenderPluginApi.sendTextMessage(MailSenderPluginApi.java:98)
 [xwiki-platform-mailsender-4.5.jar:na]
at com.xpn.xwiki.plugin.mailsender.MailSender
$sendTextMessage.call(Unknown Source)
[xwiki-platform-mailsender-4.5.jar:na]
at EmailSenderListener.onEvent(Script22.groovy:34) [script:na]
...
and line is: def attachments = source.getAttachmentList()

What should I do?

Thanks!
Valdis

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


Re: [xwiki-users] redirecting 302 responses

2013-04-27 Thread Valdis Vītoliņš
Ricardo,
if your intention is to shorten Xwiki URLs permanently,
look at http://odo.lv/Recipes/XwikiShortURLs_en

BTW, I have question to Xwiki developers — why status 302 (found) is
used?
IMHO, to train crawlers for changes, 301 (moved permanently) seems more
appropriate.

Valdis
> Oops! Please, see below!
> 
> > 
> > From: users-boun...@xwiki.org [users-boun...@xwiki.org] On Behalf Of 
> > Rodriguez Fernandez, Ricardo Julio
> > Sent: 27 April 2013 11:21
> > To: users@xwiki.org
> > Subject: [xwiki-users] redirecting 302 responses
> 
> > Hi!
> >
> > I more or less understand how URLs to missing/wrong/moved XWiki pages work
> > involving docdoesnotexist.vm, but I'm still not able to modify this 
> > behavior by
> > reading/taking into account values of request/responses exchanges between 
> > client and server.
> >
> > For instance: I would like to redirect a number of "short" URLs like this...
> >
> > http://www.idisantiago.es/BIS2013
> >
> > to a set of given XWiki pages. Currently I can, and I did, a redirection of 
> > all of them
> > to a single page by modifying Main.DocumentDoesNotExist this way...
> >
> > {{velocity}}
> > $response.sendRedirect($xwiki.getURL("BIS2013.Schedule"))
> > {{/velocity}}
> >
> > But I'm not able to find the way of using request's name and status in 
> > Velocity #if().
> > Please, see attached file. I found a number of what I consider related 
> > information dealing with
> > $response, $request, URL resolution, URL mappings and so on, so forth, but 
> > I 'm afraid this is
> > too much for me to digest!
> 
> Sorry! I forgot that attachments are filtered out of the list! Here it is the 
> referenced image...
> 
> http://www.idisantiago.es/bin/download/ICT/Request/BIS2013.302Response.png
> 
> Thanks!
> 
> > Please, could anybody point me in the right direction? Am I completely lost?
> >
> > Thanks for your help!!!
> >
> > Ricardo
> >
> 
> --
> Ricardo Rodríguez
> Research Management and Promotion Technician
> Technical Secretariat
> Health Research Institute of Santiago de Compostela (IDIS)
> http://www.idisantiago.es
> 
> 
> Nota: A información contida nesta mensaxe e os seus posibles documentos 
> adxuntos é privada e confidencial e está dirixida únicamente ó seu 
> destinatario/a. Se vostede non é o/a destinatario/a orixinal desta mensaxe, 
> por favor elimínea. A distribución ou copia desta mensaxe non está autorizada.
> 
> Nota: La información contenida en este mensaje y sus posibles documentos 
> adjuntos es privada y confidencial y está dirigida únicamente a su 
> destinatario/a. Si usted no es el/la destinatario/a original de este mensaje, 
> por favor elimínelo. La distribución o copia de este mensaje no está 
> autorizada.
> 
> See more languages: http://www.sergas.es/aviso_confidencialidad.htm
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] redirecting 302 responses

2013-04-28 Thread Valdis Vītoliņš
Ricardo, then look also at:
http://platform.xwiki.org/xwiki/bin/view/Main/ShortURLs

Valdis
> Thanks, Vladis! Please, read below...
> 
> > 
> > From: users-boun...@xwiki.org [users-boun...@xwiki.org] On Behalf Of Valdis 
> > Vītoliņš [valdis.vitol...@odo.lv]
> > Sent: 27 April 2013 13:30
> > To: XWiki Users
> > Subject: Re: [xwiki-users] redirecting 302 responses
> >
> > Ricardo,
> > if your intention is to shorten Xwiki URLs permanently,
> > look at http://odo.lv/Recipes/XwikiShortURLs_en
> >
> 
> Your solution seems great, but I'm afraid I can't use it now: currently, I've 
> no Apache web server behind the scene. Tomcat is directly serving on port 80. 
> I know this is not a desirable situation, but it is how this server is 
> running right now. So, I keep struggling to find a solution "within" XWiki. 
> Any new idea will be welcome!
> 
> 
> > BTW, I have question to Xwiki developers — why status 302 (found) is
> > used?
> > IMHO, to train crawlers for changes, 301 (moved permanently) seems more
> > appropriate.
> >
> > Valdis
> 
> 
> >> Oops! Please, see below!
> >>
> >> > 
> >> > From: users-boun...@xwiki.org [users-boun...@xwiki.org] On Behalf Of 
> >> > Rodriguez Fernandez, Ricardo Julio
> >> > Sent: 27 April 2013 11:21
> >> > To: users@xwiki.org
> >> > Subject: [xwiki-users] redirecting 302 responses
> >>
> >> > Hi!
> >> >
> >> > I more or less understand how URLs to missing/wrong/moved XWiki pages 
> >> > work
> >> > involving docdoesnotexist.vm, but I'm still not able to modify this 
> >> > behavior by
> >> > reading/taking into account values of request/responses exchanges 
> >> > between client and server.
> >> >
> >> > For instance: I would like to redirect a number of "short" URLs like 
> >> > this...
> >> >
> >> > http://www.idisantiago.es/BIS2013
> >> >
> >> > to a set of given XWiki pages. Currently I can, and I did, a redirection 
> >> > of all of them
> >> > to a single page by modifying Main.DocumentDoesNotExist this way...
> >> >
> >> > {{velocity}}
> >> > $response.sendRedirect($xwiki.getURL("BIS2013.Schedule"))
> >> > {{/velocity}}
> >> >
> >> > But I'm not able to find the way of using request's name and status in 
> >> > Velocity #if().
> >> > Please, see attached file. I found a number of what I consider related 
> >> > information dealing with
> >> > $response, $request, URL resolution, URL mappings and so on, so forth, 
> >> > but I 'm afraid this is
> >> > too much for me to digest!
> >>
> >> Sorry! I forgot that attachments are filtered out of the list! Here it is 
> >> the referenced image...
> >>
> >> http://www.idisantiago.es/bin/download/ICT/Request/BIS2013.302Response.png
> >>
> >> Thanks!
> >>
> >> > Please, could anybody point me in the right direction? Am I completely 
> >> > lost?
> >> >
> >> > Thanks for your help!!!
> >> >
> >> > Ricardo
> >> >
> >>
> >> --
> >> Ricardo Rodríguez
> >> Research Management and Promotion Technician
> >> Technical Secretariat
> >> Health Research Institute of Santiago de Compostela (IDIS)
> >> http://www.idisantiago.es
> >>
> >>
> >> Nota: A información contida nesta mensaxe e os seus posibles documentos 
> >> adxuntos é privada e confidencial e está dirixida únicamente ó seu 
> >> destinatario/a. Se vostede non é o/a destinatario/a orixinal desta 
> >> mensaxe, por favor elimínea. A distribución ou copia desta mensaxe non 
> >> está autorizada.
> >>
> >> Nota: La información contenida en este mensaje y sus posibles documentos 
> >> adjuntos es privada y confidencial y está dirigida únicamente a su 
> >> destinatario/a. Si usted no es el/la destinatario/a original de este 
> >> mensaje, por favor elimínelo. La distribución o copia de este mensaje no 
> >> está autorizada.
> >>
> >> See more languages: http://www.sergas.es/aviso_confidencialidad.htm
> >> ___
> >> users mailing list
> >> users@xwiki.org
> >> http://lists.xwiki.org/mailman/listinfo/users
> 
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
> 
> Nota: A información contida nesta mensaxe e os seus posibles documentos 
> adxuntos é privada e confidencial e está dirixida únicamente ó seu 
> destinatario/a. Se vostede non é o/a destinatario/a orixinal desta mensaxe, 
> por favor elimínea. A distribución ou copia desta mensaxe non está autorizada.
> 
> Nota: La información contenida en este mensaje y sus posibles documentos 
> adjuntos es privada y confidencial y está dirigida únicamente a su 
> destinatario/a. Si usted no es el/la destinatario/a original de este mensaje, 
> por favor elimínelo. La distribución o copia de este mensaje no está 
> autorizada.
> 
> See more languages: http://www.sergas.es/aviso_confidencialidad.htm


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


Re: [xwiki-users] java.lang.ClassCastException: com.xpn.xwiki.doc.XWikiAttachment cannot be cast to com.xpn.xwiki.api.Attachment

2013-04-29 Thread Valdis Vītoliņš
Thanks, Edo!
I got it working using following:
...
def sourceDoc = xwiki.getDocument(source.fullName);
def attachments = sourceDoc.getAttachmentList();
...

Valdis

> Hi Valdis
> 
> 
> Looks to me as if you try to give a List of XWikiAttachments to a
> method expecting Attachments. The class Attachment is the API class of
> XWikiAttachment. So if you call getAttachmentList() on an
> XWikiDocument it returns a List of XWikiAttachments, but calling the
> same method on a Document returns a List of Attachments.
> 
> 
> Long story short: I suppose calling getAttachmentList() on the source
> Document instead of the XWikiDocument should solve your problem.
> 
> 
> I hope this helps
> Edo
> 
> 
> 
> 
> On Thu, Apr 25, 2013 at 4:31 PM, Valdis Vītoliņš
>  wrote:
> I'm writing custom listener to send e-mail after document
> updates
> according to:
> 
> http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial 
> and: 
> http://xwiki.475771.n2.nabble.com/Send-an-email-in-an-event-listener-td7579175.html
> 
> Although adding attachment is working in Velocity as described
> in:
> http://extensions.xwiki.org/xwiki/bin/view/Extension/Mail
> +Sender+Plugin
> 
> Similar approach in Groovy raises exception:
> 
> java.lang.ClassCastException:
> com.xpn.xwiki.doc.XWikiAttachment cannot
> be cast to com.xpn.xwiki.api.Attachment
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.createMimeMultipart(MailSenderPlugin.java:391)
>  ~[xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.createMimeMessage(MailSenderPlugin.java:327)
>  ~[xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMails(MailSenderPlugin.java:726)
>  ~[xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMail(MailSenderPlugin.java:673)
>  ~[xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPlugin.sendMail(MailSenderPlugin.java:659)
>  ~[xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPluginApi.sendMail(MailSenderPluginApi.java:171)
>  [xwiki-platform-mailsender-4.5.jar:na]
> at
> 
> com.xpn.xwiki.plugin.mailsender.MailSenderPluginApi.sendTextMessage(MailSenderPluginApi.java:98)
>  [xwiki-platform-mailsender-4.5.jar:na]
> at com.xpn.xwiki.plugin.mailsender.MailSender
> $sendTextMessage.call(Unknown Source)
> [xwiki-platform-mailsender-4.5.jar:na]
> at EmailSenderListener.onEvent(Script22.groovy:34) [script:na]
> ...
> and line is: def attachments = source.getAttachmentList()
> 
> What should I do?
> 
> Thanks!
> Valdis
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users
> 
> 


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


[xwiki-users] Edit and save custom document from view action

2013-05-03 Thread Valdis Vītoliņš
I have customized document (i.e. attached object of the custom class to
document) and I'd like to change its status from the view mode.
I tried to modify ClassSheet for view mode with following HTML:






but got error:
Warning
This request contains an invalid authentication information.

Could anybody provide me some hints for me in the right direction?

Thanks!
Valdis

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


[xwiki-users] How to send all custom object content in e-mail

2013-05-11 Thread Valdis Vītoliņš
Is it way to get whole Custom object content to be send it in the mail?
I do it in Groovy as it is described in
http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial

I know it could be done by redoing the same formatting as in the class
sheet, but, as I need to notify about different objects, it is too
cumbersome and error prone.

I tried unsuccessfully:
1. xwiki.getURLContent("url","user","password") failed because user and
password seems not working,
2. doc.getRenderedContent() shows only doc.content part, ignoring custom
object properties.

Thanks!
Valdis



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


Re: [xwiki-users] How to send all custom object content in e-mail

2013-05-13 Thread Valdis Vītoliņš
Following to:
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/Authentication#HBasicAuthentication
I got it working using
xwiki.getURLContent(url+"?basicauth=1",user,password);

Valdis
> Is it way to get whole Custom object content to be send it in the mail?
> I do it in Groovy as it is described in
> http://platform.xwiki.org/xwiki/bin/view/DevGuide/GroovyNotificationTutorial
> 
> I know it could be done by redoing the same formatting as in the class
> sheet, but, as I need to notify about different objects, it is too
> cumbersome and error prone.
> 
> I tried unsuccessfully:
> 1. xwiki.getURLContent("url","user","password") failed because user and
> password seems not working,
> 2. doc.getRenderedContent() shows only doc.content part, ignoring custom
> object properties.
> 
> Thanks!
> Valdis
> 
> 
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] How to continue table in new row with content from referenced document

2013-05-22 Thread Valdis Vītoliņš
I'd like to continue table from main document with content from
referenced document, but can't get it right.

I have TableIncl document:
|cc|cc
|dd|dd

And then I use following:
|aa|aa
|bb|bb
 {{include reference="Test.TableIncl"/}}
I get table from TableIncl shown inside bb cell.
If I put empty line, then new table is started.

Any suggestions?
Valdis

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


Re: [xwiki-users] How to continue table in new row with content from referenced document

2013-05-22 Thread Valdis Vītoliņš
Thomas,
problem is that I don't want to put included content in a cell. Instead
I'd like to continue table in the new row. E.g. as following table:
|aa|aa
|bb|bb
|cc|cc
|dd|dd

with
|cc|cc
|dd|dd part included from the other document.

I tried also different groupings, e.g.:
(((|aa|aa
|bb|bb
{{include reference="Test.TableIncl"/}})))
what includes table in the cell,
or
(((|aa|aa
|bb|bb)))((({{include reference="Test.TableIncl"/}})))
which starts new table, etc.

It seems to me, including referenced document provides implicit grouping
~ like ((({{include reference="Test.TableIncl"/}})))

Valdis

> On Wed, May 22, 2013 at 3:43 PM, Valdis Vītoliņš  
> wrote:
> > I'd like to continue table from main document with content from
> > referenced document, but can't get it right.
> >
> > I have TableIncl document:
> > |cc|cc
> > |dd|dd
> >
> > And then I use following:
> > |aa|aa
> > |bb|bb
> >  {{include reference="Test.TableIncl"/}}
> > I get table from TableIncl shown inside bb cell.
> > If I put empty line, then new table is started.
> >
> > Any suggestions?
> > Valdis
> >
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> 
> You can use group syntax to put anything you want in a table cell
> (same for lists).
> 
> See http://www.xwiki.org/xwiki/bin/view/XWiki/XWikiSyntax#HGroups
> 
> --
> Thomas Mortagne


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


Re: [xwiki-users] How to continue table in new row with content from referenced document

2013-05-22 Thread Valdis Vītoliņš
> > Thomas,
> > problem is that I don't want to put included content in a cell. Instead
> > I'd like to continue table in the new row. E.g. as following table:
> > |aa|aa
> > |bb|bb
> > |cc|cc
> > |dd|dd
> >
> > with
> > |cc|cc
> > |dd|dd part included from the other document.
> >
> > I tried also different groupings, e.g.:
> > (((|aa|aa
> > |bb|bb
> > {{include reference="Test.TableIncl"/}})))
> > what includes table in the cell,
> > or
> > (((|aa|aa
> > |bb|bb)))((({{include reference="Test.TableIncl"/}})))
> > which starts new table, etc.
> >
> > It seems to me, including referenced document provides implicit grouping
> > ~ like ((({{include reference="Test.TableIncl"/}})))
> 
> Ok I did not understood your use case, you can't continue a table
> using include macro. The table is parsed before the include macro is
> executed and you get the include macro either in a cell or in a new
> standalone block.
> 
> In other word the table structure has to be complete before it's
> parsed. You will have to use scripting to do what you want but there
> is no way to do it with include macro.

So, this means that only way I can do it, is using macro in another page
and then invoke it from main page, e.g.

In TableIncl page:
{{velocity}}
#macro(remainingtable)
|cc|cc
|dd|dd
#end
{{/velocity}}

In Main page:
{{include reference="Test.TableIncl"/}}
{{velocity}}
|aa|aa
|bb|bb
#remainingtable()
{{/velocity}}

Valdis



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


Re: [xwiki-users] [myxwiki] new wiki request

2013-05-23 Thread Valdis Vītoliņš
Kévin,
you can probably include following velocity script in your pages.
#if($request.getRequestURL().substring(7,32)!
="www.familleassociative.fr")
## (please count characters yourself!)
$response.sendRedirect("http://www.familleassociative.fr/${request.getRequestURL().substring(32)}")
#end

And maybe even you can put this code in Xwiki settings:
../xwiki/bin/admin/XWiki/XWikiPreferences?editor=globaladmin§ion=Presentation
at the end of "HTTP Meta Information" field.

Valdis

> Thanks Vincent !
> 
> It works fine now : 
> http://www.familleassociative.fr/xwiki/bin/view/Main/WebHome
> 
> but all the content is also available at http://familleassociative.myxwiki.org
> 
> I learned that it was not a good thing to have two valid Url for a website.
> Is it possible to force with Url rewriting or other to lead to new domain 
> name ?
> 
> Thanks
> 
> Kévin
...

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


[xwiki-users] XWiki vs Xwiki or brandname vs forename

2013-05-29 Thread Valdis Vītoliņš
I'm just curious about brandname such as XWiki versus "generic" forename
such as Xwiki.

For example in languages I know (Latvian, English, Russian) any forename
(given name for person or dog, city or ship name, etc.) starts with
capital and then, if not all characters are capital, it follows with
small letters.

There are brandnames (mostly intentionally, to differ from "generic"
name) this rule is not followed: XWiki, iOS, PiTiVi, etc.

So, when I write about Xwiki:

1. I don't know it is spelled XWiki,
2. I'm too lazy to bother,
3. I intentionally spell it Xwiki, to not add disclaimer, that iOS or
XWiki or ... is a registered trademark (if is),
4. something else...

What do you think?
Valdis

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


Re: [xwiki-users] SSO/SAML/STS example provided on Github

2013-05-30 Thread Valdis Vītoliņš
Hello!
I have created another variant for XWiki authenticator, using SAML
Security Token Service (STS) authentication. It is pushed in Github fork
https://github.com/ValdisVitolins/sandbox/tree/master/authenticators/xwiki-authentication-sts
and I'd be happy if you will include it (doing some cleanup, if
necessary) in XWiki Sandbox repository.

Note, that although this module uses SAML as an high level standard,
actually it is quite different from
https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
because it uses quite old SAML 1.2 standard:
http://docs.oasis-open.org/wsfed/federation/v1.2/os/ws-federation-1.2-spec-os.html
and Authentication provider is implemented using Microsoft technologies.

Valdis


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


Re: [xwiki-users] SSO/SAML/STS example provided on Github

2013-05-31 Thread Valdis Vītoliņš
As XWiki sandbox is deprecated for new contributions, I moved this code
to another repository:
https://github.com/ValdisVitolins/munixwiki/tree/master/tools/xwiki-authentication-sts

Valdis
> Hello!
> I have created another variant for XWiki authenticator, using SAML
> Security Token Service (STS) authentication. It is pushed in Github fork
> https://github.com/ValdisVitolins/sandbox/tree/master/authenticators/xwiki-authentication-sts
> and I'd be happy if you will include it (doing some cleanup, if
> necessary) in XWiki Sandbox repository.
> 
> Note, that although this module uses SAML as an high level standard,
> actually it is quite different from
> https://github.com/xwiki-contrib/sandbox/tree/master/authenticators/xwiki-authentication-saml
> because it uses quite old SAML 1.2 standard:
> http://docs.oasis-open.org/wsfed/federation/v1.2/os/ws-federation-1.2-spec-os.html
> and Authentication provider is implemented using Microsoft technologies.
> 
> Valdis
> 
> 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] Is xwiki suitable as a blog now?

2013-08-19 Thread Valdis Vītoliņš
To handle pictures better, I use following macro:

#macro(picture $img, $width)
{image:$img|
width=$width}#end

Width parameter is optional, fixed width or percents can be used. And
user is able to click on picture to see bigger picture.

See http://platform.xwiki.org/xwiki/bin/view/DevGuide/WikiMacroTutorial
for more info about macros.

Valdis

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


[xwiki-users] Syntax 1.0 is not shown as syntax option

2013-08-20 Thread Valdis Vītoliņš
I've changed XWiki 5.1 configuration file .../xwiki/WEB-INF/xwiki.cfg
line to the:
...
xwiki.rendering.syntaxes = xwiki/1.0, xwiki/2.0, xwiki/2.1
...
but Document Syntax combo box still shows only 
XWiki 2.1
XWiki 2.0
as possible options.

Where could be the catch?
Valdis




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


[xwiki-users] Syntax and execution rules for parsed CSS and Javascript objects

2013-08-22 Thread Valdis Vītoliņš
I'm trying to move all velocity macro customizations from files to the
database according to
http://platform.xwiki.org/xwiki/bin/view/DevGuide/SkinExtensionsTutorial

Though I can't find out syntax and execution rules (e.g. order) for
parsed entries.

E.g. to implement different styles for anonymous and logged in users for
XWiki.StyleSheetExtension parsed code (how Velocity can decide which is
macro and whic is CSS id?):

#if($isGuest)
#xwikicontent {
  background-color: blue;
}
#else
#xwikicontent {
  background-color: red;
}
#end

Similarly, what should be right way to show alert for
XWiki.JavaScriptExtension parsed code:

alert($isGuest);

Thanks!
Valdis

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


Re: [xwiki-users] Syntax and execution rules for parsed CSS and Javascript objects

2013-08-22 Thread Valdis Vītoliņš
Thanks Clemens and Marius!
I updated
http://platform.xwiki.org/xwiki/bin/view/DevGuide/SkinExtensionsTutorial#HHowtouseVelocityinparsedcontent

with additional notes.

Valdis


> Hi Valdis,
> 
>  it seems in the StyleSheetExtensions / JavaScriptExtensions only the "basic" 
> variables are defined, like $doc, $request or $xcontext
> 
> The $isGuest is a "derived" variable; you can find the definition in 
> /templates/xwikivars.vm
> 
> I am not sure if there is a better way, but at least you can get the code 
> working by copy & paste the definition for the variables you need from the 
> xwikivars.vm to the corresponding objects
> 
> hope this helps,
> Clemens
> 
> > I'm trying to move all velocity macro customizations from files to the
> > database according to
> > http://platform.xwiki.org/xwiki/bin/view/DevGuide/SkinExtensionsTutorial
> > 
> > Though I can't find out syntax and execution rules (e.g. order) for
> > parsed entries.
> > 
> > E.g. to implement different styles for anonymous and logged in users for
> > XWiki.StyleSheetExtension parsed code (how Velocity can decide which is
> > macro and whic is CSS id?):
> > 
> > #if($isGuest)
> > #xwikicontent {
> >   background-color: blue;
> > }
> > #else
> > #xwikicontent {
> >   background-color: red;
> > }
> > #end
> > 
> > Similarly, what should be right way to show alert for
> > XWiki.JavaScriptExtension parsed code:
> > 
> > alert($isGuest);
> > 
> > Thanks!
> > Valdis
> > 
> > ___
> > users mailing list
> > users@xwiki.org
> > http://lists.xwiki.org/mailman/listinfo/users
> > 
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


Re: [xwiki-users] piwik anyone?

2013-08-23 Thread Valdis Vītoliņš
I use piwik and  I'm satisfied with it.
Reports can be seen at: http://odo.lv/piwik/

Valdis


> Hello XWiki users,
> 
> did anyone made experiments with Piwik?
> It seems to be an open-source (GPL unfortunately) analytics tool which would 
> compete well with Google Analytics.
> 
> thanks in advance.
> 
> Paul
> ___
> users mailing list
> users@xwiki.org
> http://lists.xwiki.org/mailman/listinfo/users


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


[xwiki-users] video tag again

2013-08-26 Thread Valdis Vītoliņš
I'm using  tag on old XWiki 2.7 with 1.0 syntax,
though I cannot to get it shown on XWiki 5.1 with 2.0/2.1 syntax.
Sergiu said in
http://lists.xwiki.org/pipermail/users/2011-July/020245.html
that {{html clean="false"}} should be used,
but it still filters  tag out...

Valdis


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


Re: [xwiki-users] video tag again

2013-08-26 Thread Valdis Vītoliņš
Thanks,
it works for me also, if I connect to the tomcat port directly.
It appears now this tag is filtered out by newer Apache proxy version
(hate these standards naciz)...

Valdis
> Hi,
> 
> On Aug 26, 2013, at 2:32 PM, Valdis Vītoliņš  wrote:
> 
> > I'm using  tag on old XWiki 2.7 with 1.0 syntax,
> > though I cannot to get it shown on XWiki 5.1 with 2.0/2.1 syntax.
> > Sergiu said in
> > http://lists.xwiki.org/pipermail/users/2011-July/020245.html
> > that {{html clean="false"}} should be used,
> > but it still filters  tag out…
> 
> It works as Sergiu said.
> 
> I've tested it here:
> http://playground.xwiki.org/xwiki/bin/view/Main/VMA
> 
> Content:
> {{html clean="false"}}
> 
> whatever
> 
> {{/html}}
> 
> HTML results (view source in your browser):
> 
>  
> whatever
> 
> 
> If it's not there it means your browser has removed it , not xwiki ;)
> 
> Thanks
> -Vincent
> 


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


Re: [xwiki-users] XWiki design and doubts

2013-08-26 Thread Valdis Vītoliņš
...
> The problem i have found is.
> 
> 1.- Project manager can create new spaces
http://platform.xwiki.org/xwiki/bin/view/AdminGuide/Access
+Rights#HPreventregularusersfromcreatingnewspaces

> 2.- I dont't know how to fix the initial space for Operators (they appear 
> in Main Space)

#if($xwiki.getUser().isUserInGroup("XWiki.DemoGroup"))
$response.sendRedirect($xwiki.getURL('Some.Document'))
#end


Valdis

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


  1   2   >