Needs review
Project:
Email Field
Version:
6.x-1.x-dev
Component:
User interface
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Aug 2009 at 06:38 UTC
Updated:
22 Apr 2011 at 02:05 UTC
Jump to comment: Most recent file


Comments
Comment #1
danepowell commentedI agree- this becomes very annoying when you have several lines of description text. However, I was not able to fix it myself in the manner that you described, so a patch would be appreciated. A good example of how this should behave is the standard text field, which only shows one description even for multiple values.
Also, it looks like the pictures in your post got overwritten by something completely unrelated... ? The attachments illustrate the problem though.
Comment #2
niklp commentedI have this too - email behaves differently on even fields that are allowed 2 values, not just "unlimited". Here is a comparison of text field versus email field, both set to exactly 2 instances.
Fortunately, I had this already developed :)
http://dl.getdropbox.com/u/72790/email_field_oddness.png
Comment #3
danepowell commentedIs anyone able to roll a patch for this? I wasn't able to figure it out.
Comment #4
niklp commentedCommenting out the description line at 224 removes the duplicated information on instances of the field where multiple values are allowed, but also removes the help text completely on single-only instances. Nightmare! :/
Comment #5
niklp commentedOk here's a partial fix, but this has to be added in a new/helper module, using form alterations. This appears to work with multiple and single instances of form elements, and leaves the generic description (under the entire form element) untouched. All good! :)
I've left all the "if" code intact as I've cut from my code - that's because I have a fair bit of form alteration code in this module - you may only need a small amount of the code below if you already have similar code in place in such a module.
Note that this code only works for ONE field - a field called "field_email" - if you have multiple email fields or they're named differently, you'll have to update the code accordingly.
Hope that helps. Only useful in the interim, of course.
Comment #6
danepowell commentedThanks NikLP-good solution for the interim. Surely everyone agrees that this is a bug that should be patched and not worked around with a separate module, right? Where is the maintainer on this? I would take a further look at this myself if there was at least some indication that the maintainer was interested in fixing it or at least reviewing patches...
Comment #7
bluestarstudios commentedThis is very annoying. Can we please find a work around? It's definitely a bug. Subscribing...
Comment #8
danepowell commentedIt's bizarre, I've compared this module line-by-line to the phone module (which does NOT repeat help text), and I cannot figure out what's different to account for the repeated text. I'm tempted to put a support request into the phone queue...
Comment #9
danepowell commentedDang, that was an easy fix- don't know how I missed it before: around line 224, change
'#description' => content_filter_xss($field['widget']['description']),to
'#description' => $element['#description'],I don't know if eliminating that content_filter_xss is a security issue or not- I don't think it should be, since an administrator is setting that description, and other modules don't use content_filter_xss here.
Comment #10
danepowell commentedpatch