Has anyone got map.resources to work within Radiant admin/extensions. The problem I have is that if I: map.resources :testimonials ...everything works fine but everything operates out of /testimonials not /admin/testimonials which means that when I create a page with a slug of 'testimonials' it all fails horribly when I try to visit that page (because it is calling the resourced controller not the radiant page). I could go back to Rails's :controller/:action's but thought I'd give this a go (and my present app does use it to an elegant end). Any one with any experience of this? Kind regards, -Karl
on 2007-04-04 00:40
on 2007-04-04 01:21
map.resources :testimonials, :path_prefix => "/admin" Try that. ;) Sean
on 2007-04-04 08:29
Ooh, nifty! Thanks.
on 2007-04-04 17:25
I've added this to the wiki http://dev.radiantcms.org/radiant/wiki/ HowToWriteAnExtension I find extensions a bit confusing, so I decided to start documenting and hope that others will pitch in.
on 2007-04-26 23:29
Hi Karl, Did this work out for you in the end? I've managed to get map.resources working fine in my Radiant extensions except for posting to the edit/update functions, whenever I try that I get the standard Radiant 404 Page Not Found page come up. Anyone have some ideas on this one? I'm stumped. Cheers, Kevin Ansfield
on 2007-04-26 23:39
Are your controllers inheriting from Admin::AbstractModelController? Sean
on 2007-04-26 23:45
Hi Sean, No, they are inheriting from ApplicationController Thanks, Keivn On 4/26/07, Sean Cribbs <firstname.lastname@example.org> wrote: > > > > > Post: Radiant@lists.radiantcms.org > > > > _______________________________________________ > Radiant mailing list > Post: Radiant@lists.radiantcms.org > Search: http://radiantcms.org/mailing-list/search/ > Site: http://lists.radiantcms.org/mailman/listinfo/radiant > -- BN23 Search Limited is Registered in England Company Number: 5323555 VAT registration Number: 896 69 0062 BN23 Search Limited Temple Grove Compton Place Road Eastbourne East Sussex BN20 8AD