Any help would be so greatly appreciated.
Here are the two problems.
1. From a previous post, I use a CDATA with a "translate" statement to output formatted text. It works well in another segment of the style sheet. However, it does not work in the snippit below. The CDATA text is not fomatted
when viewed with the browser.
2. The data cells do not hold the same "width" from row to row. ie, the <Type> column is wider in the second record, than in the first.
Any ideas why the CDATA won't respond to the style sheet snippit? I think it might have to do with the for-each statement, but I don't know...the CDATA will not respond to the translate statement.
Please please help..
Thanks.
~LCarroll
xml follows:
---------------------------------------------------------------------------
<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="ccr_20060420.xsl"?>
<ContinuityOfCareRecord
xmlns:xsi="
xsi:schemaLocation="urn:astm-org:CCR CCR_20051109.xsd"
xmlns="urn:astm-org:CCR">
<Body>
<MedicalNotes>
<MedicalNote>
<Component>
<Type><Text>Subjective:</Text></Type>
<Content><Text><![CDATA[[RX ] LASIX [40 MG] <00039-0060>
[RX ] LANOXIN [.125 MG] <00247-0510>
[PT ED] test
[ALERT] 05/28/2008 [Check for lab results]
[RECALL] 06/24/2008 [99213]
[CPT] 99213 - EP Level 3
]]></Text></Content>
</Component>
</MedicalNote>
<MedicalNote>
<Component>
<Type><Text>Plan:</Text></Type>
<Content><Text><![CDATA[[RX ] LASIX [40 MG] <00039-0060>
[RX ] test test test test test
[ALERT] 05/28/2008 [Check for lab results]
[RECALL] 06/24/2008 [99213]
[CPT] 99213 - EP Level 3
]]></Text></Content>
</Component>
</MedicalNote>
</MedicalNotes>
</Body>
</ContinuityOfCareRecord>
-------------------------------------------------------------------------------
Here is the snippit from the style sheet:
-------------------------------------------------------------------------------
<xsl:if test="a:ContinuityOfCareRecord/a:Body/a:MedicalNotes/a:MedicalNote[a:Component/a:Content/a:Text!='']">
<tr id="mednotesrow">
<td>
<span class="header">Medical Notes</span>
<br/>
<table id="mednotes" class="list" width="100%">
<tbody>
<tr>
<th>Type</th>
<th>Date</th>
<th>Component</th>
<th>Source</th>
</tr>
<xsl:for-each select="a:ContinuityOfCareRecord/a:Body/a:MedicalNotes/a:MedicalNote[a:Component/a:Content/a:Text!='']">
<tr>
<td width="10%">
<xsl:value-of select="a:Type/a:Text"/>
</td>
<td width="25%">
<table class="internal">
<tbody>
<xsl:call-template name="dateTime">
<xsl:with-param name="dt" select="a

ateTime"/>
<xsl:with-param name="fmt">MMM dd, yyyy ':' hh:mm aa zzz</xsl:with-param>
</xsl:call-template>
</tbody>
</table>
</td>
<td>
<table class="internal" width="100%">
<tbody>
<xsl:for-each select="a:Component">
<tr>
<td width="6%">
<xsl:value-of select="a:Type/a:Text"/>
</td>
<td width="44%">
<xsl:value-of select="translate(a:Content/a:Text,' ',' ')"/>
</td>
</tr>
</xsl:for-each>
</tbody>
</table>
</td>
<td width="15%">
<a>
<xsl:attribute name="href">#
<xsl:value-of select="a:Source/a:Actor/a:ActorID"/></xsl:attribute>
<xsl:call-template name="actorName">
<xsl:with-param name="objID" select="a:Source/a:Actor/a:ActorID"/>
</xsl:call-template>
</a>
</td>
</tr>
</xsl:for-each>
</tbody>
</table>
</td>
</tr>
</xsl:if>
---------------------------------------------------------------------------------------------------------
end of style sheet segment.