You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Pete Robbins (JIRA)" <tu...@ws.apache.org> on 2007/08/21 21:41:30 UTC

[jira] Resolved: (TUSCANY-1566) Element coming out in the wrong namespace

     [ https://issues.apache.org/jira/browse/TUSCANY-1566?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Pete Robbins resolved TUSCANY-1566.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: Cpp-Next

Fixed in HEAD and the branch.

> Element coming out in the wrong namespace
> -----------------------------------------
>
>                 Key: TUSCANY-1566
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-1566
>             Project: Tuscany
>          Issue Type: Bug
>          Components: C++ SDO
>    Affects Versions: Cpp-Next
>         Environment: WinXP
>            Reporter: Matthew Peters
>             Fix For: Cpp-Next
>
>         Attachments: Atom1.0.xsd
>
>
> We have a schema file that defines an atom feed. It specified elementFormDefault="qualified" so that lower level elements should be in the target namespace. I will attach the schema as a separate file. With a very simple php test case as follows:
> $xmldas = SDO_DAS_XML::create('Atom1.0.xsd');
> $document = $xmldas->createDocument('http://www.w3.org/2005/Atom','entry');
> $entry = $document->getRootDataObject();
> $author = $entry->createDataObject('author');
> $author->name[] = "Caroline Maynard";
> print $xmldas->saveString($document,2);
> we get
> <?xml version="1.0" encoding="UTF-8"?>
> <tns:entry xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.w3.org/2005/Atom">
>   <tns:author>
>     <name>Caroline Maynard</name>
>   </tns:author>
> </tns:entry>
> whereas we should see the <name> element in the tns namespace.
> I have checked this with XERCES: the xml that we are generating will not validate, whereas if I alter it to have <name> in the tns namespace it will. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org