Most cellphones can be connected to a computer by cable or Wi-Fi, depending on the phone. If using a Windows computer, drivers must be downloaded and installed for the computer to recognize the phone. If using a Mac, drivers are not required, and plugging in the phone suffices.
To connect a phone by cable, plug the smaller end into the phone and the larger end into an available USB port. Follow the on-screen instructions for the installation of drivers, if using Windows, or visit the phone manufacturer's site to download them. An iPhone needs to be synced to iTunes. Instructions are available on Apple's support site.