Sorry, I am not sure how to get this into the documentation, but it has been asked more than once here.

Here is the code free way to get your default "submitted by USERNAME" on nodes to link to your custom profile 2 page instead of the default user account. Because really, why set up custom profiles if other users cannot find them easily?

  1. Download, and installed https://drupal.org/project/submitted_by to override submitted by
  2. Navigate to the content type you want to change
  3. Choose the specific build you want to influence (ie, full node, or teaser).
  4. Use tokens (or even custom tokens)
  5. Try something like : Submitted by: <a href="[current-user:profile-public-profile:url]">[current-user:field_real_name]</a>

Note: Two things in my example. First is I called my profile 2 type "Public Profile". Second, is I am used the field "real name" for the name, instead of the username. You can also integrate this with: https://drupal.org/project/realname

Thank you to the creator of this module.

Comments

mach5_kel’s picture

Issue summary: View changes

cleaned up formatting

mach5_kel’s picture

*

joco_sp’s picture

This is working with content typs, but how to make it work with Entyties?

joco_sp’s picture

Issue summary: View changes

more formatting, jesh

mineobile’s picture

I have added the module and tokens and have gone in and replaced the byline text to what you supplied above. I also changed the tokens to the ones for my website but nothing is changing. I've also tried clearing my cache. Any info on why this is not working?

mach5_kel’s picture

Issue summary: View changes

Are you sure the submitted by module is working? Try entering some plain text into it to see. If it is working, then make sure that you are using the correct tokens. If you think it is the correct tokens, then make sure that that user actually has a profile created. I found that my links didnt work until there was actually some content in the profile. I hope that helps. If you find a solution, please post it here to help others.