Closed (fixed)
Project:
Drupal core
Version:
5.x-dev
Component:
forms system
Priority:
Minor
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
13 Apr 2007 at 16:21 UTC
Updated:
28 Jun 2007 at 06:45 UTC
Jump to comment: Most recent file
Comments
Comment #1
RobRoy commentedExcept that these are not required in user/X/edit. Confirm password is only required if you put something in the first password box. I think...
Comment #2
ChrisKennedy commentedmkalkbrenner is correct that the password file is required in certain cases, such as admin/user/user/create, but the current code does not properly allow this to be displayed. I noticed this tonight on the admin user page and came up with the exact same patch, which properly transfers the required property of the password form (whether it is set to TRUE or FALSE).
Comment #3
ChrisKennedy commented"password file" -> "password field"
As long as I'm updating I'll also note that this is a simple port to d6 as well.
Comment #4
ChrisKennedy commentedHere's the direct d6 patch.
Comment #5
RobRoy commentedOops. I took a quick look at the patch and somehow thought it was doing a blanket set of #required => TRUE instead of passing the required value along in theme_password. You're right.
Comment #6
ChrisKennedy commentedBump - this is still RTBC unless someone has issues with it.
Comment #7
dries commentedThis patch looks OK to me, although it would be comforting to get chx's or Eaton's "+1". :)
Comment #8
drewish commented+1 works as advertised, all the patch changes is making it obvious that required fields are required.
Comment #9
ChrisKennedy commentedA similar fix for this issue was posted back in March, btw: http://drupal.org/node/126549
Comment #10
dries commentedPatch no longer applies against CVS HEAD. I'll go ahead and commit it, as soon it's re-rolled.
Comment #11
ChrisKennedy commentedI thought about it some more and came up with a slightly more abstract patch. It combines the #size and #required pass-throughts into a more general foreach loop.
I also realized that a simple array_merge on pass1 and pass2 would allow forms to individually customize the form attributes for those elements. So with this patch you could specify a description or other custom attributes just for pass1 (or just for pass2), which wasn't possible previously.
Comment #12
ChrisKennedy commentedBuuump.
Comment #13
dries commentedChris, I liked the first patch better -- more transparent and easier to follow. I've re-rolled that patch and committed it to CVS HEAD. Thanks.
Comment #14
ChrisKennedy commentedFair enough - it should be fixed in D5 too though.
Comment #15
drummThe committed patch, http://cvs.drupal.org/viewcvs/drupal/drupal/includes/form.inc?r1=1.200&r..., does not apply to Drupal 5 CVS. It will need a reroll.
Comment #16
ChrisKennedy commentedYou can use the patch in the original issue post - it's against D5 and is equivalent to what was committed.
Comment #17
drummCommitted to 5.
Comment #18
(not verified) commented