This is only activating the hat locally or an all clients or no clients.

I made this code to try to get my character customization form my silly little multiplayer game, but this does not activate the hat if the other client has their hat set to on. ignore the monical and parrot.

using UnityEngine;
using System.Collections;
using System.Collections.Generic;

public class CosAct : MonoBehaviour {
	public PhotonView photonView;
	public int hatTrue = 0;
	//public int monicalTrue = 0;
	//public int parrotTrue = 0;

	void Update(){
		photonView = this.transform.GetComponent<PhotonView> ();
		hatTrue = PlayerPrefs.GetInt ("Hat");
		//monicalTrue = PlayerPrefs.GetInt("Monical");
		//parrotTrue = PlayerPrefs.GetInt("Parrot");
	if(hatTrue == 1){
			Debug.Log ("set hat on");
			ActHat();
		}else{
			return;
		}
	//if(monicalTrue == 0){
	//	ActMonical();
	//	}else{
	//		return;
	//	}
	//if(parrotTrue == 0){
	//	ActParrot();
	//	}else{
	//		return;
	//	}
	}
	void localhatlayer(){
		if(photonView.isMine){
			this.transform.FindChild ("Hat").FindChild("botcy").gameObject.layer = 11;
			this.transform.FindChild ("Hat").FindChild("topcy").gameObject.layer = 11;
		}
	}
	[PunRPC]
	void ActHat(){
		transform.FindChild("Hat").gameObject.SetActive(true);
		localhatlayer ();
    }
	void ActMonical(){
		transform.FindChild("Monical").gameObject.SetActive(true);
	}
	void ActParrot(){
		transform.FindChild("Parrot").gameObject.SetActive(true);
	}
}

Thanks for the reply.
I am changing the hat playerpref on another screen.
I know how to change the hat localy.
I dont really know what you mean by tell others somehow that you changed your hat because if i knew how to do that i wouldnt really be asking the question. But ty anyway if you could give a bit of sample code that would be great!