Hi....first thanx for the great module!

I want to ask if there is way when u click on user nickname ... to lead to the user profile not to quote his/her post?

Thanx in advance

Comments

naheemsays’s picture

Just something to add to this... would there be a replacement for the "click names to quote"?

Additionally, how about adding "clickability" to not logged in users too?

(in short, this is now an either /or issue/request. either make the logged in user names go to profile, or both logged in and not logged in should go to quote...)

brzbg’s picture

Hmmm still no solution :(

SeeSchloss’s picture

Sorry, I thought I had answered this one... so, there's no option for that, and I haven't had a good idea yet for allowing that without overriding theme functions (as I want clicks on usernames to insert "username<" in the textfield, at least by default).

If you're okay with theme overrides, you could override the "theme_post_username" function, its current code is :

function theme_post_username($post) {
  if (strlen ($post['login']) > 0) {
    $contents  = "<span class='tribune-login' title='". htmlspecialchars($post['info'], ENT_QUOTES) ."'>";
    $contents .= $post['login'];
    $contents .= "</span>\n";
  }
  else {
    $contents  = "<span class='tribune-info' title='". htmlspecialchars($post['info'], ENT_QUOTES) ."'>";
    $contents .= $post['info_small'];
    $contents .= '</span> ';
  }

  return $contents;
}

you could replace it with, for example :

function theme_post_username($post) {
  if (strlen ($post['login']) > 0) {
    $user = user_load($post['uid']);                           // load the user object from the post author's uid
    $contents  = "<span class='tribune-login' title='". htmlspecialchars($post['info'], ENT_QUOTES) ."'>";
    $contents .= theme("username", $user);                     // theme_username($user) displays a link to an user's profile
    $contents .= "</span>\n";
  }
  else {
    $contents  = "<span class='tribune-info' title='". htmlspecialchars($post['info'], ENT_QUOTES) ."'>";
    $contents .= $post['info_small'];
    $contents .= '</span> ';
  }

  return $contents;
}

Well... if you really insist, I might just make it the default behaviour :)

brzbg’s picture

REALLY THANKS Mate .... now i just need to find where is the code to change user name color :]

SeeSchloss’s picture

To change colours you should have your own stylesheet somewhere (in your theme for example) and apply styles to span.tribune-login, span.tribune-info, etc.

SeeSchloss’s picture

Assigned: Unassigned » SeeSchloss
Status: Active » Fixed

Well somehow I had forgotten about this issue... I just made anonymous users clickable (in CVS) like they should always have been.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.