mirror of
https://github.com/php/php-src.git
synced 2025-08-18 23:18:56 +02:00
Fixed bug #34788 (SOAP Client not applying correct namespace to generated values)
This commit is contained in:
parent
3ea64d3377
commit
c8f43c67d0
1 changed files with 7 additions and 1 deletions
|
@ -1381,7 +1381,7 @@ static int model_to_xml_object(xmlNodePtr node, sdlContentModelPtr model, zval *
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return 1;
|
return 1;
|
||||||
} else if (strict && model->u.element->nillable) {
|
} else if (strict && model->u.element->nillable && model->min_occurs > 0) {
|
||||||
property = xmlNewNode(NULL,model->u.element->name);
|
property = xmlNewNode(NULL,model->u.element->name);
|
||||||
xmlAddChild(node, property);
|
xmlAddChild(node, property);
|
||||||
if (style == SOAP_ENCODED) {
|
if (style == SOAP_ENCODED) {
|
||||||
|
@ -1390,6 +1390,12 @@ static int model_to_xml_object(xmlNodePtr node, sdlContentModelPtr model, zval *
|
||||||
xmlNsPtr xsi = encode_add_ns(property,XSI_NAMESPACE);
|
xmlNsPtr xsi = encode_add_ns(property,XSI_NAMESPACE);
|
||||||
xmlSetNsProp(property, xsi, "nil", "true");
|
xmlSetNsProp(property, xsi, "nil", "true");
|
||||||
}
|
}
|
||||||
|
if (style == SOAP_LITERAL &&
|
||||||
|
model->u.element->namens &&
|
||||||
|
model->u.element->form == XSD_FORM_QUALIFIED) {
|
||||||
|
xmlNsPtr nsp = encode_add_ns(property, model->u.element->namens);
|
||||||
|
xmlSetNs(property, nsp);
|
||||||
|
}
|
||||||
return 1;
|
return 1;
|
||||||
} else if (model->min_occurs == 0) {
|
} else if (model->min_occurs == 0) {
|
||||||
return 2;
|
return 2;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue