3

I am importing XML into Adobe InDesign. Using the following XSLT I am trying to massage the XML to create the desired data flow.

My XSLT is working almost perfectly thanks to help here on StackOverflow. I have just a couple of persistent problems that I can't seem to overcome. I've tried dozens of options but I'm still stumped.

The XML has four basic levels <Root><Story<CL>+<BK>+...</BK></CL></Story><Root>

The CL and the BK nodes have multiple elements.

I am trying to get two elements that appear under the CL node to appear on the same line in the XSLT result, but have not been able to get it to work no matter what I try.

Here is the full XSLT, remember the only thing I'm trying to do is to get the elements <CityDescription> and <Population> to appear on the same line in the output:

<?xml version="1.0" encoding="UTF-8"?>
 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
      <xsl:output omit-xml-declaration="yes" indent="no" />
 <xsl:strip-space elements="*"/>

 <xsl:output method="XML"/>
 <xsl:template match="/">

 <Root>
 <Story><xsl:apply-templates select="Root/Story/CL"/></Story>
 </Root>
 </xsl:template>
 <xsl:template match="CityDescription"><CityDescription><xsl:value-of select="."/></CityDescription><xsl:text>  </xsl:text></xsl:template><xsl:template match="CL/Population"><Population><xsl:value-of select="."/></Population></xsl:template>

 <xsl:template match="BankName | Address1 | Hours | Established | RoutingNbr | CO/CityOfficePhone | CO/CityOfficeAddress2 "><xsl:element name="{name()}"><xsl:value-of select="."/></xsl:element></xsl:template>
 <xsl:template match="BK">
 <xsl:apply-templates select="BankName"/><xsl:text> </xsl:text><xsl:apply-templates select="Established"/><xsl:text>    </xsl:text><xsl:apply-templates select="RoutingNbr"/><xsl:text>
 </xsl:text>
 <xsl:apply-templates select="OfficeOfLabel"/>
 <xsl:apply-templates select="Address1"/><xsl:text> </xsl:text><xsl:apply-templates select="Hours"/><xsl:text>
 </xsl:text>
 <xsl:apply-templates select="Address2"/><xsl:apply-templates select="Zip"/>
 <xsl:apply-templates select="Phone"/><xsl:apply-templates select="Fax"/><xsl:text>
 </xsl:text>
 <xsl:apply-templates select="Email"/>
 <xsl:apply-templates select="Web"/>
 <xsl:apply-templates select="HoldingCo"/>
 <xsl:apply-templates select="TotalAssets"/><xsl:apply-templates select="TotalLiabilities"/>
 <xsl:apply-templates select="TotalDeposits"/><xsl:apply-templates select="EquityCapital"/>
 <xsl:apply-templates select="EH/Employee"/>
 <xsl:apply-templates select="D"/>
 <xsl:apply-templates select="CB"/>
 <xsl:apply-templates select="OFF"/>
 <xsl:apply-templates select="CO"/>
 <xsl:apply-templates select="MultiBankLabel"/>
 <xsl:apply-templates select="IBAGroup"/><xsl:apply-templates select="FDICNbr"/>
 </xsl:template>

 <xsl:template match="HoldingCo">
 <HoldingCo>
 <xsl:text>Holding Co: </xsl:text>
 <xsl:value-of select="."/></HoldingCo><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="Phone">
 <Phone><xsl:value-of select="."/></Phone><xsl:text>    </xsl:text></xsl:template>

 <xsl:template match="Fax">
 <Fax><xsl:value-of select="."/></Fax></xsl:template>

 <xsl:template match="EH/Employee">
 <Employee><xsl:value-of select="."/></Employee><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="Zip">
 <Zip><xsl:value-of select="."/></Zip><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="Address2">
 <Address2><xsl:value-of select="."/></Address2><xsl:text>  </xsl:text>
 </xsl:template>

 <xsl:template match="Email">
  <Email><xsl:value-of select="."/></Email><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="Web">
  <Web><xsl:text>Web: </xsl:text><xsl:value-of select="."/></Web><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="TotalAssets">
  <TotalAssets><xsl:text>Total Assets   $</xsl:text><xsl:value-of select="."/></TotalAssets><xsl:text>  </xsl:text>
 </xsl:template>

 <xsl:template match="TotalLiabilities">
  <TotalLiabilities><xsl:text>Total Liabilities $</xsl:text>
   <xsl:value-of select="."/></TotalLiabilities><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="TotalDeposits">
  <TotalDeposits><xsl:text>Total Deposits   </xsl:text>
   <xsl:value-of select="."/></TotalDeposits><xsl:text> </xsl:text>
 </xsl:template>

 <xsl:template match="EquityCapital">
  <EquityCapital><xsl:text>Equity Capital   </xsl:text><xsl:value-of select="."/></EquityCapital><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="IBAGroup">
  <IBAGroup><xsl:text>IBA Group: </xsl:text><xsl:value-of select="."/></IBAGroup><xsl:text> </xsl:text>
 </xsl:template>

 <xsl:template match="FDICNbr">
  <FDICNbr><xsl:text>FDIC Certificate No.: </xsl:text><xsl:value-of select="."/></FDICNbr><xsl:text>
 </xsl:text></xsl:template> 

 <xsl:template match="OFF"><OfficeLabel><xsl:value-of select="OfficeLabel"/><xsl:text>: </xsl:text></OfficeLabel><Office><xsl:value-of select="Office"/></Office><xsl:text>
 </xsl:text></xsl:template> 

 <xsl:template match="D"><DirectorLabel><xsl:value-of select="DirectorLabel"/><xsl:text>: </xsl:text></DirectorLabel><Director><xsl:value-of select="Director"/></Director><xsl:text>
 </xsl:text></xsl:template> 

 <xsl:template match="CB"><CorrespondingBankLabel><xsl:value-of select="CorrespondingBankLabel"/></CorrespondingBankLabel><xsl:text>: </xsl:text><CorrespondingBank><xsl:value-of select="CorrespondingBank"/></CorrespondingBank><xsl:text>
 </xsl:text></xsl:template> 

 <xsl:template match="OfficeOfLabel">
 <OfficeOfLabel><xsl:value-of select="."/></OfficeOfLabel><xsl:text>
 </xsl:text></xsl:template>

 <xsl:template match="CO"><CityOfficeLabel><xsl:value-of select="CityOfficeLabel"/><xsl:text>:
 </xsl:text></CityOfficeLabel><CityOfficeAddress1><xsl:value-of select="CityOfficeAddress1"/></CityOfficeAddress1><xsl:text>
 </xsl:text><CityOfficeZip><xsl:value-of select="CityOfficeZip"/></CityOfficeZip><xsl:text>
 </xsl:text><CityOfficePhone><xsl:value-of select="CityOfficePhone"/></CityOfficePhone><xsl:text>
 </xsl:text></xsl:template> 

 </xsl:stylesheet> 
Jim Maivald
  • 522
  • 6
  • 26
  • It's probably not related, but Chrome has a bug with its javascript engine that was causing any white space to be interpreted as a new line character (I asked a question about it here http://stackoverflow.com/questions/4822883). If Chrome and whatever you're using use the same xslt code, it might explain it. How is this 'appearing'? Are you using a browser to show it? If so, it might just be that the browser is wrapping it on encountering the white space tab character. – Flynn1179 Jun 14 '12 at 20:25

1 Answers1

2

the only thing I'm trying to do is to get the elements <CityDescription> and <Population> to appear on the same line in the output

This part of your code:

<xsl:template match="CityDescription"><CityDescription><xsl:value-of select="."/></CityDescription> <xsl:text>  
</xsl:text></xsl:template>

explicitly generates a NL character after the CityDescription element.

This causes anything that is additionally generated to appear at least one line below the CityDescription element.

One obvious solution is to remove the xslt:text that generates the NL character.

In case the NL character is replaced just with a few spaces, then the problem disappears.

Here is the corrected transformation:

<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
          <xsl:output omit-xml-declaration="yes" indent="no" />
     <xsl:strip-space elements="*"/>

     <xsl:output method="xml"/>
     <xsl:template match="/">

     <Root>
     <Story><xsl:apply-templates select="Root/Story/CL"/></Story>
     </Root>
     </xsl:template>
     <xsl:template match="CityDescription"><CityDescription><xsl:value-of select="."/></CityDescription>
    <xsl:text> </xsl:text></xsl:template><xsl:template match="CL/Population"><Population><xsl:value-of select="."/></Population></xsl:template>

     <xsl:template match="BankName | Address1 | Hours | Established | RoutingNbr | CO/CityOfficePhone | CO/CityOfficeAddress2 "><xsl:element name="{name()}"><xsl:value-of select="."/></xsl:element></xsl:template>
     <xsl:template match="BK">
     <xsl:apply-templates select="BankName"/><xsl:text> </xsl:text><xsl:apply-templates select="Established"/><xsl:text>    </xsl:text><xsl:apply-templates select="RoutingNbr"/><xsl:text>
     </xsl:text>
     <xsl:apply-templates select="OfficeOfLabel"/>
     <xsl:apply-templates select="Address1"/><xsl:text> </xsl:text><xsl:apply-templates select="Hours"/><xsl:text>
     </xsl:text>
     <xsl:apply-templates select="Address2"/><xsl:apply-templates select="Zip"/>
     <xsl:apply-templates select="Phone"/><xsl:apply-templates select="Fax"/><xsl:text>
     </xsl:text>
     <xsl:apply-templates select="Email"/>
     <xsl:apply-templates select="Web"/>
     <xsl:apply-templates select="HoldingCo"/>
     <xsl:apply-templates select="TotalAssets"/><xsl:apply-templates select="TotalLiabilities"/>
     <xsl:apply-templates select="TotalDeposits"/><xsl:apply-templates select="EquityCapital"/>
     <xsl:apply-templates select="EH/Employee"/>
     <xsl:apply-templates select="D"/>
     <xsl:apply-templates select="CB"/>
     <xsl:apply-templates select="OFF"/>
     <xsl:apply-templates select="CO"/>
     <xsl:apply-templates select="MultiBankLabel"/>
     <xsl:apply-templates select="IBAGroup"/><xsl:apply-templates select="FDICNbr"/>
     </xsl:template>

     <xsl:template match="HoldingCo">
     <HoldingCo>
     <xsl:text>Holding Co: </xsl:text>
     <xsl:value-of select="."/></HoldingCo><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="Phone">
     <Phone><xsl:value-of select="."/></Phone><xsl:text>    </xsl:text></xsl:template>

     <xsl:template match="Fax">
     <Fax><xsl:value-of select="."/></Fax></xsl:template>

     <xsl:template match="EH/Employee">
     <Employee><xsl:value-of select="."/></Employee><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="Zip">
     <Zip><xsl:value-of select="."/></Zip><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="Address2">
     <Address2><xsl:value-of select="."/></Address2><xsl:text>  </xsl:text>
     </xsl:template>

     <xsl:template match="Email">
      <Email><xsl:value-of select="."/></Email><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="Web">
      <Web><xsl:text>Web: </xsl:text><xsl:value-of select="."/></Web><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="TotalAssets">
      <TotalAssets><xsl:text>Total Assets   $</xsl:text><xsl:value-of select="."/></TotalAssets><xsl:text>  </xsl:text>
     </xsl:template>

     <xsl:template match="TotalLiabilities">
      <TotalLiabilities><xsl:text>Total Liabilities $</xsl:text>
       <xsl:value-of select="."/></TotalLiabilities><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="TotalDeposits">
      <TotalDeposits><xsl:text>Total Deposits   </xsl:text>
       <xsl:value-of select="."/></TotalDeposits><xsl:text> </xsl:text>
     </xsl:template>

     <xsl:template match="EquityCapital">
      <EquityCapital><xsl:text>Equity Capital   </xsl:text><xsl:value-of select="."/></EquityCapital><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="IBAGroup">
      <IBAGroup><xsl:text>IBA Group: </xsl:text><xsl:value-of select="."/></IBAGroup><xsl:text> </xsl:text>
     </xsl:template>

     <xsl:template match="FDICNbr">
      <FDICNbr><xsl:text>FDIC Certificate No.: </xsl:text><xsl:value-of select="."/></FDICNbr><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="OFF"><OfficeLabel><xsl:value-of select="OfficeLabel"/><xsl:text>: </xsl:text></OfficeLabel><Office><xsl:value-of select="Office"/></Office><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="D"><DirectorLabel><xsl:value-of select="DirectorLabel"/><xsl:text>: </xsl:text></DirectorLabel><Director><xsl:value-of select="Director"/></Director><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="CB"><CorrespondingBankLabel><xsl:value-of select="CorrespondingBankLabel"/></CorrespondingBankLabel><xsl:text>: </xsl:text><CorrespondingBank><xsl:value-of select="CorrespondingBank"/></CorrespondingBank><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="OfficeOfLabel">
     <OfficeOfLabel><xsl:value-of select="."/></OfficeOfLabel><xsl:text>
     </xsl:text></xsl:template>

     <xsl:template match="CO"><CityOfficeLabel><xsl:value-of select="CityOfficeLabel"/><xsl:text>:
     </xsl:text></CityOfficeLabel><CityOfficeAddress1><xsl:value-of select="CityOfficeAddress1"/></CityOfficeAddress1><xsl:text>
     </xsl:text><CityOfficeZip><xsl:value-of select="CityOfficeZip"/></CityOfficeZip><xsl:text>
     </xsl:text><CityOfficePhone><xsl:value-of select="CityOfficePhone"/></CityOfficePhone><xsl:text>
     </xsl:text></xsl:template>

</xsl:stylesheet>

when applied on the XML document provided in your previous question, with all nine different XSLT 1.0 and XSLT 2.0 processors I am using:

<Root>
    <Story>
        <CL>
            <CityDescription>ACKLEY, HARDIN CO.</CityDescription>
            <Population>POP. 1589</Population>
            <BK>
                <BankName>Ackley State Bank</BankName>
                <BankType>BANKS</BankType>
                <Established>Est. 1934</Established>
                <RoutingNbr>0739-0535-2</RoutingNbr>
                <Address1>650 Main St</Address1>
                <Hours>Hrs: M-F 8-3</Hours>
                <Address2>PO Box 149</Address2>
                <Zip>50601-1438</Zip>
                <Fax>FAX: (641) 847-2011</Fax>
                <Phone>(641) 847-2651</Phone>
                <Email>e-Mail: asbinfo@bankasb.com</Email>
                <WebURL>Web: www.ackleystatebank.com</WebURL>
                <HoldingCo>GNB Bancorporation, Grundy Center</HoldingCo>
                <SubChapS>Yes</SubChapS>
                <TotalAssets>128,319,000</TotalAssets>
                <TotalLiabilities>117,059,000</TotalLiabilities>
                <TotalDeposits>89,847,000</TotalDeposits>
                <EquityCapital>11,260,000</EquityCapital>
                <IBAGroup>7</IBAGroup>
                <FDICNbr>14936</FDICNbr>
                <EH>
                    <Employee>Kevin Swalley, Chmn</Employee>
                </EH>
                <EH>
                    <Employee>V.J. Barker, Pres</Employee>
                </EH>
                <EH>
                    <Employee>Kathy M Eichmeier, VP, Cash</Employee>
                </EH>
                <EH>
                    <Employee>Darren Janssen, VP</Employee>
                </EH>
                <EH>
                    <Employee>Gene Sandell, CFO</Employee>
                </EH>
                <EH>
                    <Employee>Angela M Luhring, SLO</Employee>
                </EH>
                <EH>
                    <Employee>Briget Meyer, Mktg</Employee>
                </EH>
                <EH>
                    <Employee>Josh Meyer, LO</Employee>
                </EH>
                <EH>
                    <Employee>Sharon Pudenz, LO</Employee>
                </EH>
                <EH>
                    <Employee>Deb Willms, TO</Employee>
                </EH>
                <D>
                    <DirectorLabel>Directors</DirectorLabel>
                    <Director>Doug Hofmeister, Hollis Janssen, Joseph Wojcik, Bob Johanns, Steve McDowell, Kevin Swalley, Mark Sexton, Verlin (Gus) Barker</Director>
                </D>
                <CB>
                    <CorrespondingBankLabel>Correspondent Banks</CorrespondingBankLabel>
                    <CorrespondingBank>Bankers Bank, Madison; FHLB, Des Moines; Quad City Bank &amp; Trust; UMB, Kansas City; US Bank, NA, Cedar Rapids</CorrespondingBank>
                </CB>
                <OFF>
                    <OfficeLabel>Offices</OfficeLabel>
                    <Office>Geneva, Iowa Falls, Story City</Office>
                </OFF>
            </BK>
            <BK>
                <BankName>Green Belt Bank &amp; Trust</BankName>
                <RoutingNbr>0739-2167-9</RoutingNbr>
                <Address1>419 Sherman Ave</Address1>
                <Zip>50601-1206</Zip>
                <Fax>FAX: (641) 847-0022</Fax>
                <Phone>(641) 847-0011</Phone>
                <OfficeOfLabel>Office of Green Belt Bank &amp; Trust, Iowa Falls</OfficeOfLabel>
                <EH>
                    <Employee>Janet DeBerg, VP, OM</Employee>
                </EH>
            </BK>
            <BK>
                <BankName>Peoples Savings Bank</BankName>
                <Address1>33149 161st St</Address1>
                <Zip>50601-7774</Zip>
                <Fax>FAX: (641) 847-2602</Fax>
                <Phone>(641) 847-3126</Phone>
                <OfficeOfLabel>Office of Peoples Savings Bank, Wellsburg</OfficeOfLabel>
                <EH>
                    <Employee>Lance Haupt, LO</Employee>
                </EH>
            </BK>
        </CL>
        <CL>
            <CityDescription>ADAIR, ADAIR CO.</CityDescription>
            <Population>POP. 781</Population>
            <BK>
                <BankName>Exchange State Bank</BankName>
                <BankType>BANKS</BankType>
                <Established>Est. 1879</Established>
                <RoutingNbr>0739-0680-1</RoutingNbr>
                <Address1>322 Audubon</Address1>
                <Hours>Hrs: M-TH 9-3 F 9-5</Hours>
                <Address2>PO Box 98</Address2>
                <Zip>50002-0098</Zip>
                <Fax>FAX: (641) 742-3424</Fax>
                <Phone>(641) 742-3201</Phone>
                <WebURL>Web: www.esbanks.com</WebURL>
                <HoldingCo>Exchange Financial Inc., Adair</HoldingCo>
                <SubChapS>Yes</SubChapS>
                <TotalAssets>51,817,000</TotalAssets>
                <TotalLiabilities>46,937,000</TotalLiabilities>
                <TotalDeposits>39,503,000</TotalDeposits>
                <EquityCapital>4,880,000</EquityCapital>
                <IBAGroup>5</IBAGroup>
                <FDICNbr>18838</FDICNbr>
                <EH>
                    <Employee>Charles J Gaffey, Pres, CEO</Employee>
                </EH>
                <EH>
                    <Employee>Kendall Kerns, EVP, RELO</Employee>
                </EH>
                <EH>
                    <Employee>Debra Lemke, VP, Cash</Employee>
                </EH>
                <EH>
                    <Employee>Lisa J Plowman, AVP, IT</Employee>
                </EH>
                <EH>
                    <Employee>Mel Jorgensen, COO</Employee>
                </EH>
                <D>
                    <DirectorLabel>Directors</DirectorLabel>
                    <Director>Harold Scholl, Rex Noland, W. Edward Littler, Jr., Forrest Schnobrich, Stan Kading, Chris Schafer, Charles Gaffey</Director>
                </D>
                <CB>
                    <CorrespondingBankLabel>Correspondent Banks</CorrespondingBankLabel>
                    <CorrespondingBank>FHLB, Des Moines; MIB, Jefferson City, MO</CorrespondingBank>
                </CB>
                <OFF>
                    <OfficeLabel>Office</OfficeLabel>
                    <Office>Winterset</Office>
                </OFF>
            </BK>
            <BK>
                <BankName>Rolling Hills Bank &amp; Trust</BankName>
                <Address1>502 Broad Street</Address1>
                <Zip>50002</Zip>
                <Fax>FAX: (641) 742-3436</Fax>
                <Phone>(641) 742-3432</Phone>
                <OfficeOfLabel>Office of Rolling Hills Bank &amp; Trust, Atlantic</OfficeOfLabel>
                <EH>
                    <Employee>Mary Beth Petty, VP, BM</Employee>
                </EH>
            </BK>
        </CL>
        <CL>
            <CityDescription>ADEL, DALLAS CO.</CityDescription>
            <Population>POP. 3682</Population>
            <BK>
                <BankName>Lincoln Savings Bank</BankName>
                <BankType>BANKS</BankType>
                <Address1>805 Main Street</Address1>
                <Zip>50003</Zip>
                <Fax>FAX: (515) 253-9502</Fax>
                <OfficeOfLabel>Office of Lincoln Savings Bank, Reinbeck</OfficeOfLabel>
            </BK>
            <BK>
                <BankName>Peoples Trust &amp; Savings Bank</BankName>
                <Established>Est. 1917</Established>
                <RoutingNbr>0739-1921-2</RoutingNbr>
                <Address1>804 Greenwood Hills Dr</Address1>
                <Hours>Hrs: M-F 9-4 Sat 9-12</Hours>
                <Address2>PO Box 98</Address2>
                <Zip>50003-0098</Zip>
                <Fax>FAX: (515) 993-5681</Fax>
                <Phone>(515) 993-5680</Phone>
                <Email>e-Mail: info@ptsbank.com</Email>
                <WebURL>Web: www.ptsbank.com</WebURL>
                <OfficeOfLabel>Office of Peoples Trust &amp; Savings Bank, Clive</OfficeOfLabel>
                <EH>
                    <Employee>Dean W Boettcher, EVP, Mkt Pres</Employee>
                </EH>
                <EH>
                    <Employee>Colby Dawes, VP</Employee>
                </EH>
                <EH>
                    <Employee>Doran T Ryan, VP</Employee>
                </EH>
            </BK>
            <BK>
                <BankName>Raccoon Valley Bank</BankName>
                <Established>Est. 1914</Established>
                <Address1>1009 Court St</Address1>
                <Hours>Hrs: M-F 8-6  SAT 9-12</Hours>
                <Zip>50003-1477</Zip>
                <Fax>FAX: (515) 993-5127</Fax>
                <Phone>(515) 993-4581</Phone>
                <Email>e-Mail: roger-platz@raccoonvalleybank.com</Email>
                <WebURL>Web: www.raccoonvalleybank.com</WebURL>
                <OfficeOfLabel>Office of Raccoon Valley Bank, Perry</OfficeOfLabel>
                <EH>
                    <Employee>Doug Zeigler, VP</Employee>
                </EH>
                <EH>
                    <Employee>Joan Barber, AC</Employee>
                </EH>
            </BK>
            <BK>
                <BankName>Wells Fargo Bank, N.A.</BankName>
                <RoutingNbr>0730-0082-0</RoutingNbr>
                <Address1>100 Nile Kinnick Drive</Address1>
                <Zip>50003</Zip>
                <Fax>FAX: (515) 993-4555</Fax>
                <Phone>(515) 993-4551</Phone>
                <OfficeOfLabel>Office of Wells Fargo Bank, N.A., Des Moines</OfficeOfLabel>
                <EH>
                    <Employee>Brett A Smith, Dist. Mgr</Employee>
                </EH>
            </BK>
        </CL>
    </Story>
</Root>

produces the following result -- and the elements CityDescription and Population are on the same line:

<Root><Story><CityDescription>ACKLEY, HARDIN CO.</CityDescription> <Population>POP. 1589</Population><BankName>Ackley State Bank</BankName> <Established>Est. 1934</Established> <RoutingNbr>0739-0535-2</RoutingNbr> <Address1>650 Main St</Address1> <Hours>Hrs: M-F 8-3</Hours> <Address2>PO Box 149</Address2> <Zip>50601-1438</Zip> <Phone>(641) 847-2651</Phone> <Fax>FAX: (641) 847-2011</Fax> <Email>e-Mail: asbinfo@bankasb.com</Email> <HoldingCo>Holding Co: GNB Bancorporation, Grundy Center</HoldingCo> <TotalAssets>Total Assets $128,319,000</TotalAssets> <TotalLiabilities>Total Liabilities $117,059,000</TotalLiabilities> <TotalDeposits>Total Deposits 89,847,000</TotalDeposits> <EquityCapital>Equity Capital 11,260,000</EquityCapital> <Employee>Kevin Swalley, Chmn</Employee> <Employee>V.J. Barker, Pres</Employee> <Employee>Kathy M Eichmeier, VP, Cash</Employee> <Employee>Darren Janssen, VP</Employee> <Employee>Gene Sandell, CFO</Employee> <Employee>Angela M Luhring, SLO</Employee> <Employee>Briget Meyer, Mktg</Employee> <Employee>Josh Meyer, LO</Employee> <Employee>Sharon Pudenz, LO</Employee> <Employee>Deb Willms, TO</Employee> <DirectorLabel>Directors: </DirectorLabel><Director>Doug Hofmeister, Hollis Janssen, Joseph Wojcik, Bob Johanns, Steve McDowell, Kevin Swalley, Mark Sexton, Verlin (Gus) Barker</Director> <CorrespondingBankLabel>Correspondent Banks</CorrespondingBankLabel>: <CorrespondingBank>Bankers Bank, Madison; FHLB, Des Moines; Quad City Bank & Trust; UMB, Kansas City; US Bank, NA, Cedar Rapids</CorrespondingBank> <OfficeLabel>Offices: </OfficeLabel><Office>Geneva, Iowa Falls, Story City</Office> <IBAGroup>IBA Group: 7</IBAGroup> <FDICNbr>FDIC Certificate No.: 14936</FDICNbr> <BankName>Green Belt Bank & Trust</BankName> <RoutingNbr>0739-2167-9</RoutingNbr> <OfficeOfLabel>Office of Green Belt Bank & Trust, Iowa Falls</OfficeOfLabel> <Address1>419 Sherman Ave</Address1> <Zip>50601-1206</Zip> <Phone>(641) 847-0011</Phone> <Fax>FAX: (641) 847-0022</Fax> <Employee>Janet DeBerg, VP, OM</Employee> <BankName>Peoples Savings Bank</BankName>
<OfficeOfLabel>Office of Peoples Savings Bank, Wellsburg</OfficeOfLabel> <Address1>33149 161st St</Address1>
<Zip>50601-7774</Zip> <Phone>(641) 847-3126</Phone> <Fax>FAX: (641) 847-2602</Fax> <Employee>Lance Haupt, LO</Employee> <CityDescription>ADAIR, ADAIR CO.</CityDescription> <Population>POP. 781</Population><BankName>Exchange State Bank</BankName> <Established>Est. 1879</Established> <RoutingNbr>0739-0680-1</RoutingNbr> <Address1>322 Audubon</Address1> <Hours>Hrs: M-TH 9-3 F 9-5</Hours> <Address2>PO Box 98</Address2> <Zip>50002-0098</Zip> <Phone>(641) 742-3201</Phone> <Fax>FAX: (641) 742-3424</Fax> <HoldingCo>Holding Co: Exchange Financial Inc., Adair</HoldingCo> <TotalAssets>Total Assets $51,817,000</TotalAssets> <TotalLiabilities>Total Liabilities $46,937,000</TotalLiabilities> <TotalDeposits>Total Deposits 39,503,000</TotalDeposits> <EquityCapital>Equity Capital 4,880,000</EquityCapital> <Employee>Charles J Gaffey, Pres, CEO</Employee> <Employee>Kendall Kerns, EVP, RELO</Employee> <Employee>Debra Lemke, VP, Cash</Employee> <Employee>Lisa J Plowman, AVP, IT</Employee> <Employee>Mel Jorgensen, COO</Employee> <DirectorLabel>Directors: </DirectorLabel><Director>Harold Scholl, Rex Noland, W. Edward Littler, Jr., Forrest Schnobrich, Stan Kading, Chris Schafer, Charles Gaffey</Director> <CorrespondingBankLabel>Correspondent Banks</CorrespondingBankLabel>: <CorrespondingBank>FHLB, Des Moines; MIB, Jefferson City, MO</CorrespondingBank> <OfficeLabel>Office: </OfficeLabel><Office>Winterset</Office> <IBAGroup>IBA Group: 5</IBAGroup> <FDICNbr>FDIC Certificate No.: 18838</FDICNbr> <BankName>Rolling Hills Bank & Trust</BankName>
<OfficeOfLabel>Office of Rolling Hills Bank & Trust, Atlantic</OfficeOfLabel> <Address1>502 Broad Street</Address1>
<Zip>50002</Zip> <Phone>(641) 742-3432</Phone> <Fax>FAX: (641) 742-3436</Fax> <Employee>Mary Beth Petty, VP, BM</Employee> <CityDescription>ADEL, DALLAS CO.</CityDescription> <Population>POP. 3682</Population><BankName>Lincoln Savings Bank</BankName>
<OfficeOfLabel>Office of Lincoln Savings Bank, Reinbeck</OfficeOfLabel> <Address1>805 Main Street</Address1> <Zip>50003</Zip> <Fax>FAX: (515) 253-9502</Fax> <BankName>Peoples Trust & Savings Bank</BankName> <Established>Est. 1917</Established> <RoutingNbr>0739-1921-2</RoutingNbr> <OfficeOfLabel>Office of Peoples Trust & Savings Bank, Clive</OfficeOfLabel> <Address1>804 Greenwood Hills Dr</Address1> <Hours>Hrs: M-F 9-4 Sat 9-12</Hours> <Address2>PO Box 98</Address2> <Zip>50003-0098</Zip> <Phone>(515) 993-5680</Phone> <Fax>FAX: (515) 993-5681</Fax> <Email>e-Mail: info@ptsbank.com</Email> <Employee>Dean W Boettcher, EVP, Mkt Pres</Employee> <Employee>Colby Dawes, VP</Employee> <Employee>Doran T Ryan, VP</Employee> <BankName>Raccoon Valley Bank</BankName> <Established>Est. 1914</Established>
<OfficeOfLabel>Office of Raccoon Valley Bank, Perry</OfficeOfLabel> <Address1>1009 Court St</Address1> <Hours>Hrs: M-F 8-6 SAT 9-12</Hours> <Zip>50003-1477</Zip> <Phone>(515) 993-4581</Phone> <Fax>FAX: (515) 993-5127</Fax> <Email>e-Mail: roger-platz@raccoonvalleybank.com</Email> <Employee>Doug Zeigler, VP</Employee> <Employee>Joan Barber, AC</Employee> <BankName>Wells Fargo Bank, N.A.</BankName> <RoutingNbr>0730-0082-0</RoutingNbr> <OfficeOfLabel>Office of Wells Fargo Bank, N.A., Des Moines</OfficeOfLabel> <Address1>100 Nile Kinnick Drive</Address1>
<Zip>50003</Zip> <Phone>(515) 993-4551</Phone> <Fax>FAX: (515) 993-4555</Fax> <Employee>Brett A Smith, Dist. Mgr</Employee> </Story></Root>

Flynn1179
  • 11,925
  • 6
  • 38
  • 74
Dimitre Novatchev
  • 240,661
  • 26
  • 293
  • 431
  • In my XSL, the xsl:text is supposed to be inserting a TAB character, not a NL. Would a TAB character cause this problem? I've never experienced it before. Several other lines in this same style sheet insert TAB characters correctly, do you know why this one would insert a NL? – Jim Maivald Jun 14 '12 at 14:48
  • The generated XML is being imported into Adobe InDesign. I removed the xsl:text element altogether and the XSL is still generating a line break. I tried to rebuild your original XSL by starting at the Story element instead of the CL element and then using a template to build a single line reference, but that created all sorts of other problems. Trying to get these two elements on the same line is my only remaining problem, aside from a few extraneous paragraph returns. FYI, the xsl:text element does actually insert a TAB but it is also inserting a PARAGRAPH too. I don't know why. – Jim Maivald Jun 14 '12 at 15:00
  • FYI, When I run the XSL through a parser, the two elements are on one line, but when I run it through InDesign it puts them on two separate lines. All the other templates work fine now. However, I do get a few extraneous blank paragraph returns in some elements. – Jim Maivald Jun 14 '12 at 15:01
  • @JimMaivald: Then this isn't an XSLT question at all -- what InDesign messes up is only InDesign problem. Please, edit the question and add this important fact there. Also, delete the xslt tag. – Dimitre Novatchev Jun 14 '12 at 15:34
  • It is an XSLT question. I am using the XSLT during the XML import. – Jim Maivald Jun 14 '12 at 15:39
  • @JimMaivald: It isn't XSLT question, because the problem is caused by InDesign -- not by XSLT. What I am saying is that one could spend indefinite amount of time writing XSLTwith the purpose of solving this problem -- only to confirm what we now know for sure -- it isn't XSLT problem at all. – Dimitre Novatchev Jun 14 '12 at 15:43
  • @JimMaivald: So, if you have time to waste, you can spend as much of it as you like trying to "solve" this problem with XSLT, but my recommendation is to invest this time in something useful. – Dimitre Novatchev Jun 14 '12 at 15:54
  • I have found a solution to the result without solving the problem. By using the Split Column feature of InDesign CS5 I can make the two elements appear on the same line, but they are still appearing in two separate paragraphs. The other elements work just fine, I don't see why the CityDescription and Population elements are still causing trouble. Thanks anyway. – Jim Maivald Jun 14 '12 at 16:47
  • It seems to me there should be a way just to concatenate the two elements. – Jim Maivald Jun 14 '12 at 16:48
  • @JimMaivald: There isn't a notion of "concatenating elements" in XSLT. – Dimitre Novatchev Jun 14 '12 at 16:50