Connect to an FTP Service with Yii
This is a generic class for interacting with an FTP service. It uses a constructor method to make the connection to the service. Although this particular example is based on the Yii Framework, the general concept applies to any PHP based framework.