If I have only chosen to a single messaging transport (eg Simple Mail or PHPMailer), It would be nice if the "Default send method:" (found in your user account setting) select box were hidden. There's no reason (IMO) to give a user a option that only has one option, as it will just adds noise and confusion :)
I was planning on submitting a similar request over in the messaging queue, but I wanted to wait to get you feedback here first.
Just a request, but thanks for all your hard work on this module.
| Comment | File | Size | Author |
|---|---|---|---|
| #11 | messaging-hide-user-form-if-only-one-method.diff | 1.04 KB | landry |
| #1 | messaging.module.250161.patch | 2.22 KB | jaydub |
| #1 | notifications.admin_.inc_.250161.patch | 1.35 KB | jaydub |
| #1 | notifications.module.250161.patch | 1.33 KB | jaydub |
Comments
Comment #1
jaydub commentedYes I do think that there's room for improvement here.
I've attached patches for messaging and notifications
to address this in the module settings pages and in
the user edit pages.
I know Jose is porting to Drupal 6 at this time so I'll
post the patches here to be assessed rather than
just commit.
Comment #2
jose reyero commentedThe patches look good. However I think it was asking for a bigger remake so that's what I did.
Merged messaging and notifications 'default_send_method' setting, it should show up disabled when there's only one. Also fixed some related issues, strenghtened permissions (aditional checking in case perms have changed), etc...
This is to be ported to D6. There may be room for more improvements though (Like actually removing the send method down for subscription forms)
Comment #3
jose reyero commentedDone for D6
Comment #4
plan9 commented@Jose, do you have this patch for D5?
Comment #5
amogiz commentedHi. I am a user of this great D6 module but still have the send box method down for subscription forms.
How could i hide it ?
Thanx
Comment #6
amogiz commentedExcuse me i did not fill correctly the form and did not re-open the Post so i do it again.
Hi. I am a user of this great D6 module but still have the send box method down for subscription forms.
How could i hide it ?
Thanx
Comment #7
jdln commentedSubscribing.
Comment #8
Soldierka commentedI can't find this option neither.... Any help please?
Comment #9
jdln commentedIf there was a div with a unique name around these options so I could hide it with CSS, that would be fine for me. Is there a simple patch / theming method to achieve this?
Thanks
Comment #10
juc1 commentedsame problem here
Comment #11
landry commentedI think what people want is no form at all if there is only one method available. Atm, the form is here, but with a disabled select box.
A 'better' fix would be removing '#disabled' in messaging.module:messaging_user() line 138, and instead amend the if to be :
if ($category == 'account' && ($list = messaging_method_list($user)) && count($list) > 1)
Attached patch works for me.