Wiki

Sorted by ratingX
Displaying 61-70 of 687 result(s).

Understanding Scenarios

Created 2 years ago by Luke JurgsTutorials11 comments – viewed 74,472 times – ( +27 ) – version 1.1
Scenarios are an extremely useful tool for separating validation tasks on any class you use derived from CModel. In this tutorial we will use CActiveRecord.

How to add ajax-loading indicators

Created 4 years ago by schmunkTutorials5 comments – viewed 40,863 times – ( +27 ) – version 1.1
With yii you're able to create ajax requests and updates easily. But most times you always want to show a loading indicatior to your user.
tags: AJAX

How to use a Widget as an Action Provider

Created 3 years ago by Antonio RamirezHow-tos14 comments – viewed 30,192 times – ( +27 ) – version 1.1
As written on the API docs: An Action Provider Widget is a widget that has declared several actions by using its 'public static function actions()'. After, a Controller can easily import all its declared actions on its 'public function actions()'.
tags: Widgets, CAction

How to use an application behavior to maintain runtime configuration

Created 3 years ago by zaccariaHow-tos3 comments – viewed 23,333 times – ( +27 ) – version 1.1
In this tutorial will be explained a method to manage some configuration runtime. This excellent tutorial follows a similar approach, but requires to write a masterclass which all controllers are supposed to extend, following this wiki you can achieve the same by only editing the configuration.

How to add more information to Yii::app()->user

Created 5 years ago by qiangTutorials1 comment – viewed 114,981 times – ( +26 ) – version 1.1
By default, the expression Yii::app()->user returns a CWebUser application component which represents the information that are closely related with the current user. Some information can be persistent throughout the current user session. For example, CWebUser already comes with a name property that stores the username of the current user.

Saving CGridView filter

Created 6 months ago by sefburhanTutorials4 comments – viewed 3,308 times – ( +26 ) – version 1.1
In this tutorial we will try to save cgridview filter(search) with title etc. basically we want to save two forms data i.e one represents filters and other data about filters like title, description etc. You can define your own structure for filter saving table here are some basic steps

X-Sendfile - serve large static files efficiently from web applications

Created 3 years ago by Maurizio Domba CerinHow-tos5 comments – viewed 38,878 times – ( +26 ) – version 1.1
Normally when we want users to download a file, that file is put in a folder under the web application root and the web server does the rest.

An easy way to display a success page using flash messages

Created 3 years ago by qiangTips2 comments – viewed 23,795 times – ( +26 ) – 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.

Configuring different sessions for backend and frontend in Yii advanced app

Created 3 months ago by Kartik VHow-tos0 comments – viewed 2,039 times – ( +26 ) – version 2.0
After you have setup your Yii2 advanced application, you now have setup your user authentication for both frontend and backend. However, if you have first logged into frontend, and try to access backend from the same client machine, you see no login screen, but find yourself automatically logged in.

Key web server settings after installing a fresh Yii 2 basic or advanced app

Created 3 months ago by Kartik VTips0 comments – viewed 1,596 times – ( +26 ) – version 2.0
So, you have installed a brand new Yii 2 app (basic) or (advanced). Here are a few tips for Apache web server users to get things running more secure and better with your yii2 app.