Hide fields on the user profile page with preprocess function On the user profile edit page I can do something like this in my theme's template.php file to hide a field:

function MYTHEME_form_user_profile_form_alter(&amp;$form,$form_state,$form_id){
//remove unwanted fields from the form (default value is still saved)
  $form['timezone']['#access'] = FALSE;
}


On the profile view page, I am trying to do a similar thing. I want to hide: 

History
Member for 3 months 4 weeks


So I looked up the api function and it's hook_user_view

Based on this I try:

function MYTHEME_user_view($items) {
$items['member_for']['#access'] = FALSE;
}


... however, this does not work after I clear the cache. I'd also like to avoid hiding this using CSS display:none.
You do not need to use any preprocess functions tbh :> its pretty simple
Go to Home » Administration » Configuration » People » Account settings » Manage Display , History -> Format  chose hidden.