RE: Does Xforms bind foce ajax

Posted by Richard Braman on
URL: https://discuss.orbeon.com/DMV-Forms-Example-tp27273p27338.html

I don't know, I tried removing the ajax code, but am getting nowhere.
Maybe its not ajax, but if its not, I don't know where else to search.
I just don't want the span tag holding
tyle="height:22px;width:209px;margin:0px;font-size:16px.  This should be
in the input tag.

This:
<div style="position:absolute; left:110px; top:61px; width:209px;
height:22px;">
                        <xforms:input pdf:x-position="202"
pdf:y-position="1048" xhtml:type="text" bind="f1-1"
xhtml:style="height:22px;width:209px;margin:0px;font-size:16px"/>
                </div>

Is becoming this:
   <div style="position:absolute; left:110px; top:61px; width:209px;
height:22px;"><span id="xforms-element-78" class="xforms-control
xforms-input" type="text"
style="height:22px;width:209px;margin:0px;font-size:16px"><span
class="xforms-date-display"></span><input type="text"
name="xforms-element-78" value="" class="xforms-input-input
xforms-type-string"><span class="xforms-showcalendar
xforms-type-string"></span></span><label class="xforms-alert
xforms-alert-inactive" for="xforms-element-78"></label></div>




-----Original Message-----
From: Richard Braman [mailto:[hidden email]]
Sent: Thursday, February 09, 2006 2:35 PM
To: [hidden email]
Subject: [ops-users] Does Xforms bind foce ajax


It seems when I switched to using x forms:bid, it sent tverything into
ajax.  I see at least one issue with ajax.  The code below seems to puts
a span tag around the xforms input, which doesn't work on IE.  What if I
don't want to use AJAX?  I am trying to keep everything on the server
and simple, as this is version 0.0.

<xhtml:span>
            <xsl:copy-of select="xxforms:copy-attributes(.,
('xforms-control', 'xforms-input'), $id)"/>
            <!-- Output for formatted date -->
            <xhtml:span>
                <xsl:variable name="showcalendar-readonly-class"
as="xs:string?"
                    select="if ($is-readonly) then 'xforms-readonly'
else ()"/>
                <xsl:copy-of select="xxforms:copy-attributes(.,
('xforms-date-display', $showcalendar-readonly-class), ())"/>
                <xsl:if test="$is-date-or-time">
                    <xsl:value-of
select="xxforms:control($id)/@display-value"/>
                </xsl:if>
            </xhtml:span>
            <!-- Input field -->
            <xhtml:input type="text" name="{$id}" value="{if
($generate-template) then '' else xxforms:control($id)}">
                <xsl:if test="not($generate-template) and
xxforms:control($id)/@readonly = 'true'">
                    <xsl:attribute
name="disabled">disabled</xsl:attribute>
                </xsl:if>
                <xsl:copy-of select="xxforms:copy-attributes(.,
($type-class), ())"/>
            </xhtml:input>

-----Original Message-----
From: Ryan Puddephatt [mailto:[hidden email]]
Sent: Wednesday, February 08, 2006 10:31 AM
To: [hidden email]
Subject: RE: [ops-users] x:forms:bind and xforms:model


Sorry just seen the instance, that should work!

Ryan Puddephatt
Software Engineer
TFX Group - IT UK
1 Michaelson Square
Livingston
West Lothian
Scotand
EH54 7DP
 
* [hidden email]
( 01506 407 110
7  01506 407 108
 

>-----Original Message-----
>From: Ryan Puddephatt [mailto:[hidden email]]
>Sent: 08 February 2006 15:24
>To: [hidden email]
>Subject: RE: [ops-users] x:forms:bind and xforms:model
>
>What is the structure of the src file f1040ez.xml? has it got a root
>node <form> or <f1040ex>?
>
>Try the following
>
><html>
><head>
>    <title>Form 1040 EZ 2005</title>
>    <xforms:model>
>        <xforms:instance id="main-instance" src="/xforms/f1040ez.xml"/>
>    </xforms:model>
></head>
>    <body bgcolor="#FFFFFF" text="#000000">
>        <xforms:input xhtml:type="text" ref="/form/f1040/f1-1"
>           xhtml:style="height:22px;width:209px;margin:0px;font-
>size:16px"/>
> </body>
></html>
>
>Ryan Puddephatt
>Software Engineer
>TFX Group - IT UK
>1 Michaelson Square
>Livingston
>West Lothian
>Scotand
>EH54 7DP
>
>* [hidden email]
>( 01506 407 110
>7  01506 407 108
>
>
>>-----Original Message-----
>>From: Richard Braman [mailto:[hidden email]]
>>Sent: 08 February 2006 15:07
>>To: [hidden email]
>>Subject: RE: [ops-users] x:forms:bind and xforms:model
>>
>>I have reproduced snippets from my code.  This code throws a response
>>cannot be null error in xForms-epilogue.xpl line 81.  I don't really
>>understand the syntax, because if it was the way understand it, it
>>would work :)
>>
>>Here is my view:
>>
>><html>
>><head>
>>        <title>Form 1040 EZ 2005</title>
>><xforms:model>
>><xforms:instance id="main-instance" src="/xforms/f1040ez.xml"/>
>><xforms:bind id="f1-1" nodeset="/form/f1040ez/f1-1"></xforms:bind>
>></xforms:model>
>></head>
>> <body bgcolor="#FFFFFF" text="#000000">
>>
>>
>> <xforms:input xhtml:type="text" bind="f1-1"
>>xhtml:style="height:22px;width:209px;margin:0px;font-size:16px"/>
>>
>> </body>
>></html>
>>
>>**********************************
>>Here is my input instance in file /xforms/f1040ez.xml
>>
>><xforms:model xmlns:xforms="http://www.w3.org/2002/xforms">
>> <xforms:instance>
>> <form>
>> <f1040ez>
>> <f1-1>first name</f1-1>
>> </f1040ez>
>> </form>
>> </xforms:instance>
>> <xforms:submission method="post"/>
>></xforms:model>
>>
>>
>>-----Original Message-----
>>From: Richard Braman [mailto:[hidden email]]
>>Sent: Wednesday, February 08, 2006 9:28 AM
>>To: [hidden email]
>>Subject: RE: [ops-users] x:forms:bind and xforms:model
>>
>>
>>I am trying to get my empty instance
>>
>>-----Original Message-----
>>From: Ryan Puddephatt [mailto:[hidden email]]
>>Sent: Wednesday, February 08, 2006 9:04 AM
>>To: [hidden email]
>>Subject: RE: [ops-users] x:forms:bind and xforms:model
>>
>>
>>Richard,
>> If your using the classic engine then the instance will be
defined in

>>the page-flow, but if your using the NG engine, which it looks like
>>your trying to! Then the instance is defined within the page.
>>
>>Ryan Puddephatt
>>Software Engineer
>>TFX Group - IT UK
>>1 Michaelson Square
>>Livingston
>>West Lothian
>>Scotand
>>EH54 7DP
>>
>>* [hidden email]
>>( 01506 407 110
>>7  01506 407 108
>>Any ideas on What is src="input:instance"
>>
>>>-----Original Message-----
>>>From: Richard Braman [mailto:[hidden email]]
>>>Sent: 08 February 2006 13:46
>>>To: [hidden email]
>>>Subject: RE: [ops-users] x:forms:bind and xforms:model
>>>
>>>What is src="input:instance"  ?
>>>I thought my src instance is specified in the page flow.... Is this
>>>instance passed into the instance in the view?
>>>
>>>-----Original Message-----
>>>From: Erik Bruchez [mailto:[hidden email]] On Behalf Of Erik
>>>Bruchez
>>>Sent: Wednesday, February 08, 2006 8:45 AM
>>>To: [hidden email]
>>>Subject: Re: [ops-users] x:forms:bind and xforms:model
>>>
>>>
>>>That goes under your /xhtml:html/xhtml:head in your page view, yes.
>>>
>>>-Erik
>>>
>>>Richard Braman wrote:
>>>>  Is thi syntax supported in3.0?  Where would this code go, in the
>>>> view?
>>>>
>>>>
>>>> <xforms:model xmlns:xforms="http://www.w3.org/2002/xforms">
>>>>
>>>>  <!--The actual XForms instance comes from the database -->
>>>>
>>>>  <!--This syntax has yet to be supported by the server-side XForms
>>>> processor -->
>>>>
>>>>  <xforms:instance id="main-instance"src="input:instance"/>
>>>>
>>>>  <!--Calculations -->
>>>>
>>>>  <xforms:bind nodeset="/form/this/is/a/calculated/value1"
>>>> calculate="sum(/form/some/repeated/values)"/>
>>>>
>>>>  <xforms:bind nodeset="/form/this/is/a/calculated/@value2"
>>>> calculate="if
>>>> (/form/some/value gt 1000)then 100.0 else 200.0"/> ...
>>>>
>>>>  </xforms:model>
>>>
>>>
>>>
>>
>>
>>
>>
>>
>>
>
>








--
You receive this message as a subscriber of the [hidden email] mailing list.
To unsubscribe: mailto:[hidden email]
For general help: mailto:[hidden email]?subject=help
ObjectWeb mailing lists service home page: http://www.objectweb.org/wws