Hi Ken, On Thu, Nov 5, 2009 at 12:56 AM, Ken Burcham <[email protected]> wrote: > I just noticed my question is pretty much the same as this one: > > http://markmail.org/message/htl6r3uctuzb6l5q
You're right :) > On Nov 4, 2009, at 3:39 PM, Ken Burcham wrote: > >> Ok, so I'm enjoying sling a lot. I'm stuck on something tho: >> >> Here's my content repository >> [...] >> I have my application nodes as: sling:resourceType = gradapp/application >> and the tabs as: sling:resourceType=gradapp/tab >> >> >> So my problem is that >> >> http://localhost:8888/gradapp/application/app1.edit.html >> >> works fine in giving me the edit page for app1 application, using the >> script from the apps/gradapp/application/edit.esp >> >> but >> >> http://localhost:8888/gradapp/application/*.edit.html >> >> does not work, just gives me the resource dumped: >> >> Resource dumped by HtmlRendererServlet >> Resource path: /gradapp/application/* >> Resource metadata: {sling.resolutionPath=/gradapp/application/*, >> sling.resolutionPathInfo=.edit.html} >> Resource type: sling:syntheticStarResource >> Resource super type: - >> Resource Value: >> >> as though it isn't mapping to the /apps/gradapp/application/edit.esp as I >> would expect. >> >> I'm sure i'm just not thinking of it right, but i'm not sure what i'm >> doing wrong. :) thanks! Or how do I tell it that the new node will have >> resourceType gradapp/application? As you've read on the thread you linked to, /gradapp/application/*.edit.html does not invoke your script, because your script is registered on a resource type (gradapp/application), and the "*" does not have that resource type (as it is not created yet). One suggestion is to register a generic node creation form script, e.g. at /apps/sling/servlet/default/create.esp. You should be able to invoke that script by browsing to /gradapp/application/*.create. If you want the create.esp script to be able to render different forms (e.g. one for applications, one for tabs) you could do so by checking on a query parameter. So requesting /gradapp/application/*.create?typeToCreate=application could give a form for creating application nodes, while /gradapp/application/*.create?typeToCreate=tab could give the tab form. Hope this gives you some ideas. -- Vidar S. Ramdal <[email protected]> - http://www.idium.no Sommerrogata 13-15, N-0255 Oslo, Norway + 47 22 00 84 00 / +47 21 531941, ext 2070
