Hi Tim,

Here is a complete test form:

<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="../xsltforms/xsltforms.xsl" type="application/xml"?>
<?xsltforms-options debug="yes"?>
<?css-conversion no?>
<html xmlns="http://www.w3.org/1999/xhtml";
        xmlns:nr="http://www.nearby.org.uk";
        xmlns:xf="http://www.w3.org/2002/xforms"; 
        xmlns:ev="http://www.w3.org/2001/xml-events";>
        
        <head>
                <title>Test</title>


                <xf:model id="theModel">
                        <xf:instance id="var" xmlns="">
                                <doc>
                                        <!--co-ordinates-->
                                        <convert>
                                                <key>37d6c2c0832f6b</key>
                                                <p>303743,967206</p>
                                                <in>gr-osgb36</in>
                                                <need>gr10-osgb36</need>
                                                <output>sxml</output>
                                        </convert>
                                </doc>
                        </xf:instance>
                
                        <xf:instance id="gridRef">
                                <convert xmlns="http://www.nearby.org.uk"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xsi:schemaLocation="http://www.nearby.org.uk/api/convert.xsd";>
                                        <info 
href="http://www.nearby.org.uk/api/convert-help.php"/>
                                        <input>
                                                <en datum="osgb36" e="302872" 
n="966758"/>
                                        </input>
                                        <output>
                                                <gaz country="United Kingdom"/>
                                                <gr10 datum="osgb36" gr10="ND 
02872 66758"/>
                                                <gr datum="osgb36" 
gr="ND0287266758" digits="10"/>
                                                <ll datum="wgs84" 
lat="58.577939885331" long="-3.6719623952203"/>
                                        </output>
                                </convert>
                        </xf:instance>
                        
                        
                        <xf:submission id="getGridRef"
                                method="get"
                                replace="instance" 
                                instance="gridRef"
                                ref="instance('var')/convert"
                                
serialization="application/x-www-form-urlencoded"
                                
resource="http://www.nearby.org.uk/api/convert.php";>                
                                <xf:action ev:event="xforms-submit-error">      
             
                                        <xf:message level="modal">'<xf:output 
value="instance('var')/convert/p"/>' getGridRef didn't work</xf:message>
                                </xf:action>
                        </xf:submission>
                        
                </xf:model>
                
        </head>

        <body>
                        <xf:input ref="instance('var')/convert/p">
                                <xf:label>EPSG:27700 co-ordinates</xf:label>
                        </xf:input>
                
                        <xf:submit submission="getGridRef">
                                <xf:label>Get Ordnance Survey Grid 
Reference</xf:label>
                        </xf:submit>

                <p>OS Grid Reference is: <xf:output 
ref="instance('gridRef')/nr:output/nr:gr10/@gr10"/></p>
        </body>
</html>


> On 10 Jul 2015, at 21:01, Tim Thompson <[email protected]> wrote:
> 
> Hi, Mark,
> 
> What do your instances look like? Could you include a more complete example?
> 
> Best,
> Tim
> 
> 
> --
> Tim A. Thompson
> Metadata Librarian (Spanish/Portuguese Specialty)
> Princeton University Library
>  <mailto:[email protected]>
> 
> On Fri, Jul 10, 2015 at 2:45 PM, Mark Seaborne <[email protected] 
> <mailto:[email protected]>> wrote:
> Hi,
> 
> I have a simple submit that is failing, if anyone can suggest something to 
> try I would be very grateful. I’m sure I must have missed something obvious.
> 
> Here is what XSLTForms, build 615, reports:
> 
> Submit get - application/xml - 
> http://www.nearby.org.uk/api/convert.php?key=37d6c2c0832f6b&p=303657%2C965123&in=gr-osgb36&need=gr10-osgb36&output=sxml
>  
> <http://www.nearby.org.uk/api/convert.php?key=37d6c2c0832f6b&p=303657%2C965123&in=gr-osgb36&need=gr10-osgb36&output=sxml>
>  - false
> 
> If I copy the URL string into a browser the expected XML document is 
> returned, so there is no problem there.
> 
> Here is the submission itself:
> 
>                       <xf:submission id="getGridRef"
>                               method="get"
>                               replace="instance" 
>                               instance="coord"
>                               ref="instance('var')/convert"
>                               
> serialization="application/x-www-form-urlencoded"
>                               
> resource="http://www.nearby.org.uk/api/convert.php 
> <http://www.nearby.org.uk/api/convert.php>">                
>                               <xf:action ev:event="xforms-submit-error">      
>              
>                                       <xf:message level="modal">'<xf:output 
> value="instance('var')/convert/p"/>' getGridRef didn't work</xf:message>
>                               </xf:action>
>                       </xf:submission>
> 
> Best wishes
> 
> Mark
> 
> ------------------------------------------------------------------------------
> Don't Limit Your Business. Reach for the Cloud.
> GigeNET's Cloud Solutions provide you with the tools and support that
> you need to offload your IT needs and focus on growing your business.
> Configured For All Businesses. Start Your Cloud Today.
> https://www.gigenetcloud.com/ <https://www.gigenetcloud.com/>
> _______________________________________________
> Xsltforms-support mailing list
> [email protected] 
> <mailto:[email protected]>
> https://lists.sourceforge.net/lists/listinfo/xsltforms-support 
> <https://lists.sourceforge.net/lists/listinfo/xsltforms-support>
> 
> 

------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
Xsltforms-support mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xsltforms-support

Reply via email to