[Ocaml-pxp-users] Forcing xmlns declarations to be written out

Richard Jones rich at annexia.org
Mon May 23 09:42:33 PDT 2005


Is there a way to force PXP to write xmlns declarations, even ones
which are "apparently" useless?

I have the following SOAP document:

	<?xml version="1.0" encoding="UTF-8"?>
	<soap:Envelope
	xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
	><soap:Body
	><fn:echo_bool
	xmlns:fn="http://localhost:50881"
	><fn:c-gensym1
	xsi:type="xsd:boolean"
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	>true</fn:c-gensym1
	></fn:echo_bool
	></soap:Body
	></soap:Envelope
	>

The problem is the attribute xsi:type="xsd:boolean".  In SOAP the xsd:
prefix in the attribute's _value_ is supposed to refer to a namespace,
and that's supposed to have been declared earlier, ie. something like
<soap:Envelope ... xmlns:xsd="...">

However since the xsd: prefix isn't declared, the SOAP server can't
parse the above request, complaining that:

	Application failed during request deserialization: Unresolved
	prefix 'xsd' for attribute value 'xsd:boolean'

Also for aesthetic reasons I'd like my xsi and xsd namespaces to be
declared as attributes in the Envelope.

Any tips on how to do this?

Rich.

-- 
Richard Jones, CTO Merjis Ltd.
Merjis - web marketing and technology - http://merjis.com
Team Notepad - intranets and extranets for business - http://team-notepad.com



More information about the Ocaml-pxp-users mailing list