Wiki

Articles in category "how-tos", sorted by viewsX
Displaying 151-160 of 183 result(s).

How to Setting Layouts in Yii

Created 14 days ago by ruderbytesHow-tos2 comments – viewed 3,813 times – ( +2 / -3 )
usually someone confused to make layouts in yii.

Tarpit for bad bots

Created about a year ago by mitherealHow-tos4 comments – viewed 3,806 times – ( +1 )
I recently built a tarpit for bad bots.
tags: tarpit, bots

Extending an ActiveRecord model

Created 3 months ago by BogseyHow-tos3 comments – viewed 3,717 times – ( +2 / -3 )
Introduction

Publish yii webapp using Git push

Created 10 months ago by rootbearHow-tos6 comments – viewed 3,635 times – ( +2 )
I did not invent this instructions, I read it somewhere and re-organized in my way as I was trying and it works for me;
tags: git

Handling recursive deletion in Yii

Created 5 months ago by JamesBarnsleyHow-tos3 comments – viewed 3,432 times – ( +3 )
As a lead developer at Mutable Labs I was tasked to find a way to do recursive deletion in Yii. As I asked other developers and looked around the internet the usual answers all came up, use a plugin or use cascade delete at the DB level, but I did not want to do either of these.

Serial Numbers (item counts) in GridView

Created 7 months ago by PeRoChAkHow-tos2 comments – viewed 3,387 times – ( +1 )
Sometime we need to display numbers of items per page with their counting as a serial number.

Using phpseclib with Yii

Created 7 months ago by nkdHow-tos6 comments – viewed 3,368 times – ( +2 )
I installed phpseclib because I needed to do some AES encryption in my project. After all the hassle of installing php lib, I found out that Yii already has a security module (securityManager). I finally decided to keep using phpseclib because it has one big advantage over Yii securityManager module, it does not requite mcrypt to be installed in the phpserver!
tags: security

How to "masquerade" a non-required form element as 'required' one (in the view only)

Created 8 months ago by BoazHow-tos2 comments – viewed 3,325 times – ( +5 / -1 )
In a nutshell, the task at hand is to mark (or render) a model attribute in the typical "_form.php" view file with the 'required' red asterisk while this attribute is not marked as required in the model's rule() method. If you're interested only in the solution, jump ahead to the 'solution' section below.

Using Grunt for deploying client scripts

Created 2 months ago by Chris83How-tos8 comments – viewed 3,282 times – ( +5 )
For a long time I have struggled to find a suitable tool for doing server tasks such as compiling LESS files, concatenating and minifying of JavaScript files and copying the minified JavaScript files. While most of these tasks can be done with Yii extensions I would still not recommend using them because it requires you to include these extensions in your project, and therefore also deploying them in your production environment.