Resolve resource name and return corresponding XML or XHTML response