Wiki articles

Showing 41-60 of 148 items.

How to create/update a model with its related items using Listbox or CheckboxList

Created 4 years ago by softark, updated 2 years ago by softark.

Assume we have many categories and many posts.

4 0
6 followers
Viewed: 36 346 times
Version: 2.0
Category: Tutorials

Optimize Scenarios for yii2

Created 3 years ago by AndroideLP, updated 9 months ago by AndroideLP.

Working with scenarios, with models that can receive many modifications in their rules or structures as development evolves, can create disruptions in the rescue process.

4 0
2 followers
Viewed: 28 167 times
Version: 2.0
Category: Tutorials

Configuring different sessions for backend and frontend in Yii advanced app

Created 6 years ago by Kartik V, updated 4 years ago by Kartik V.

Your need: You require that for shared machines, the user is authenticated again for a backend access again, if someone is logged in from frontend and vice versa.

4 0
46 followers
Viewed: 39 509 times
Version: 2.0
Category: How-tos

Relational data fields display and edit with the yii2-detail-view extension

Created 6 years ago by Kartik V, updated 6 years ago by Kartik V.

If you have read this wiki you would be aware of the yii2-detail-view extension and how it offers you an easy way to EDIT and VIEW your model data, toggle these modes, and other features. You can [read the extension documentation](http://demos....

4 0
41 followers
Viewed: 54 382 times
Version: 2.0
Category: Tutorials

Building a REST API in Yii2.0

Created 5 years ago by sirin k, updated 3 years ago by Maurizio Domba Cerin.

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

4 0
16 followers
Viewed: 134 924 times
Version: 2.0
Category: Tutorials

Yii v2 snippet guide

Created 10 months ago by rackycz, updated 17 days ago by rackycz.

Please note, that this article will be updated regularly as I have more and more snippets so come back in a few weeks

4 0
3 followers
Viewed: 50 377 times
Version: 2.0
Category: Tutorials

Integrating ZF2 into Yii - use case demonstrated

Created 7 years ago by Boaz, updated 6 years ago by Boaz.

I needed to use a class from ZF2 in my Yii project. I've read probably all there is about this subject and still I needed lots of trial & errors to get it working, probably due to my lack of experience working with namepsaces and ZF2 in general. Also, the resources on the web are all partial, at best. Most simply refer to ZF1 where things are technically different. When I got it all working I de...

4 0
6 followers
Viewed: 10 918 times
Version: 2.0
Category: How-tos

UUID instead of an auto-increment integer for ID with Active Record

Created 8 months ago by grigori, updated 3 months ago by samdark.

I have an API. It's built with a RESTful extension over Active Record, and some endpoints provide PUT methods to upload files. By a REST design we create an entity with POST /video first, and then upload a video file with PUT /video/{id}/data.

4 0
3 followers
Viewed: 15 691 times
Version: 2.0
Category: How-tos

Using multiple models in an identity

Created a year ago by samdark, updated a year ago by samdark.

Let's assume we have two models: Customer and Supplier and we want both to log in. Yii is quite flexible when it comes to authentication and authorization so it's possible.

8 2
3 followers
Viewed: 24 373 times
Version: 2.0
Category: How-tos

RBAC Super Simple with Admin and User

Created 5 years ago by evercode, updated 5 years ago by evercode.

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: 85 265 times
Version: 2.0
Category: Tutorials

[Guide] How to actually separate Frontend (User) and Backend (Admin) on Yii2 Advanced

Created 5 years ago by Wade Shuler, updated 5 years ago by samdark.

I am writing this guide because I struggled to find a resource that included ALL of the necessary steps to completely separate the frontend from the backend. After reading guides like Configuring different sessions for backend and frontend in yii-advanced-app and [yii2 configuring d...

6 1
17 followers
Viewed: 91 404 times
Version: 2.0
Category: How-tos

Simple way to implement Dynamic Tabular Inputs

Created 5 years ago by ezekielnoob, updated a year ago by samdark.

grid

3 0
10 followers
Viewed: 33 312 times
Version: 2.0
Category: Tutorials

Simple revealing and hiding the password in the password field

Created 4 years ago by Bizley, updated 4 years ago by Bizley.

There are numerous usability problems:

3 0
4 followers
Viewed: 18 034 times
Version: 2.0
Category: How-tos

How to install Yii 2 advanced on a shared hosting environment

Created 4 years ago by oligalma, updated a year ago by oligalma.

I've read many comments that it's not possible to install Yii 2 advanced on a shared hosting environment, as it has two webroots. This is partially true.

3 0
2 followers
Viewed: 26 727 times
Version: 2.0
Category: How-tos

How to change GridView delete confirmation message for specific controllers only?

Created 4 years ago by AlaFalaki, updated 4 years ago by AlaFalaki.

Hello,
If you want to give extra attention for some specific delete actions and you don't want to override whole yii.confirm JS method here is what you can do:
(I've only put the ActionColumn part of the GridView here to just give you the idea)

3 0
4 followers
Viewed: 36 435 times
Version: 2.0
Category: Tips

Yii2 RESTful API with OAuth 2.0

Created 2 years ago by sirin k, updated a year ago by sirin k.

https://cdn.pbrd.co/images/GMN5ROs.jpg

3 0
3 followers
Viewed: 49 427 times
Version: 2.0
Category: Tutorials

MongoDb's embedded documents mapping for ActiveRecord in Yii2

Created 6 years ago by edoardo849, updated 6 years ago by CeBe.

suppose to have in Mongo a collection "user" like:

3 0
6 followers
Viewed: 21 279 times
Version: 2.0
Category: How-tos

Automatically get the SVN Revision Number of your Project

Created 6 years ago by jcagentzero, updated 6 years ago by jcagentzero.

When you are handling so many projects and those projects are saved in different repository locations, you may find it very difficult to keep track all the versions and revisions manually and it will be much harder if you are developing in multiple repository branches.

3 0
4 followers
Viewed: 9 230 times
Version: all
Category: Tutorials

How to implement cron in Yii 2

Created 6 years ago by hemc, updated 6 years ago by hemc.

In advance template there is already a file yii. And there is no need to run it as php, it is Linux script.

3 0
13 followers
Viewed: 81 009 times
Version: 2.0
Category: How-tos
Tags: console, cron, yii2

Yii2 and Pdf files with Mpdf

Created 6 years ago by CTala, updated 6 years ago by CTala.

I am still new to composer and packagist, so I want to share how I am creating the pdf files because for me was not as simple as it should be.

3 0
8 followers
Viewed: 23 762 times
Version: 2.0
Category: How-tos