RE: xforms-disabled question

Posted by Ryan Puddephatt on
URL: https://discuss.orbeon.com/xforms-disabled-question-tp32439p32440.html

Jeff,
        You've fallen into the default namespace trap, add xmlns="" to
<mymodel> and it will work. This happens because you have your default
namespace as the xhtml namespace, but xpath doesn't take this default :-)

Ryan

Ryan Puddephatt
Software Engineer

Teleflex Group - IT UK
1 Michaelson Square
Livingston
West Lothian
Scotland
EH54 7DP

e> [hidden email]
t> +44(0)1506 407 110
f> +44(0)1506 407 108

 

>-----Original Message-----
>From: [hidden email] [mailto:[hidden email]]
>Sent: 19 January 2007 23:10
>To: [hidden email]
>Subject: [ops-users] xforms-disabled question
>
>-----BEGIN PGP SIGNED MESSAGE-----
>Hash: SHA1
>
>Why do some things render with the class including xforms-disabled?
>
>I have this code:
>
><html xmlns="http://www.w3.org/1999/xhtml"
>      xmlns:xforms="http://www.w3.org/2002/xforms"
>      xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>      xmlns:xxforms="http://orbeon.org/oxf/xml/xforms"
>      xsl:version="2.0">
>  <head>
>    <title>Hello World XForms</title>
>    <xforms:model>
>      <xforms:instance>
> <mymodel>
>          <first-name/>
>  <life-line-qualification/>
> </mymodel>
>      </xforms:instance>
>    </xforms:model>
>  </head>
>  <body>
>    <form id="hello-form">
>      <table>
> <thead>
>  <tr>
>    <th>Table of Checkboxes</th>
>  </tr>
> </thead>
> <tbody>
>  <tr>
>    <td>
>
>      <xforms:select ref="/mymodel/life-line-qualification"
>     appearance="full">
> <xforms:choices>
>  <xforms:item>
>    <xforms:label>Food Stamps/Vision Card</xforms:label>
>    <xforms:value>food_stamps_vision_card</xforms:value>
>  </xforms:item>
>  <xforms:item>
>    <xforms:label>Medicaid</xforms:label>
>    <xforms:value>medicaid</xforms:value>
>  </xforms:item>
> </xforms:choices>
>      </xforms:select>
>    </td>
>  </tr>
>  <tr>
>    <td>Something should be above here </td>
>  </tr>
> </tbody>
>      </table>
>    </form>
>  </body>
></html>
>
>
>which renders the checkboxes as:
>
><td>
>  <!-- What? xforms-disabled ?? -->
>  <span id="xforms-element-3" class="xforms-control
>xforms-select-full xforms-disabled">
>    <span>
>      <input type="checkbox" name="xforms-element-3"
>value="food_stamps_vision_card">Food Stamps/Vision Card
>    </span>
>    <span>
>      <input type="checkbox" name="xforms-element-3"
>value="medicaid">Medicaid
>    </span>
>  </span>
>  <label class="xforms-alert xforms-alert-active"
>for="xforms-element-3">
>  </label>
></td>
>
>
>What do I have to do to make these not disabled? I don't see
>anything wrong with my code, which I cut and paste from a
>working example (initially from the xforms documentation). I
>was trying to figure out how to make these show up vertically,
>but this small example doesn't even show the check boxes at all!
>
>Thanks for any help.
>Jeff
>
>-----BEGIN PGP SIGNATURE-----
>Version: GnuPG v1.4.2.2 (GNU/Linux)
>
>iD8DBQFFsU+9cZdQORGez0sRAkwvAJ43h8Qeu3HBRaxjZX2IBKYcSTloBQCgmuAU
>6Rs5vD94MmOqMu09afKwqqo=
>=QOl5
>-----END PGP SIGNATURE-----
>
>
>



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