Problems with Discover Sling in 15 minutes

心已入冬 提交于 2019-12-13 09:14:59

问题


I have problems with creating a content node with cURL. I execute the following command:

curl -u admin:admin -F"sling:resourceType=foo/bar" -F"title=some title" http://localhost:8080/content/mynode

But I can't see http://localhost:8080/content/mynode.html as there is showed the following problem:

Resource dumped by HtmlRendererServlet

Resource path: /content/mynode
Resource metadata: {sling.resolutionPathInfo=.html, sling.resolutionPath=/content/mynode}
Resource type: foo/bar
Resource super type: -

Resource properties

title: some title
sling:resourceType: foo/bar
jcr:createdBy: admin
jcr:created: 

http://localhost:8080/content/mynode.json has following content:

{"title":"some title","sling:resourceType":"foo/bar","jcr:createdBy":"admin","jcr:created":"Thu Jul 04 2013 21:24:36 GMT+0300","jcr:primaryType":"sling:Folder"}

回答1:


The html output that you get is correct, it's the default Sling HTML rendering.

You probably haven't executed the "Render your content using server-side javascript (ESP)" steps at http://sling.apache.org/documentation/getting-started/discover-sling-in-15-minutes.html which will setup a custom HTML rendering that's more useful.



来源:https://stackoverflow.com/questions/17476554/problems-with-discover-sling-in-15-minutes

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!