Re: Checkbox problem

Posted by Erik Bruchez on
URL: https://discuss.orbeon.com/DMV-Forms-Example-tp27273p27298.html

You have to understand that there is a translation from XForms to XHTML
which is taking place here. Each XForms control generates "a bunch" of
XHTML elements that are useful to render the control and that also allow
client-side code to discover the controls. The generated HTML may or may
not match your expectations, but in general, there is a good rationale.
For example, the type of an input field can change at runtime, from
xs:string to xs:date for example, and from an input field become a date
picker. The server-side code currently places placeholders in place for
that this scenario. This could certainly be optimized, but for now it
works and in general the extra elements are of no consequence.

-Erik

Richard Braman wrote:

> Aside form my styling problem the other thing I don't get is how:
>
> <div style="position:absolute; left:615px; top:218px;
> width:13px; height:14px;">
> <xforms:input pdf:x-position="707"
> pdf:y-position="891" xhtml:type="checkbox" bind="c1-1"
> xhtml:style="height:14px;width:13px;margin:0px;font-size:10px"/>
> </div>
>
> Becomes:
> <div style="position:absolute; left:615px; top:218px; width:13px;
> height:14px;">
> <span id="xforms-element-93" class="xforms-control xforms-input"
> type="checkbox"
> style="height:14px;width:13px;margin:0px;font-size:10px"><span
> class="xforms-date-display"></span>
> <input type="text" name="xforms-element-93" 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-93"></label></div>
>
> Also , why is there this code, which I don't want or need.  I am not
> tring to show a calendar.
> <span class="xforms-showcalendar xforms-type-string"></span>
> <span class="xforms-date-display"></span>



--
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