By dhroople on
Display block on every user profile page. The below code display block only for logged in user page but not on other user page. soloution needed please.
global $user;
if (arg(0) == 'user' && $user->uid == arg(1)){
return TRUE;
}
else {
return FALSE;
}
Comments
Try this.
What to write when..
Is there a way to show the module only on the user-indexsite?
Show it here http://sitename.tld/user/3
but not here http://sitename.tld/user/3/messages and on other subpages
And there is one problem more. Newer users have already a optimized url :
http://sitename.tld/users/gosu
There subpages are still :
http://site.tld/user/197/status e.g.
I hope somebody can help me because the friendsmodule is presented on every usersubpage :>
Edit : Oh. Wrong thread o.o I'm using drupal 6 :>
Edit 2 :
Works with :