foo is not a valid mode
mode attribute of a
content element must be either "xml", "escaped", or "base64".
Use one of the acceptable values, or take out the attribute (it defaults to "xml").
Like all attributes in XML, this attribute value is case sensitive.
Not clear? Disagree?
You might be able to find help in one of these fine resources.