472,338 Members | 1,781 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,338 software developers and data experts.

XML to XSL

Hey, I have a slightly different XML file type then I'm used to and my
XSL will not parse the data in at all. Could someone look at it for me
and see if I'm just an idiot?

XSL:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:template match="/">

<html>
<body>
<h2>Summary Report</h2>
<table border="1">
<tr bgcolor="#9acd32">
<th align="left">Tracking ID</th>
<th align="left">Condition Indicator</th>
</tr>
<tr>
<td>
<xsl:value-of
select="CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420100_2000C_TRN_ProviderTracking/CMS27420100_2000C_TRN02_ReferenceIdentification"/>
</td>
<td>
<xsl:value-of
select="CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420300_2100CA/CMS27421400_2100CA_CRC_EFIProcessingStatusAddition al/CMS27421400_2100CA_CRC03_ConditionIndicator"/>
</td>
</tr>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
Excerpt of sample code:
<CMS274>
<CMS27410200_BHT_BeginningOfHierarchicalTransactio n
CMS27410200_BHT02_TransactionSetPurposeCode="11"
CMS27410200_BHT06_TransactionTypeCode="RK"/>
<CMS274_HealthCareProviderInformationProviderSiteG roup>
<CMS27420100_2000A>
<CMS27420300_2100AA_NM1_SubmitterName
CMS27420300_2100AA_NM109_SubmitterIdentifier="9999 99"/>
</CMS27420100_2000A>
<CMS27420100_2000C>
<CMS27420100_2000C_TRN_ProviderTracking

CMS27420100_2000C_TRN02_ReferenceIdentification="0 6132006999999"/>
<CMS27420300_2100CA>
<CMS27420300_2100CA_NM1_ProviderName
CMS27420300_2100CA_NM102_EntityTypeQualifier="1"

CMS27420300_2100CA_NM103_ProviderLastOrOrganizatio nName="Johnson"
CMS27420300_2100CA_NM104_ProviderFirstName="Tom"
CMS27420300_2100CA_NM106_ProviderNamePrefix="Mr."/>
<CMS27420500_2100CA_PER_ProviderCommunicationsCont act

CMS27420500_2100CA_PER03_CommunicationNumberQualif ier="TE"

CMS27420500_2100CA_PER04_CommunicationNumber="6106 641194"/>
<CMS27420600_2100CA_DMG_ProviderSDemographicInform ation

CMS27420600_2100CA_DMG02_ProviderBirthDate="03/13/1952"
CMS27420600_2100CA_DMG03_ProviderGenderCode="M"/>
<CMS27420700_2100CA_API_RequestStatus
CMS27420700_2100CA_API02_ActionCode="A4"/>
<CMS27421400_2100CA_CRC_EFIProcessingStatusAdditio nal
CMS27421400_2100CA_CRC03_ConditionIndicator="12"
CMS27421400_2100CA_CRC05_ConditionDetail="Gate
Keeper routines have flagged the record for Enumerator review"/>
....

My program Oxygen tries to relate the path to the lowest element, but
not the attribute. I normally have the data between
<person>Myname</person> style tags, I do not know how to pull the data
in this form. I have tried parsing in IE6 and Oxygen7Any ideas?

Jun 26 '06 #1
2 1006
re*****@gmail.com wrote:
<xsl:value-of
select="CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420100_2000C_TRN_ProviderTracking/CMS27420100_2000C_TRN02_ReferenceIdentification"/>
</td>
<td>
<xsl:value-of
select="CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420300_2100CA/CMS27421400_2100CA_CRC_EFIProcessingStatusAddition al/CMS27421400_2100CA_CRC03_ConditionIndicator"/>
</td>
</tr>
</table>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
Excerpt of sample code:
<CMS274>
<CMS27410200_BHT_BeginningOfHierarchicalTransactio n
CMS27410200_BHT02_TransactionSetPurposeCode="11"
CMS27410200_BHT06_TransactionTypeCode="RK"/>
<CMS274_HealthCareProviderInformationProviderSiteG roup>
<CMS27420100_2000A>
<CMS27420300_2100AA_NM1_SubmitterName
CMS27420300_2100AA_NM109_SubmitterIdentifier="9999 99"/>
</CMS27420100_2000A>
<CMS27420100_2000C>
<CMS27420100_2000C_TRN_ProviderTracking

CMS27420100_2000C_TRN02_ReferenceIdentification="0 6132006999999"/>
<CMS27420300_2100CA>
<CMS27420300_2100CA_NM1_ProviderName
CMS27420300_2100CA_NM102_EntityTypeQualifier="1"

CMS27420300_2100CA_NM103_ProviderLastOrOrganizatio nName="Johnson"
CMS27420300_2100CA_NM104_ProviderFirstName="Tom"
CMS27420300_2100CA_NM106_ProviderNamePrefix="Mr."/>
<CMS27420500_2100CA_PER_ProviderCommunicationsCont act

CMS27420500_2100CA_PER03_CommunicationNumberQualif ier="TE"

CMS27420500_2100CA_PER04_CommunicationNumber="6106 641194"/>
<CMS27420600_2100CA_DMG_ProviderSDemographicInform ation

CMS27420600_2100CA_DMG02_ProviderBirthDate="03/13/1952"
CMS27420600_2100CA_DMG03_ProviderGenderCode="M"/>
<CMS27420700_2100CA_API_RequestStatus
CMS27420700_2100CA_API02_ActionCode="A4"/>
<CMS27421400_2100CA_CRC_EFIProcessingStatusAdditio nal
CMS27421400_2100CA_CRC03_ConditionIndicator="12"
CMS27421400_2100CA_CRC05_ConditionDetail="Gate
Keeper routines have flagged the record for Enumerator review"/>
...

My program Oxygen tries to relate the path to the lowest element, but
not the attribute. I normally have the data between
<person>Myname</person> style tags, I do not know how to pull the data
in this form. I have tried parsing in IE6 and Oxygen7Any ideas?

Jun 26 '06 #2
re*****@gmail.com wrote:
<xsl:value-of
select="CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420300_2100CA/CMS27421400_2100CA_CRC_EFIProcessingStatusAddition al/CMS27421400_2100CA_CRC03_ConditionIndicator"/> .... <CMS27421400_2100CA_CRC_EFIProcessingStatusAdditio nal
CMS27421400_2100CA_CRC03_ConditionIndicator="12"
CMS27421400_2100CA_CRC05_ConditionDetail="Gate
Keeper routines have flagged the record for Enumerator review"/>


You need to use @ (or attribute::) to refer to an attribute. Change the
path to:

"CMS274/CMS274_HealthCareProviderInformationProviderSiteGr oup/CMS27420100_2000C/CMS27420300_2100CA/CMS27421400_2100CA_CRC_EFIProcessingStatusAddition al/@CMS27421400_2100CA_CRC03_ConditionIndicator"

(Since this is basic XPath usage, it suggests that you might want to
review a good XPath tutorial.)
Jun 26 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: William C. White | last post by:
Does anyone know of a way to use PHP /w Authorize.net AIM without using cURL? Our website is hosted on a shared drive and the webhost company...
2
by: Albert Ahtenberg | last post by:
Hello, I don't know if it is only me but I was sure that header("Location:url") redirects the browser instantly to URL, or at least stops the...
3
by: James | last post by:
Hi, I have a form with 2 fields. 'A' 'B' The user completes one of the fields and the form is submitted. On the results page I want to run a...
0
by: Ollivier Robert | last post by:
Hello, I'm trying to link PHP with Oracle 9.2.0/OCI8 with gcc 3.2.3 on a Solaris9 system. The link succeeds but everytime I try to run php, I get...
1
by: Richard Galli | last post by:
I want viewers to compare state laws on a single subject. Imagine a three-column table with a drop-down box on the top. A viewer selects a state...
4
by: Albert Ahtenberg | last post by:
Hello, I have two questions. 1. When the user presses the back button and returns to a form he filled the form is reseted. How do I leave...
1
by: inderjit S Gabrie | last post by:
Hi all Here is the scenerio ...is it possibly to do this... i am getting valid course dates output on to a web which i have designed ....all...
2
by: Jack | last post by:
Hi All, What is the PHP equivilent of Oracle bind variables in a SQL statement, e.g. select x from y where z=:parameter Which in asp/jsp...
3
by: Sandwick | last post by:
I am trying to change the size of a drawing so they are all 3x3. the script below is what i was trying to use to cut it in half ... I get errors....
0
by: concettolabs | last post by:
In today's business world, businesses are increasingly turning to PowerApps to develop custom business applications. PowerApps is a powerful tool...
0
better678
by: better678 | last post by:
Question: Discuss your understanding of the Java platform. Is the statement "Java is interpreted" correct? Answer: Java is an object-oriented...
0
by: Kemmylinns12 | last post by:
Blockchain technology has emerged as a transformative force in the business world, offering unprecedented opportunities for innovation and...
0
jalbright99669
by: jalbright99669 | last post by:
Am having a bit of a time with URL Rewrite. I need to incorporate http to https redirect with a reverse proxy. I have the URL Rewrite rules made...
0
by: Matthew3360 | last post by:
Hi there. I have been struggling to find out how to use a variable as my location in my header redirect function. Here is my code. ...
2
by: Matthew3360 | last post by:
Hi, I have a python app that i want to be able to get variables from a php page on my webserver. My python app is on my computer. How would I make it...
0
by: AndyPSV | last post by:
HOW CAN I CREATE AN AI with an .executable file that would suck all files in the folder and on my computerHOW CAN I CREATE AN AI with an .executable...
0
by: Arjunsri | last post by:
I have a Redshift database that I need to use as an import data source. I have configured the DSN connection using the server, port, database, and...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.