countries.xplファイルをmymlからxmlにリダイレクトして読み込むように変更しました。Orbeon - xplから動的データに10以上の項目を表示
多くのアイテムをdinamycデータのドロップダウンに表示する必要があります。
私はこのラインでcountries.xpl修飾:iが値を更新する場合、これは動作し、iはdinamycのみ8の項目を参照し、数より少ない10、例えば "8" から "10"
<xsl:copy-of select="/countries/country[starts-with(lower-case(name),lower-case($name))][10 >= position()]"/>
をデータがドロップダウンします。
しかし、この値を10の「10」という数字から10の数字「11」に変更すると、dinamycデータには10個しか表示されず、11個以上は表示されません。
私の質問は です❑ダイナミックデータのドロップダウンに10個以上のアイテムが表示される可能性がありますか?
¿正確に行番号を変更しました<xsl:copy-of select="/countries...
?または私はxplの他の行を変更する必要がありますか?
私はXPLから継続的にコードattacht:ください私の
`<!--
Copyright (C) 2004 Orbeon, Inc.
This program is free software; you can redistribute it and/or modify it under the terms of the
GNU Lesser General Public License as published by the Free Software Foundation; either version
2.1 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Lesser General Public License for more details.
The full text of the license is available at http://www.gnu.org/copyleft/lesser.html
-->
<p:config xmlns:p="http://www.orbeon.com/oxf/pipeline"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:oxf="http://www.orbeon.com/oxf/processors"
xmlns:xh="http://www.w3.org/1999/xhtml"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<p:param name="instance" type="input"/>
<p:param name="data" type="output"/>
<p:processor name="oxf:request">
<p:input name="config">
<config>
<include>/request/parameters/parameter[name = 'country-name']</include>
<include>/request/parameters/parameter[name = 'all']</include>
</config>
</p:input>
<p:output name="data" id="request"/>
</p:processor>
<p:processor name="oxf:xslt">
<p:input name="data" href="countries.xml"/>
<p:input name="request" href="#request"/>
<p:input name="instance" href="#instance"/>
<p:input name="config">
<countries xsl:version="2.0">
<xsl:variable
name="name"
select="if (doc('input:instance')/*/@xsi:nil = 'true') (: No instance was posted to this service :)
then doc('input:request')/request/parameters/parameter[name = 'country-name']/value (: Try getting request parameter :)
else doc('input:instance')/instance/country-name (: Use name in posted instance :)"/>
<xsl:variable
name="all"
select="doc('input:request')/request/parameters/parameter[name = 'all']/value = 'true'"/>
<xsl:choose>
<!-- If no name is specified, just take the first 10 countries unless all=true -->
<xsl:when test="empty($name)">
<xsl:copy-of select="/countries/country[$all or position() le 10]"/>
</xsl:when>
<!-- Get first 10 countries that start with provided name -->
<xsl:otherwise>
<xsl:copy-of select="/countries/country[starts-with(lower-case(name), lower-case($name))][11 >= position()]"/>
</xsl:otherwise>
</xsl:choose>
</countries>
</p:input>
<p:output name="data" ref="data"/>
</p:processor>
</p:config>
ヘルプを。 多くのありがとう よろしくお願いします。
iはproperties.loca.xmlを変更し、 "XS:整数" =ように行 '<プロパティ を追加感謝avernet 名= "oxf.xforms.xbl.fr.autocomplete.max-結果、表示された" 値($ name)、小文字($ name))] [20] = "20"> 'を変更して、xpl行を変更しました。 ' work ...ありがとうございました:) –
優秀;私はうまくいってうれしいです、そして、更新のためにありがとう! – avernet