Articles in category "how-tos", sorted by commentsX
Displaying 111-120 of 354 result(s).

"safe" and "unsafe" Model validators (massive assignments)

Created 3 years ago by Kostas Apazidis (KonApaz)How-tos4 comments – viewed 18,882 times – ( +4 / -6 ) – version 1.1
Ok, it is a little bit difficult to full understanding the unsafe validator.

Multiple Database Connection : Select database based on login user id, Dynamic

Created 3 years ago by Rajith RHow-tos4 comments – viewed 24,888 times – ( +9 / -6 ) – version 1.1
create a class file under protected\components named RActiveRecord.php

Visualization tree-multi subcategories as listbox or dropdownlist

Created 3 years ago by Kostas Apazidis (KonApaz)How-tos4 comments – viewed 14,425 times – ( +4 ) – version 1.1
Do you want to make a listbox or dropdownlist to select one or more categories or sub categories ?

Tarpit for bad bots

Created 4 years ago by mitherealHow-tos4 comments – viewed 6,715 times – ( +1 ) – version 1.1
I recently built a tarpit for bad bots.
tags: tarpit, bots

CGridView keep focus on the control after filtering

Created 4 years ago by jayalaHow-tos4 comments – viewed 10,131 times – ( +6 ) – version 1.1
You can find the reason why I wrote this article here.
tags: CGridView, filter

Simple Share Widget for Facebook, twitter and google+

Created 4 years ago by softarkHow-tos4 comments – viewed 22,140 times – ( +10 ) – version 1.1
This widget will show a Facebook "like" button and "comments" box together with "tweet" button and "google plusone" button on your page.

How to include Javascript, CSS

Created 3 years ago by InterboyHow-tos4 comments – viewed 373,260 times – ( +11 / -3 ) – version 1.1
There are many methods that we can include javascript, css into your Yii App. Today I will demonstrate three simple and helpul methods.

Simple Web APIs for your Yii App

Created 2 years ago by shivHow-tos4 comments – viewed 16,589 times – ( +2 / -2 ) – version 1.1
Its very common now-a-days to have Mobile app for web apps. For Mobile apps we need web APIs to fetch data or even post/update on web. We found a very simple method to make such interface. Mobile App can call plain get or post request and receive data back in JSON format. JSON is relatively easy for mobile app to handle while plain standard GET/POST request for easy for Web server to handle. This mixed approach saves lot of time on server side. We not really need to handle actual REST requests and still be able to exchange data between web and mobiles or ajax java-scripts or even node.js.
tags: API, JSON

Using standard filters in CGridView custom fields

Created 5 years ago by GOshaHow-tos4 comments – viewed 60,924 times – ( +17 ) – version 1.1
In this article I'll try to explain how to use standard quick search fields in CGridView with customized columns.For example: We have a record in a database with field switch having 0 or 1 values. After that we want a user to see on or off instead 1 or 0. So we do the usual thing:

Integrating Wordpress and Yii,Working Out The Details.

Created 4 years ago by drumaddictHow-tos4 comments – viewed 21,870 times – ( +8 ) – version 1.1
This article is based on fr0d0z's article Integrating Wordpress and Yii: still another approach, using Yii as the router/controller and provides more details on how to set up this integration.To be more specific,the idea is not to use any main.php layout in Yii's controllers.This gives the advantage that we do not need to modify any Yii code when we switch a theme in WordPress admin panel,provided we have done a very basic setup which I explain below.
tags: wordpress