Don't know about you Christopher, but i still haven't got this working..
As a quick fix, you can just make an /app/views/layouts/application.rhtml
file in your extension, and add the extra stylesheet from there
Benny
Oh, duh! Sorry I overlooked this problem.
>
> You need to memoize the @stylesheets array. Change that method to look
> like this:
>
> def customize_admin_css
> @stylesheets ||=[]
> include_stylesheet 'radiant_custom'
> end
>
> Sean
>
> Christopher Zimmermann wrote:
> > Hi,
> > Im trying to include a custom CSS file for radiant. Previously, I just
> > replaced the main.css file in the radiant gem directory - but thats not
> > "sustainable".
> >
> > I tried following Sean's instructions below but have run into trouble.
> The
> > technique is to create an extension that runs a before filter that
> calls:
> > include_stylesheet 'my_stylesheet'
> >
> > But it looks like the include_stylesheet is crashing because the
> @stylesheet
> > array is empty.
> >
> > The line it is failing on is:
> > controllers/application.rb line 22
> > "@stylesheets << sheet"
> >
> > My extension looks like this:
> >
> > def activate
> > require_dependency 'application'
> > SiteController.class_eval do
> >
> > prepend_before_filter :customize_admin_css
> >
> > def customize_admin_css
> > include_stylesheet ('radiant_custom')
> > end
> > end
> > end
> >
> > Any ideas anyone - could be something silly as I am still a rubynuby.
> >
> > Thanks!
> > Topher
> >
_______________________________________________
Radiant mailing list
Post: [email protected]
Search: http://radiantcms.org/mailing-list/search/
Site: http://lists.radiantcms.org/mailman/listinfo/radiant