def pageProperty = { attrs ->
        if (!attrs.name) {
            throwTagError("Tag [pageProperty] is missing required attribute [name]")
        }        def propertyName = attrs.name
        def htmlPage = getPage()
        def propertyValue        if (htmlPage instanceof GSPSitemeshPage) {
            // check if there is an component content buffer
            propertyValue = htmlPage.getContentBuffer(propertyName)
        }        if (!propertyValue) {
            propertyValue = htmlPage.getProperty(propertyName)
        }        if (!propertyValue) {
            propertyValue = attrs.'default'
        }        if (propertyValue) {
            if (attrs.writeEntireProperty) {
                out << ' '
                out << propertyName.substring(propertyName.lastIndexOf('.') + 1)
                out << "=\""
                out << propertyValue
                out << "\""
            }
            else {
                out << propertyValue
            }
        }
    }