Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I think the addition of "Contact xxxxxx" in the "Author Information" block would be really valuable. Certainly I would use it.
It's pretty darn simple thanks to the way the block was developed. Here's a patch.
Comment | File | Size | Author |
---|---|---|---|
#4 | profile_patch_0.txt | 1.02 KB | NancyDru |
profile_patch.txt | 1000 bytes | NancyDru |
Comments
Comment #1
NancyDruComment #2
NancyDruNothing in over 4 weeks?
Comment #3
drummFeatures such as this can only go into the current development version; nothing new will be added to Drupal 5.x.
This doesn't check with the contact module to see if the link makes sense. Contact module should really put the option and link there to keep related features in the same place.
Comment #4
NancyDruI created it with 5.1, but knew that it would have to go into 6 (unless there happens to be a 5.2 before that). But I don't have 6 to build it against. As simple as this patch is, I figured it could easily be brought forward.
I am adding a check for the contact module with this new version. I won't move this back to the profile module, but I do disagree that this is a contact change.
Comment #5
Gábor HojtsyThat could only work with t('Contact %username', array('%username' => $account->name)
Comment #6
NancyDruWhy would you want to translate the user's name? This code works for me exactly as it is.
Comment #7
NancyDruGuess I have to rewrite a patch for D6.
Comment #8
PanchoAnswering your question in #6: We always include variables into t()-translated strings. That's not because the variables would get translated, but because translators might want to change the variable's placement, as some languages need this here and there. Whether we need it here, is not the question - we do this generally and consistantly.
Concerning placement in profile or contact. I'd agree that this belongs in contact.module.
However, the blocks code seem to be one of the oldest parts of Drupal and is neither very flexible nor extensible. Someting like block_alter would be great! We can wrap the profile block in a bogus form, though, and then use contact_form_alter. Not so nice though.
I guess, we need some more input on this.
For now it's too late to get this into D6. I move it to D7, and would love to see it implemented there!
Comment #9
KarenS CreditAttribution: KarenS commentedSee #370620: Add 'Link to contact page' theme for a proposed theme that would create the link. Then you would just need to use the theme.
Comment #10
Dave ReidBumping to D8.
Comment #11
valthebaldCan this be marked as #370620: Add 'Link to contact page' theme duplicate?
Comment #12
andypost#11 not a duplicate, but another way to expose a link