On 09/16/2010 10:24 PM, volker wrote: > Hello Fabio& friends, > > i tried to use curl and the RESTful API to > > 1) create a page: ok > 2) upload a file/image: ok > 3) create some TAGS to the page: ???? > > 1) and 2) is working, but 3 is not working. What is wrong in 3)? > > What about unicode/Umlaut in page-name, tag-name and > upload-filename. I have some problems with öäü-German and > øæå-Norwegian. > Hi Volker,
3) doesn't work because the .../tags resource doesn't support PUT. At the beginning this resource was just meant to be a shortcut to list tags, not to modify them. But indeed it would be nice to allow the user to modify tags through this resource. You can open an improvement request on the JIRA for that. As a workaround you can manipulate the TagClass object to modify tags: curl -u "Admin:admin" -X PUT -H "Content-type: text/plain" --data-ascii "foo,bar" http://localhost:8080/xwiki/rest/wikis/xwiki/spaces/Main/pages/WebHome/objects/TagClass/0/properties/tags If the reply is a 404, this means that the TagClass object doesn't exist on the page. In this case you need to send an additional request to create the object: curl -u "Admin:admin" -X POST -H "Content-type: application/x-www-form-urlencoded" --data-ascii "className=TagClass&property#tags=foo,bar" http://localhost:8080/xwiki/rest/wikis/xwiki/spaces/Main/pages/WebHome/objects Concerning the unicode/Umlaut problem what's exactly the issue? Hope this helps, Fabio _______________________________________________ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users