Wiki

Articles in category "tips", sorted by viewsX
Displaying 51-60 of 135 result(s).

Extending CActiveForm for some form display fixes and language tweaks

Created 3 years ago by TrejderTips0 comments – viewed 12,420 times – ( +5 ) – version 1.1
In this simple example I'll demonstrate how to extend CActiveForm class to overload some drawing functions to achieve some commonly used fixes in forms.

A simple class to use a different db for a module

Created 3 years ago by tydeas_drTips2 comments – viewed 12,254 times – ( +9 ) – version 1.1
What would you do if you want/need to have a different than the main database connection in an module's models?

Auto TDD - How to auto-run PHPUnit

Created 3 years ago by imeheszTips3 comments – viewed 12,132 times – ( +3 / -1 ) – version 1.1
If you are lucky enough and have the privilege to develop on a Linux based environment, this little tip might boost-up your TDD process (at least the Unit Testing part). Please note, that this should work just fine with Apple computers also, but not tested!
tags: PHPUnit, testing, TDD

BootProgressColumn - Progress Bar Inside GridView Column compatible with 'bootstrap' extension

Created 2 years ago by LuizTips1 comment – viewed 11,758 times – ( +7 ) – version 1.1
A little hint of how to create a progress bar inside the column of the grid, using the 'bootstrap' extension.

Using MBMenu and Rights to automatically create menu item for your modules

Created 3 years ago by dinhtrungTips2 comments – viewed 11,428 times – ( +1 / -1 ) – version 1.1
Using Rights generator component, we can easily create a dynamic menu, in which we scan every modules' controllers, to access the index page of them.

Rendering Views and Updating them with Ajax

Created 8 months ago by Manish GuptaTips4 comments – viewed 11,384 times – ( +2 )
I wanted to implement a widget that could refresh itself through Ajax without refreshing the whole page. CGridView and CListView are excellent examples of such widgets.

adding class and links to Ctreeview node

Created 3 years ago by bingjie2680Tips2 comments – viewed 11,359 times – ( +4 ) – version 1.1
This article will show you how to add links and class to each node in ctreeview. so you can attach events in js by obtaining handler on anchor or class.
tags: ctreeview, link, class

Using events with CAction classes

Created 2 years ago by Antonio RamirezTips0 comments – viewed 10,561 times – ( +9 ) – version 1.1
There are some good guides out there explaining how to work with events and the ways to attach them to your components, but none (that I know) explain the following way to configure your events with CAction classes on your controllers the following way.

How to ensure unicity to url

Created 2 years ago by zaccariaTips3 comments – viewed 10,334 times – ( +14 ) – version 1.1
Many time for SEO porpouses is important that each page will have a unique address.
tags: SEO, unique, URL

URL component access functions

Created 3 years ago by Steve FriedlTips1 comment – viewed 10,259 times – ( +28 ) – version 1.1
Many applications wish to obtain parts of the URL for the current page (the hostname, the query string, etc.), and the CHttpRequest class wraps various $_SERVER variables to break down the URL into its constituent parts.
tags: URL, request