9.1.6.6 Using GSP to Customize Rendering - Reference Documentation
Authors: Graeme Rocher, Peter Ledbrook, Marc Palmer, Jeff Brown, Luke Daley, Burt Beckwith, Lari Hotari
Version: 3.0.12
9.1.6.6 Using GSP to Customize Rendering
You can also customize rendering on a per action basis using Groovy Server Pages (GSP). For example given theshow
action mentioned previously:def show(Book book) { respond book }
show.xml.gsp
file to customize the rendering of the XML:<%@page contentType="application/xml"%> <book id="${book.id}" title="${book.title}"/>