🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.xml
Article #10283

Re: xslt - prosba o pomoc

#10283
From: rleg2000
Date: Wed, 19 Jun 2013 07:59
22 lines
2550 bytes
Na razie poradzilem sobie w ten sposob:
<?xml version='1.0'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
	<xsl:import href="copy.xslt"/>
	<xsl:output method="xml" version="1.0" encoding="UTF-8" omit-xml-declaration="no" indent="no" media-type="text/xml"/>
	<xsl:template match="t">
		<xsl:element name="t">
			<xsl:attribute name="p"><xsl:value-of select="@p"/></xsl:attribute>[<xsl:value-of select="following-sibling::item/@nr"/>] <xsl:apply-templates/>
		</xsl:element>
	</xsl:template>
</xsl:stylesheet>
problem pojawi sie, gdy bedzie wiecej atrybutow, a jeszcze gorzej, gdy nie bede wiedzial o jakims.

Ale mam teraz wiekszy problem ze spacjami, mianowicie ma np. paragraf:
	<item nr="47">
		<p class="pl">47. Et iterum: <i>Haereticum hominem post primam correptionem devita</i>,<span class="prz"> {[b Non pauci mss., <i>sciens quia perversus est</i>. Et infra unus, <i>proprio vitio damnatus</i>.]}</span> <i>sciens quia subversus est qui ejusmodi est, et delinquit, cum sit proprio judicio damnatus</i></p>
	</item>
	
po transformacji GINIE mi SPACJA miedzy "</span>" a "<i>", czyli otrzynuje "</span><i>" Jak ja odzyskac, co zmienic? Bo w przypadku ksiazki jest to nie do przyjecia.
	
Pozdrowienia
Robert
Technical Details
Message-ID: <068ccafa-64a8-46e7-b365-f0a1426afdc0@googlegroups.com>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!goblin2!goblin.stu.neva.ru!feeder.erje.net!us.feeder.erje.net!news.ripco.com!news.glorb.com!j2no789000qak.0!news-out.google.com!y6ni3510qax.0!nntp.google.com!j2no788990qak.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail
References: <a40f5135-226a-49b0-9293-7387ccc0fe0c@googlegroups.com>

Show Full Headers
Complete Article Headers
X-Received: by 10.224.200.202 with SMTP id ex10mr2453733qab.8.1371628762426;        Wed, 19 Jun 2013 00:59:22 -0700 (PDT)
X-Received: by 10.49.11.140 with SMTP id q12mr30797qeb.9.1371628762410; Wed, 19 Jun 2013 00:59:22 -0700 (PDT)
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!agh.edu.pl!news.agh.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!goblin2!goblin.stu.neva.ru!feeder.erje.net!us.feeder.erje.net!news.ripco.com!news.glorb.com!j2no789000qak.0!news-out.google.com!y6ni3510qax.0!nntp.google.com!j2no788990qak.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail
Newsgroups: pl.comp.xml
Date: Wed, 19 Jun 2013 00:59:22 -0700 (PDT)
In-Reply-To: <a40f5135-226a-49b0-9293-7387ccc0fe0c@googlegroups.com>
Complaints-To: groups-abuse@google.com
Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=83.17.169.154; posting-account=-0d7QAoAAACcoB5MUZQMIF_EGj4vE6di
NNTP-Posting-Host: 83.17.169.154
References: <a40f5135-226a-49b0-9293-7387ccc0fe0c@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <068ccafa-64a8-46e7-b365-f0a1426afdc0@googlegroups.com>
Subject: Re: xslt - prosba o pomoc
From: rleg2000@gmail.com
Injection-Date: Wed, 19 Jun 2013 07:59:22 +0000
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit