Wiki

Sorted by commentsX
Displaying 451-460 of 785 result(s).

Create custom button button with AJAX function in CGridView

Created 4 years ago by nkdHow-tos2 comments – viewed 54,515 times – ( +19 / -1 ) – version 1.1
CButtonColumn in CGridView can be customised to include user built buttons. To learn a great deal about including custom buttons, read this excellent wiki. This tutorial will show how to call an action from one custom button using AJAX instead of regular GET calls.

Localized version of CFormatter

Created 4 years ago by marcovtwoutHow-tos2 comments – viewed 5,513 times – ( +3 / -1 ) – version 1.1
Since Yii 1.1.14, a CLocalizedFormatter is available.

Yii 2 list of path aliases available with default basic and advanced app.

Created 3 years ago by Kartik VTips2 comments – viewed 90,770 times – ( +53 / -6 ) – version 2.0
If you are coming over from Yii 1.x to Yii 2, and already read this guide, you may note that namespaces are very important in Yii 2 to identify classes. But do you know the list of seeded path aliases that come shipped with a basic or advanced app? Here is my attempt to list them.

FORM with GET method causes repeated stacking of URL Parameters

Created 3 years ago by Kartik VTips2 comments – viewed 27,125 times – ( +45 / -5 ) – version all
You are using an ActiveForm in yii (both v1.x or 2), with a GET method like below:

How to use Smarty renderer in Yii

Created 6 years ago by dongbetaHow-tos2 comments – viewed 19,746 times – ( +4 / -1 ) – version 1.1
At first, create a class named SmartyRenderer under application/components or any directory you want.
tags: smarty, renderer

CGridView and AjaxForm Connect

Created 6 years ago by PinkBrainPlanHow-tos2 comments – viewed 21,442 times – ( +1 / -1 ) – version 1.1
As I'm new to the framework (2 weeks) - I tried to build a functionallity I already use a lot in my old framework (PRADO). This means combining a GridView with a form. And this in one page, what allows you to select a record from the grid and view the values in the same page without jumping to a new page.
tags: Ajax, Form, CGridView

Multilanguage Lorem Ipsum Text Generator

Created 4 years ago by yasenHow-tos2 comments – viewed 7,473 times – ( +2 / -1 ) – version 1.1
Taking futher the idea from Piotr Masełkowski - http://www.yiiframework.com/extension/elipsum/ here's how to generate multilanguage Lorem Ipsum text. This example uses English and Bulgarian sample paragraphs. Create a class in /protected/components/LoremIpsum.php. Wall of text incoming wohoo...

To configure Yii path in Windows platform

Created 6 years ago by CodaTutorials2 comments – viewed 40,482 times – ( +3 / -7 ) – version 1.1
I can see many questions regarding configuring the path using Windows OS. I could hardly get the right information about it. The cook book has defined for Linux. So I would like to share my idea on it. To configure the Yii path using Windows OS,

An easy way to display a success page using flash messages

Created 6 years ago by qiangTips2 comments – viewed 40,291 times – ( +28 / -1 ) – version 1.1
We often need to display a success page after the user has submitted a form without problem. We may show some welcome message after a user registers a new account. There are many ways to implement this workflow. In this article, I will explain a method that exploits flash messages.