MCPcopy Create free account
hub / github.com/crewjam/saml / wrapXHTML

Function wrapXHTML

xhtml_forms_test.go:70–73  ·  view source on GitHub ↗

wrapXHTML puts fragment, a form made by one of the PostWithNonce methods, in a page the way samlsp.Middleware does.

(fragment []byte)

Source from the content-addressed store, hash-verified

68// wrapXHTML puts fragment, a form made by one of the PostWithNonce methods,
69// in a page the way samlsp.Middleware does.
70func wrapXHTML(fragment []byte) []byte {
71 return []byte(`<!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml"><head><title>Continue</title></head><body>` +
72 string(fragment) + `</body></html>`)
73}
74
75// awkward values check that whatever the templates interpolate is escaped
76// in a way that stays well-formed XML.

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected