You can download YII from below url:
http://www.yiiframework.com/download/
After Download you may want to verify that your server satisfies Yii's requirements. You can do so by accessing the requirement checker script via the following URL in a Web browser:
http://hostname/path/to/yii/requirements/index.php
rest described here!!