Proteins that pass through the entirety of the phospholipid bilayer of the cellular membrane are called transmembrane or integral proteins. There are many things to talk about these kinds of protein (e.g. their different functions, variations, etc) but one fundamental information about them is that a majority of them, if not all, have hydrophobic centers with hydrophilic ends. You have to remember that they go across the phospholipid bilayer and the inside of this layer is majorly fat or lipids and the extracellular and intracellular surface of this layer is made up of phosphate groups, which are very polar substance. The transmembrane proteins have to blend well with the polarity of these environments.
Peripheral proteins on the other hand are only found on one surface of the phospholipid bilayer: either facing the extracellular or intracellular sides.