json - Get template rendered from controller without render yet -


i want return response json ajax containing more atributtes instead template:

default:

render(template:"/templates/question",model:[question: question]) 

..and want like:

def template = *get*(template:"/templates/question",model:[question: question])     render [template:template, istemplate: true] json 

is possible? thanks

then solution is:

class mycontroller {    def test = {         // stored string ...          def x = g.render(template:"/basecontroller/test",model:[name:"wysmedia.com"]);          render(x); // display template instead render    } } 

Comments

Popular posts from this blog

apache - Add omitted ? to URLs -

redirect - bbPress Forum - rewrite to wwww.mysite prohibits login -

php - How can I stop spam on my custom forum/blog? -