background preloader

Yii

Facebook Twitter

Drumaddict/YiiApp. Urmaul/cleanapp. YiiApp - A starter project template for Yii built with Html5 Boilerplate,Bootstrap,ΥiiBooster and BootSwatch. Yii Framework | Tariff Street Ltd. A site I’m currently building requires a bunch of Cron jobs running daily to bring in and update various bits of data. It’s the first time I’ve needed to do this within the Yii framework, and it was a useful experience figuring out how it works. The Yii documentation located at isn’t completely clear, so hopefully this post will help. Firstly, forget about browser emulation, the best way to implement Cron jobs in Yii is by using Yii’s Console Application (CConsoleCommand) functions. Essentially this is a separate instance of your application that can be run from the command line rather than as a publicly executable php script. The first thing to do is to create a new entry or index script – which looks a lot like the index.php file in your public_html or root directory.

I called my script cron.php and dropped it on to the server below public_html. // change the following paths if necessary$yii=dirname(__FILE__).'

Yii - Tutorial

Yii - Form. Yii - Structure. Yii -AJAX. Yii - jQuery. Yii - Debug. Yii - ClientScript. YII - social. Yii Tutorial. By Anatoliy Dimitrov Yii is a modern and robust PHP framework aimed to secure and scalable programming. It is not hardern or more complex compared to the popular PHP frameworks such as CakePHP. It supports all major databases from MySQL to Sqlite. The best is that it is much faster and scalable compared to other frameworks. The latter is what made me reconsider using it over CakePHP. SEO and Clean URLs By default Yii routes all URL requests transparently through the main index.php file and your URLs look like this: Our aim is to make it look: For this purpose follow these steps: Open your site root protected/config/main.php and uncomment the part about the urlManager so that it looks like this: 'urlManager'=>array( 'urlFormat'=>'path', 'showScriptName'=> false, 'rules'=>array( ' Add the following lines to your .htaccess (provided you are using Apache or compatible web server): RewriteEngine on RewriteCond %{REQUEST_FILENAME} !

Best approach for backend-frontend development in YII. Andy_s, on 07 January 2012 - 05:30 AM, said: There is no the best approach. Also there is a 4th option: admin module. Which approach to use depends on: are you developing an application alone or in a team;how big is the application;do you want to have fully separate backend/frontend or not (with different url types, login systems, etc.) ;will you need to move backend to another server;your personal taste of course I used it successfully in several small projects (frontend and backend are separated). Hope it helps Andy, 4th Option: admin module.

Yii - Database