Wiki articles

Showing 61-80 of 143 items.
Created 3 years ago by evercode, updated 3 years ago by evercode.

RBAC Super Simple with Admin and User

One of the common requests I see in the forum is how to implement RBAC. While you can implement Yii 2's built-in RBAC, that might be too much for developers who are just starting with Yii 2 or have simpler needs. Sometimes you are looking for a fast solution and just want two flavors, user and admin. And even if you will eventually need more, you can use these methods as a starting point for devel...

6 1
14 followers
Viewed: 67 600 times
Version: 2.0
Category: Tutorials
Created 3 years ago by Deepak Pradhan, updated 3 years ago by Deepak Pradhan.

Analyse the server's USER-AGENT against browsecap file to determine it's capability.

Does your application need to know user's details on browser details, os and device type? We can use PHP's misc. function to achieve that provided you have an update copy of browsercap.ini

0 0
0 follower
Viewed: 4 153 times
Version: 2.0
Category: Tips
Created 3 years ago by hrnair, updated 3 years ago by hrnair.

Yii2: Configuring different sessions for backend and frontend in Yii Advanced Application Template

This is as an extension of this wiki by Kartik V which shows to make different enableAutoLogin cookies for frontend and backend.

2 0
7 followers
Viewed: 28 362 times
Version: 2.0
Category: How-tos
Created 3 years ago by Scott_Huang, updated 3 years ago by Scott_Huang.

Easy way to redirect http:\\localhost\yii2-basic to http:\\localhost\yii2-basic\web\index.php

First of all, install yii2 basic template according below link:

1 0
5 followers
Viewed: 20 775 times
Version: 2.0
Category: Tips
Created 3 years ago by Scott_Huang, updated 3 years ago by Scott_Huang.

Step by step for how to full export Yii2 grid to excel

We will leverage Yii2-excelview widget. So, first of all is install Yii2-excelview:

0 0
5 followers
Viewed: 44 803 times
Version: 2.0
Category: Tips
Created 3 years ago by Misbahul D Munir, updated 3 years ago by Misbahul D Munir.

Simple Way to Upload and Save File

This tutorial need extension mdmsoft/yii2-upload-file. Follow the intruction to install. After installation done, create controller and action

0 0
4 followers
Viewed: 23 996 times
Version: 2.0
Category: Tutorials
0 0
5 followers
Viewed: 30 536 times
Version: 2.0
Category: How-tos
Created 3 years ago by Misbahul D Munir, updated 3 years ago by Misbahul D Munir.

Create Form With DynamicModel

In yii2 we can create form without create FormModel. Here we go

1 0
7 followers
Viewed: 23 338 times
Version: 2.0
Category: Tips
Tags: form, model, yii2
Created 3 years ago by Anas AbuDayah, updated 2 years ago by Cozumel.

How to use imagine ( crop, thumb, effects for images ) on Yii2

Imagine adds most common image functions and also acts as a wrapper to Imagine image manipulation library.

4 0
12 followers
Viewed: 62 245 times
Version: 2.0
Category: Tutorials
Created 3 years ago by Asmaa, updated 3 years ago by Asmaa.

How to display images in CJuiAutoComplete without extenstions

I wanted to customize the CJuiAutoComplete, so that it displays a thumb image before the label like the one shown in the following image:

0 0
1 follower
Viewed: 6 620 times
Version: all
Category: Tutorials
Created 3 years ago by raminious, updated 3 years ago by jim..

How to hide /frontend/web in url addresses on apache

There is an issue on Yii2 to redirecting / urls to /frontend/web.
In other words we need a way to hidden /frontend/web from addresses.
We will do this without changing Apache configuration and creating virtual host or setting document root (It's good for share hostings that we have not access to apache.conf)

6 0
18 followers
Viewed: 91 438 times
Version: 2.0
Category: How-tos
Created 3 years ago by edoardo849, updated 3 years ago by edoardo849.

MongoDB's RBAC support class extending BaseManager

Here's a possible implementation for MongoDb of the RBAC standard. Create a class "MongoDbManager" in `common\components and modify your params.php` file like this:

0 0
4 followers
Viewed: 8 146 times
Version: 2.0
Category: How-tos
Tags: mongodb, rbac, yii2
Created 3 years ago by yiqing95, updated 3 years ago by yiqing95.

embedded javascript block in your view with IDE checking or intellisense

this is my way for embed js code block in view file:

1 0
3 followers
Viewed: 6 639 times
Version: 2.0
Category: Tips
Created 3 years ago by Antonio Ramirez, updated 2 years ago by deacs.

How to implement form events

You have that, when a product is on development they can change its API anytime. This change is quite important though, its related on how to set the events of your form, for example, the useful beforeSubmit.

5 0
6 followers
Viewed: 21 449 times
Version: 2.0
Category: How-tos
Tags: Forms, How to, yii2
Created 3 years ago by sirin k, updated 11 months ago by Maurizio Domba Cerin.

Building a REST API in Yii2.0

This is wiki page is useful if you are trying to build a customized REST API in Yii2.0

3 0
16 followers
Viewed: 116 324 times
Version: 2.0
Category: Tutorials
Created 3 years ago by sirin k, updated 11 months ago by Maurizio Domba Cerin.

Write & use a custom Component in Yii2.0

This is a simple example in Yii2.0 to understand how you can write a custom component and use it inside your app.(basic template)

11 0
11 followers
Viewed: 83 432 times
Version: 2.0
Category: How-tos
Created 3 years ago by Dency G B, updated 3 years ago by Dency G B.

Role Management

Implementing a role based access control is a very easy process and you can even load your roles from the database if you want.

0 0
5 followers
Viewed: 13 271 times
Version: 2.0
Category: How-tos
Tags: rbac, yii2
Created 3 years ago by Ankit Modi, updated 3 years ago by Ankit Modi.

How to display Dependent drop-down value using ajax call with dynamically

Hi Friends, In this tutorial I write a code display dependent drop-down value using ajax call.

0 1
5 followers
Viewed: 35 887 times
Version: all
Category: Tutorials
Created 3 years ago by Ankit Modi, updated 3 years ago by Ankit Modi.

Manage Email Template content from database

Hi Friends,

0 1
2 followers
Viewed: 9 329 times
Version: all
Category: Tutorials
Created 3 years ago by Ankit Modi, updated 3 years ago by Ankit Modi.

How to show Image view after upload and delete view image using eajaxupload extension

Hi Friends, In this tutorial you can use the eajaxupload-extension ,

0 1
3 followers
Viewed: 13 768 times
Version: all
Category: How-tos