[development] Issues with disabling a form field

jeff at ayendesigns.com jeff at ayendesigns.com
Fri Jan 21 15:47:59 UTC 2011


I'm using the method given at 
http://drupal.org/node/357328#comment-3021230 to disable a submit button 
in a form (after trying to simply set #disabled in hook_form_alter). I 
have the module set with a weight of 10, the code works as it should in 
terms of setting the attribute for the field (below), but the field is 
not disabled. I note that the attribute is being set to 'disabled' 
rather than TRUE in this and another almost identical example. I tried 
it with TRUE just in case, to no avail.


checkout(/Array,*21 elements*/)

    *
      #type(/String,*6 characters*/)*submit*
    *
      #value(/String,*8 characters*/)*Checkout*
    *
      #submit(/Array,*1 element*/)
    *
      #post(/Array,*0 elements*/)
    *
      #programmed(/Boolean/)*FALSE*
    *
      #tree(/Boolean/)*FALSE*
    *
      #parents(/Array,*1 element*/)
    *
      #array_parents(/Array,*1 element*/)
    *
      #weight(/Float/)*0.003*
    *
      #processed(/Boolean/)*TRUE*
    *
      #description(/NULL/)
    *
      #attributes(/Array,*1 element*/)
          o
            disabled(/String,*8 characters*/)*disabled*
    *
      #required(/Boolean/)*FALSE*
    *
      #input(/Boolean/)*TRUE*
    *
      #name(/String,*2 characters*/)*op*
    *
      #button_type(/String,*6 characters*/)*submit*
    *
      #executes_submit_callback(/Boolean/)*TRUE*
    *
      #process(/Array,*1 element*/)
    *
      #id(/String,*13 characters*/)*edit-checkout*
    *
      #defaults_loaded(/Boolean/)*TRUE*
    *
      #sorted(/Boolean/)*TRUE*



-- 

Ayen Designs
388 Bullsboro Drive #105 · Newnan, Georgia 30263
404-271-9734
Web:ayendesigns.com <http://ayendesigns.com>
Blog: theAccidentalCoder.com <http://theaccidentalcoder.com>
Drupal: j. ayen green <http://drupal.org/user/367108>
IRQ: j_ayen_green
IM (Yahoo) baalwww    (MSN) baalwww at yahoo.com
Skype: ayendesigns

Ayen Designs is a tradename of the computer services division of

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drupal.org/pipermail/development/attachments/20110121/61322aa4/attachment-0001.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ayenlogo
Type: image/jpeg
Size: 8316 bytes
Desc: not available
Url : http://lists.drupal.org/pipermail/development/attachments/20110121/61322aa4/attachment-0002.jpe 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: acmelogo
Type: image/jpeg
Size: 1462 bytes
Desc: not available
Url : http://lists.drupal.org/pipermail/development/attachments/20110121/61322aa4/attachment-0003.jpe 


More information about the development mailing list