It's the right socket. You will need to consult with Gateway or refer to the support page for your laptop model to determine whether the CPU will work or not (sometimes it is restricted by BIOS).
To replace the CPU, you will need to open the laptop and remove the heat sink (and possibly more, depending on the design). You can then access the CPU. Make sure you unmount it before trying to pull it out, if need be; CPU sockets often require that you use a flat head screwdriver or a torque screwdriver on the socket to unmount the processor.