In this wiki I will show how could wo pass the third parameter to UserIdentity on login authenticate. So we can do separate login authentcation from two or more different models from single login form.
In this wiki I will show how could wo pass the third parameter to UserIdentity on login authenticate. So we can do separate login authentcation from two or more different models from single login form.
I build this simple PHP class (DialogBox.php at the bottom of this wiki) to help you in the dialog box usage on Yii applications. The goal is run any Yii actions into this dialog box and return the resulting value to the calling instance.
Here's a tutorial on how to create a CGridView with external date filters the trick is to create hidden columns within the CGridView Filters something like in the example below:
what i am going to introduce is a coding style that will result into a single page generated from different requests like in the example below this makes the specific request reusable instead of just an action being accessible to the controller in which the widgets are created
Original source code and idea are from: PHP, PDO & Nested Transactions.
This wiki is to show you how to use jQuery get and JSON to get data from a dropdown/any form field and fill form fields with the values instantaneously. First, I'll give example use cases of what I'm going to teach you so you can quickly see if this is for you.
CJuiDatePicker displays a datepicker. CJuiDatePicker encapsulates the JUI datepicker plugin.
There are two ways to run a cron job:
I did not invent this instructions, I read it somewhere and re-organized in my way as I was trying and it works for me;
The Problem: Yii2 utilizes by default UserIdentity configured in config/web.php for connection, this object apply one table to authentication ('identityClass' => 'app\panel\models\User'). How to authentication from diferent tables? Solution: Create instances in web.php to uses UserIdentify. eg:
In this short how-to I will show how to customize setFlash() to display messages (flashes) styled to be success confirmation, error report or notice information. And how to achieve displaying errors in other way.
With the adoption of PJax on Yii2 things have change quite a bit with GridView when it comes to work with them in AJAX mode. It will probably be confusing at the beginning, but then you will soon realize how powerful the new approach is.
In this article, we introduce an approach that allows automatic hyphenation of the route part in URLs.
I was looking around wiki and found that was no approach as the one I did so I guessed this is worth to write.
Whatever reason, it turns out to be easy enough to add that feature to your application. :)
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.
This How-To is useful if you are planning to move the Yii vendor directory outside the default location.
If you like the things to be short and clear, then you can skip right to a short summary of instructions at the end of this article.