web stats
Removing 1 bound namespace from XML - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 02-05-2016, 06:54 AM
craig.burdulis craig.burdulis is offline
Mirth Newb
 
Join Date: Jan 2016
Posts: 7
craig.burdulis is on a distinguished road
Default Removing 1 bound namespace from XML

I'm trying to remove the xmlns:cda namespace from the line below:
Code:
<ClinicalDocument xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:hl7-org:v3" xmlns:cda="urn:hl7-org:v3" xmlns:sdtc="urn:hl7-org:sdtc">
I have tried a myriad of ways, both on the source and destination ends of the channel, with no luck. I do not want to strip namespaces since only the xmlns:cda namespace is causing issues with the channel processing.

I've tried (separately):
Code:
msg.removeNamespace('@xmlns:cda');
msg.replace('xmlns:cda="urn:hl7-org:v3"', '')
delete tmp['@xmlns:cda']
to no avail. Any ideas? I feel like I am not referencing the namespace correctly.
Reply With Quote
  #2  
Old 02-12-2016, 08:43 AM
jackwhaines jackwhaines is offline
 
Join Date: May 2011
Location: Kansas City, Missouri
Posts: 168
jackwhaines is on a distinguished road
Send a message via Skype™ to jackwhaines
Default

So close! Try this:

Code:
msg = msg.replace('xmlns:cda="urn:hl7-org:v3"', '')
__________________

-= Jack Haines : Healthcare Integrations, LLC
-= jack.haines@HealthcareIntegrations.com
-= Mirth Connect (Advanced)-certified
-= Gold member of HL7.org
-= Available for Mirth Connect channel development and consultation! Schedule a call with me at https://integrations.as.me
Reply With Quote
Reply

Tags
cda, delete, namespace, remove, xml

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 12:11 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2019, vBulletin Solutions, Inc.
Mirth Corporation