Wiki

Sorted by viewsX
Displaying 421-430 of 786 result(s).

Radio Button List with enum values for column of type ENUM >+> incorporate into giix

Created 5 years ago by pckabeerHow-tos1 comment – viewed 18,810 times – ( +7 / -1 ) – version 1.1
Let's say our table 'mug' has a column named 'color' of the type ENUM('red','green','blue'). We want to replace the textfield for the attribute color in the create and update forms of a 'mug' with a Radio Button List, which has the enum values as options. This is a rewrite of c@cba in the wiki article of enumDropdownListThe main code was contributed by zaccaria in the forum (see this post).

[Updated] How to create & call custom global function in whole application?

Created 3 years ago by Rohit SutharTutorials8 comments – viewed 18,803 times – ( +5 / -3 ) – version 1.1
In this wiki I will show how to create own custom global function. It may be save the space and reduce the time.

Yii2 default values for Index data Provider

Created 3 years ago by CTalaTips3 comments – viewed 18,786 times – ( +4 / -1 ) – version 2.0
Guys,

Use CGridview to sort and filter CSqlDataProvider - when used with UNRELATED tables (or complex queries)

Created 3 years ago by Gerhard LiebenbergHow-tos6 comments – viewed 18,687 times – ( -1 ) – version 1.1
I have two tables called hospitals and departments. I have a junction table between them which holds the departments in each hospital. But sometimes I need a list of "All hospitals with All possible departments" - regardless of whether they are linked in the junction table or not.

Using Grunt for deploying client scripts

Created 4 years ago by Chris83How-tos8 comments – viewed 18,452 times – ( +11 / -1 ) – version 1.1
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.

Create a custom menu using CMenu data-items (flat or tree structure)

Created 4 years ago by Kostas Apazidis (KonApaz)How-tos0 comments – viewed 18,448 times – ( +4 / -1 ) – version 1.1
There are cases that you want more control to your menu Suppose you want a specific menu with complex css, layout, images. also you want to add extra content,html,css,javascript etc it run time foreach submenu item by conditions.

Install specific Yii2 vendor extension & dependency without updating other packages.

Created 3 years ago by Kartik VTips0 comments – viewed 18,447 times – ( +40 / -7 ) – version 2.0
The tips here are for advanced usages of composer and its assumed you have read about using composer and have a knowledge of your vendor packages to be updated. Let's consider, you want to update only one specific yii2 vendor library, without updating all the other extension packages?

Code style

Created 7 years ago by zaccariaTips2 comments – viewed 18,333 times – ( +30 / -1 ) – version 1.1
Often, when writing widgets or editing Yii code, it is unclear whether or not the code is following the MVC pattern.
tags: mvc

Extending an ActiveRecord model

Created 4 years ago by BogseyHow-tos3 comments – viewed 18,262 times – ( +2 / -4 ) – version 1.1
Introduction

CSV Export

Created 5 years ago by JohnPollardHow-tos5 comments – viewed 18,261 times – ( +4 / -1 ) – version 1.1
I needed a csv export function for my cgridview and I wanted to export the entire result set of the sorted and filtered cgridview the user was viewing via ajax.
tags: csv, export