Views from other source

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Views from other source

Stephan.Schmidt
Hello,

is it possible to load views not from the file system (or WAR) but on  
the fly from a different source (database, xml database?)
We have been thinking about Grails as a SnipSnap frontend and need to  
load views from wiki pages.

thanks
bye
-stephan


Reply | Threaded
Open this post in threaded view
|

Re: Views from other source

graemer
Not without some tweaking, I guess there are 2 ways you could do it.. you could

a) change the "org.codehaus.groovy.grails.web.servlet.view.GrailsViewResolver"
implementation configured in the SpringConfig

or

b) Add new methods to
"org.codehaus.groovy.grails.web.pages.GroovyPagesTemplateEngine" to
create templates from another source and then use it directly from a
controller action to render the view

Cheers
Graeme



On 4/19/06, Stephan J. Schmidt <[hidden email]> wrote:

> Hello,
>
> is it possible to load views not from the file system (or WAR) but on
> the fly from a different source (database, xml database?)
> We have been thinking about Grails as a SnipSnap frontend and need to
> load views from wiki pages.
>
> thanks
> bye
> -stephan
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Views from other source

Stephan.Schmidt
Ok, thanks, I'll try the first way :-)

bye
-stephan

> Not without some tweaking, I guess there are 2 ways you could do  
> it.. you could
>
> a) change the  
> "org.codehaus.groovy.grails.web.servlet.view.GrailsViewResolver"
> implementation configured in the SpringConfig
>
> or
>
> b) Add new methods to
> "org.codehaus.groovy.grails.web.pages.GroovyPagesTemplateEngine" to
> create templates from another source and then use it directly from a
> controller action to render the view
>
> Cheers
> Graeme
>
>
>
> On 4/19/06, Stephan J. Schmidt <[hidden email]> wrote:
>> Hello,
>>
>> is it possible to load views not from the file system (or WAR) but on
>> the fly from a different source (database, xml database?)
>> We have been thinking about Grails as a SnipSnap frontend and need to
>> load views from wiki pages.
>>
>> thanks
>> bye
>> -stephan
>>
>>
>>