我的XML短标记文件
<product>
<a001>CRITICAL-62258</a001
><a002>01</a002>
<productidentifier>
<b221>03</b221>
<b244>9781911106050</b244>
</productidentifier>
<productidentifier>
<b221>15</b221>
<b244>9781911106050</b244>
</productidentifier>
<b012>DG</b012>
<b385>10</b385>
<b211>002</b211>
<series>
<seriesidentifier>
<b273>01</b273>
<b233>Publishers Code</b233>
<b244>181</b244>
</seriesidentifier>
<b018>Critical Teaching</b018>
</series>
<title>
<b202>01</b202>
<b203>Creative Approaches to the Curriculum in Primary Foreign Languages</b203>
</title>
<workidentifier>
<b201>01</b201>
<b233>critical.stisontest.co.uk Content ID</b233>
<b244>48452</b244>
</workidentifier>
<contributor>
<b034>1</b034>
<b035>A01</b035>
<b036>Louise Pagden</b036>
<b037>Pagden, Louise</b037>
<b039>Louise</b039>
<b040>Pagden</b040>
<personnameidentifier>
<b390>01</b390>
<b233>www.stisonbooks.com Author ID</b233>
<b244>44217</b244>
</personnameidentifier>
<b044><p><strong>Louise Pagden is a senior lecturer in teacher development at the University of Winchester where she lectures in primary languages. She has many years of experience in this field, first as a primary school teacher and languages subject leader and later as a primary languages consultant in Hampshire. During her time there she was involved in the implementation of primary languages in the 350 primary schools in the county. Louise has taught in Spain, Argentina, Mexico and India. Her research interests lie in immersion teaching and content and language integrated learning. </strong></p></b044>
</contributor>
<n386/>
<b061>192</b061>
<b064>EDU029000</b064>
<b200>2</b200>
<b065>JNU</b065>
<b066>2.1</b066>
<subject>
<b067>12</b067>
<b068>2.1</b068>
<b069>JNMT</b069>
<b070>Teacher training</b070>
</subject>
<subject>
<b067>12</b067>
<b068>2.1</b068>
<b069>JNT</b069>
<b070>Teaching skills & techniques</b070>
</subject>
<subject>
<b067>23</b067>
<b069>PFL</b069>
<b070>Primary Foreign Languages</b070>
</subject>
<subject>
<b067>23</b067>
<b069>ED</b069>
<b070>Education</b070>
</subject>
<subject>
<b067>23</b067>
<b069>PR</b069>
<b070>Primary</b070>
</subject>
<subject>
<b067>20</b067>
<b070>Primary languages; Language teaching; Foreign languages</b070>
</subject>
<b073>06</b073>
<b073>09</b073>
<othertext>
<d102>01</d102>
<d103>02</d103>
<d104><p>This book enables trainee and qualified teachers to embrace a more creative approach to primary language teaching. The first part of the book focuses on key language skills, including reading, writing, speaking, listening, grammar and phonics, while the second part examines a range of different pedagogical approaches to language teaching, including flipped learning, CLIL, ICT and overseas partnerships. Each chapter includes links to the national curriculum objectives and the Key Stage 2 framework for languages, notes on progression and assessment, implications for transition and a detailed case study demonstrating the skill or approach in practice. In addition the text critically explores up-to-date theory and research, making clear links between theory and practice. </p>
</d104></othertext>
<othertext><d102>02</d102><d103>02</d103><d104><p>An up to date text for trainee and qualified primary teachers promoting a more creative approach to primary language teaching. </p>
</d104></othertext>
<othertext>
<d102>04</d102><d104><p><em>Glossary</em></p>
<p><em>Introduction</em></p>
<p><strong>PART 1: Key skills</strong></p>
<p><span>1. Speaking and listening</span></p>
<p><span>2. Reading </span></p>
<p><span>3. Writing</span></p>
<p><span>4. Getting to grips with grammar</span></p>
<p><span>5. Phonics</span></p>
<p><strong>PART 2: Contexts for learning</strong></p>
<p><span>6. Cross-curricular links: music and arts; drama and role play</span></p>
<p><span>7. CLIL and immersion</span></p>
<p><span>8. Languages in the digital age</span></p>
<p><span>9. Enquiry based learning</span></p>
<p><span>10. Partnerships and exchanges</span></p>
<p><em>Key websites and sources of support</em></p>
<p><em>Bibliography</em></p>
<p><em>Index</em></p>
</d104>
</othertext>
<othertext>
<d102>18</d102>
<d104>
<p>This book enables trainee and qualified teachers to embrace a more creative approach to primary language teaching. The first part of the book focuses on key language skills, including reading, writing, speaking, listening, grammar and phonics, while the second part examines a range of different pedagogical approaches to language teaching, including flipped learning, CLIL, ICT and overseas partnerships. Each chapter includes links to the national curriculum objectives and the Key Stage 2 framework for languages, notes on progression and assessment, implications for transition and a detailed case study demonstrating the skill or approach in practice. In addition the text critically explores up-to-date theory and research, making clear links between theory and practice. </p>
</d104>
</othertext>
<productwebsite>
<b367>01</b367>
<f123>www.criticalpublishing.com</f123>
</productwebsite>
<imprint>
<b241>02</b241>
<b242>Proprietary</b242>
<b243>CPC</b243>
<b079>Critical Publishing</b079>
</imprint>
<publisher>
<b291>01</b291>
<b081>Critical Publishing</b081>
</publisher>
<b209>Northwich</b209>
<b083>GB</b083>
<b394>02</b394>
<b003>20170120</b003>
<salesrights>
<b089>01</b089>
<b388>WORLD</b388>
</salesrights>
<relatedproduct>
<h208>06</h208>
<productidentifier>
<b221>15</b221>
<b244>9781911106036</b244>
</productidentifier>
</relatedproduct>
<relatedproduct>
<h208>06</h208>
<productidentifier>
<b221>15</b221>
<b244>9781911106043</b244>
</productidentifier>
</relatedproduct>
<relatedproduct>
<h208>13</h208>
<productidentifier>
<b221>15</b221>
<b244>9781911106029</b244>
</productidentifier>
</relatedproduct>
<supplydetail>
<j137>NBN International</j137>
<j396>10</j396>
<j142>20170113</j142>
<price>
<j148>01</j148>
<j151>26.00</j151>
<j152>EUR</j152>
</price>
<price>
<j148>02</j148>
<j151>22.00</j151>
<j152>GBP</j152>
<j153>S</j153>
<j154>20.0</j154>
<j155>18.50</j155>
<j156>3.50</j156>
</price>
</supplydetail>
<supplydetail>
<j137>International Specialized Book Services</j137>
<j270>1-800-944-6190</j270><j272>customerservice@isbs.com</j272>
<j138>US</j138>
<j396>10</j396>
<j142>20170113</j142>
<price>
<j148>01</j148>
<j151>33.00</j151>
<j152>USD</j152>
</price>
</supplydetail>
</product>我想将这个简短的标记名转换为引用标记名。为了转换成短的标记名,我尝试了这个
我创建了一个文件夹,并将xml文件和jar文件放入其中。为了进行转换,我找到了一个名为Saxon.jar的jar。我打开了我的命令提示符,因为我进入了我放置文件的位置。
E:\Arunselvan> java标记名saxon9.jar "criticalonix.xml“开关-onix -jar -2.0.xsl-jar-document=”“dtd--jar ="ONIX_BookProduct_3.0_reference.dtd”如果我给出这个错误,我会认为: Bad param =命令行上的值对。我将命令提示符图像放在下面
我的截图在这里Screenshot of short tag to reference tag conversion
我希望输出文件像这个引用标记名一样
<Product>
<RecordReference>1512722278</RecordReference>
<NotificationType>04</NotificationType>
<ProductIdentifier>
<ProductIDType>02</ProductIDType>
<IDValue>1512722278</IDValue>
</ProductIdentifier>
<ProductIdentifier>
<ProductIDType>03</ProductIDType>
<IDValue>9781512722277</IDValue>
</ProductIdentifier>
<ProductIdentifier>
<ProductIDType>15</ProductIDType>
<IDValue>9781512722277</IDValue>
</ProductIdentifier>
<ProductForm>BC</ProductForm>
<ProductFormDetail>B102</ProductFormDetail>
<ProductFormFeature>
<ProductFormFeatureType>02</ProductFormFeatureType>
<ProductFormFeatureDescription>CRE</ProductFormFeatureDescription>
</ProductFormFeature>
<TitleDetail>
<TitleType>01</TitleType>
<TitleElement>
<TitleElementLevel>01</TitleElementLevel>
<TitleText>Everyday Evangelism</TitleText>
<SubTitle> Practical Tips to Use Today</SubTitle>
</TitleElement>
</TitleDetail>
<Contributor>
<SequenceNumber>1</SequenceNumber>
<ContributorRole>A01</ContributorRole>
<PersonName>Laura Yang </PersonName>
<PersonNameInverted>Yang, Laura</PersonNameInverted>
<NamesBeforeKey>Laura </NamesBeforeKey>
<KeyNames>Yang</KeyNames>
</Contributor>
<EditionVersionNumber>20160205204457</EditionVersionNumber>
<Language>
<LanguageRole>01</LanguageRole>
<LanguageCode>eng</LanguageCode>
</Language>
<NumberOfPages>96</NumberOfPages>
<Illustrations>
<IllustrationType>01</IllustrationType>
<IllustrationTypeDescription>1:B&amp;W 5.5 x 8.5 in or 216 x 140 mm (Demy 8vo) Perfect Bound on Creme w/Gloss Lam</IllustrationTypeDescription>
</Illustrations>
<Subject>
<MainSubject />
<SubjectSchemeIdentifier>10</SubjectSchemeIdentifier>
<SubjectCode>REL012070</SubjectCode>
<SubjectHeadingText>Religion : Christian Life - Personal Growth</SubjectHeadingText>
</Subject>
<Subject>
<SubjectSchemeIdentifier>10</SubjectSchemeIdentifier>
<SubjectCode>REL012100</SubjectCode>
<SubjectHeadingText>Religion : Christian Life - Relationships</SubjectHeadingText>
</Subject>
<Subject>
<SubjectSchemeIdentifier>10</SubjectSchemeIdentifier>
<SubjectCode>REL012120</SubjectCode>
<SubjectHeadingText>Religion : Christian Life - Spiritual Growth</SubjectHeadingText>
</Subject>
<TextContent>
<TextType>03</TextType>
<ContentAudience>00</ContentAudience>
<Text textformat="02"><![CDATA[<p>Written by an "everyday" Christian, this book contains simple, straightforward suggestions for sharing your faith. Everyday Evangelism empowers you to tell others about Christ today.<p>
<p>Discover new ideas and practical ways to share the gospel in your daily life. Interspersed with scripture, the tips are grouped into eleven categories-for example: "Super Simple," "Critical Conversation," and "Often-Forgotten."<p>
<p>Experience the exhilarating joy that God intends for you by sharing the gospel. Use Everyday Evangelism as a tool to unleash the power of the Holy Spirit within you to "go and make disciples of all nations" (Matthew 28:19).</p>]]></Text>
</TextContent>
<SupportingResource>
<ResourceContentType>01</ResourceContentType>
<ContentAudience>00</ContentAudience>
<ResourceMode>03</ResourceMode>
<ResourceVersion>
<ResourceForm>02</ResourceForm>
<ResourceVersionFeature>
<ResourceVersionFeatureType>01</ResourceVersionFeatureType>
<FeatureValue>D502</FeatureValue>
</ResourceVersionFeature>
</ResourceVersion>
<ResourceLink>http://image-hub.lightningsource.com/2011-04-01/Images/front_cover/x/sku/1512722278.jpg</ResourceLink>
</SupportingResource>
<SupportingResource>
<ResourceContentType>02</ResourceContentType>
<ContentAudience>00</ContentAudience>
<ResourceMode>03</ResourceMode>
<ResourceVersion>
<ResourceForm>02</ResourceForm>
<ResourceVersionFeature>
<ResourceVersionFeatureType>01</ResourceVersionFeatureType>
<FeatureValue>D502</FeatureValue>
</ResourceVersionFeature>
</ResourceVersion>
<ResourceLink>http://image-hub.lightningsource.com/2011-04-01/Images/back_cover/x/sku/1512722278.jpg</ResourceLink>
</SupportingResource>
<PublishingDetail>
<Imprint>
<ImprintName>Westbow Press</ImprintName>
</Imprint>
<Publisher>
<PublisherName>AuthorHouse</PublisherName>
</Publisher>
</PublishingDetail>
<PublishingDate>
<PublishingDateRole>01</PublishingDateRole>
<DateFormat>00</DateFormat>
<Date>20160205</Date>
</PublishingDate>
<Measure>
<MeasureType>01</MeasureType>
<Measurement>8.50</Measurement>
<MeasureUnitCode>in</MeasureUnitCode>
</Measure>
<Measure>
<MeasureType>02</MeasureType>
<Measurement>5.50</Measurement>
<MeasureUnitCode>in</MeasureUnitCode>
</Measure>
<Measure>
<MeasureType>03</MeasureType>
<Measurement>0.23</Measurement>
<MeasureUnitCode>in</MeasureUnitCode>
</Measure>
<Measure>
<MeasureType>08</MeasureType>
<Measurement>0.294</Measurement>
<MeasureUnitCode>lb</MeasureUnitCode>
</Measure>
<ProductSupply>
<Market>
<Territory>
<CountriesIncluded>IN</CountriesIncluded>
</Territory>
<SupplyDetail>
<Supplier>
<SupplierRole>07</SupplierRole>
<SupplierName>Lightning Source Inc.</SupplierName>
</Supplier>
<ReturnsConditions>
<ReturnsCodeType>02</ReturnsCodeType>
<ReturnsCode>N</ReturnsCode>
</ReturnsConditions>
<ProductAvailability>20</ProductAvailability>
<SupplyDate>
<SupplyDateRole>08</SupplyDateRole>
<DateFormat>00</DateFormat>
<Date>20160205</Date>
</SupplyDate>
<Stock>
<PackQuantity>72</PackQuantity>
</Stock>
<Price>
<PriceType>01</PriceType>
<DiscountCoded>
<DiscountCodeType>02</DiscountCodeType>
<DiscountCodeTypeName>LSI</DiscountCodeTypeName>
<DiscountCode>36</DiscountCode>
</DiscountCoded>
<PriceAmount>9.95</PriceAmount>
<CurrencyCode>USD</CurrencyCode>
</Price>
</SupplyDetail>
</Market>
</ProductSupply>
</Product>发布于 2016-05-05 20:48:59
1) Windows命令行中等号前后不能有空格。所以它应该是
dtd-path="ONIX_BookProduct_3.0_reference.dtd" 而不是
dtd-path ="ONIX_BookProduct_3.0_reference.dtd" 这就是为什么会出现"Bad param = value pair“错误的原因
2)您输入的XML包含与号(&),这是XML格式的保留字符。将其替换为&实体
3)显然在这个地址上找不到这个DTD。您应该下载所有必需的DTD:
可在此处找到:http://www.editeur.org/files/ONIX%203/ONIX_BookProduct_DTDs+codes_Issue_33.zip
然后,您可以在DTD声明中指向本地文件。我还认为您的输入文件应该包含DTD声明和ONIX版本信息:
<?xml version=1.0 encoding=UTF-8"?>
<!DOCTYPE ONIXmessage SYSTEM "ONIX_BookProduct_3.0_reference.dtd">
<ONIXmessage release="3.0">
...
(your original XML short tag input)
...
</ONIXmessage>假设您将DTD解压到相同的目录,则此声明是正确的。
发布于 2016-05-05 17:58:52
假设您想要使用样式表http://www.editeur.org/files/ONIX%203/switch-onix-tagnames-2.0.xsl,那么它看起来像是接受了一些参数,名为result-document的应该是结果文件的名称,因此您需要确定该名称并传递给它。作为结果文件名的空字符串不起作用。
所以试一试
java -jar saxon9.jar criticalonix.xml switch-onix-tagnames-2.0.xsl result-document=result.xml dtd-path=ONIX_BookProduct_3.0_reference.dtdhttps://stackoverflow.com/questions/37044611
复制相似问题