web stats
Mirth Community - View Single Post - Removing 1 bound namespace from XML
View Single Post
  #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