Wiki articles

Showing 41-60 of 142 items.

Use kartik Growl with Yii2 flash messages

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

This is to show you how to use Yii2 flash messages with Kartik Growl (bootstrap notify wrapper).

6 0
10 followers
Viewed: 37 925 times
Version: 2.0
Category: How-tos

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

Created 4 years ago by Wade Shuler, updated 4 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...

4 1
16 followers
Viewed: 78 427 times
Version: 2.0
Category: How-tos

Remove Byte Order Mark (BOM) from files recursively

Created 5 years ago by Kostas Apazidis (KonApaz), updated 5 months ago by samdark.

The problem was that all my web applications ran normally on localhost, but on server the Greek characters (or any other no-english characters) displayed with problems.

2 1
7 followers
Viewed: 23 929 times
Version: all
Category: How-tos

Yii2: How to create/develop a new extension using Composer locally without version control or Git

Created 2 years ago by Wade Shuler, updated 3 months ago by jwerner.

Using a version control system, like Git, is nice. However, when building an extension from scratch and loading it via Composer, it adds a lot of pain in the butt steps. You have to commit your changes, update composer to pull them over, then notice there is an error, fix, commit, update. repeat.. I don't want all my baby steps under Git. Sure, I could edit my commit history, but c'mon. Just let m...

6 0
5 followers
Viewed: 20 007 times
Version: 2.0
Category: How-tos

Yii2 GridView Sorting and Searching with a Junction Table Column(Many to Many Relationship)

Created 2 years ago by Amjad Khan, updated 2 years ago by Amjad Khan.

Following is the table structure

tblgroups

CREATE TABLE IF NOT EXISTS `tblgroups` (
  `id` int(11) NOT NULL,
  `groupname` varchar(150) NOT NULL,
  `status` tinyint(1) NOT NULL DEFAULT '1' COMMENT '1=Acitve,2=Inactive',
  `date` datetime NOT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

tblcontacts

2 0
6 followers
Viewed: 51 074 times
Version: 2.0
Category: Tutorials
10 0
15 followers
Viewed: 33 719 times
Version: all
Category: Others

How to login from different tables in Yii2

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

The Problem: Yii2 utilizes by default UserIdentity configured in config/web.php for connection, this object appy one table to authentication ('identityClass' => 'app\painel\models\User'). How to authentication from diferent tables? Solution: Create instances in web.php to uses UserIdentify. eg:

5 0
5 followers
Viewed: 21 014 times
Version: 2.0
Category: How-tos

Upload files in Yii2 with MongoDb and GridFs

Created 5 years ago by edoardo849, updated 4 years ago by skworden.

Uploading files in a webapp can be extremely tricky and sometimes the quickest way to do it is to store the file directly in the webserver or into a DNS (like Amazon S3) and then to save the link and the metadata inside a table in the DB. The thing is that you'll have to deal with file permissions, server storage, file management and so on (which is perfectly fine, by the way).

6 0
5 followers
Viewed: 23 289 times
Version: 2.0
Category: How-tos

How to send emails using SMTP

Created 5 years ago by robregonm, updated 3 months ago by Wade Shuler.
5 0
10 followers
Viewed: 90 693 times
Version: 2.0
Category: How-tos

Yii2 default values for Index data Provider

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

Guys,

1 0
5 followers
Viewed: 24 662 times
Version: 2.0
Category: Tips

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

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

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.

10 3
47 followers
Viewed: 134 493 times
Version: 2.0
Category: Tips

FORM with GET method causes repeated stacking of URL Parameters

Created 5 years ago by Kartik V, updated 5 years ago by toph.

// In Yii 1.x $form = $this->beginWidget('CActiveForm', [

'id' => 'order-search-form',
'method' => 'get',

]); echo $form->textInput($searchModel, 'id'); echo CHtml::submitButton('Find', ['class' => 'btn btn-primary']); $this->endWidget(); `

5 2
40 followers
Viewed: 43 803 times
Version: all
Category: Tips

Displaying uploaded file from DB for update with FileInput widget

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

This is for folks who are using \kartik\widgets\FileInput to upload files from your client. How do you display an image for update after you have uploaded it to the server using the widget?

1 3
42 followers
Viewed: 46 463 times
Version: 2.0
Category: How-tos

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

Created 4 years ago by Anas AbuDayah, updated 3 years ago by Cozumel.

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

5 0
13 followers
Viewed: 73 479 times
Version: 2.0
Category: Tutorials

Moving the vendor directory for multiple projects

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

This How-To is useful if you are planning to move the Yii vendor directory outside the default location.

4 0
4 followers
Viewed: 20 440 times
Version: 2.0
Category: How-tos
2 0
3 followers
Viewed: 21 940 times
Version: 2.0
Category: How-tos

Before Query Example : Soft Delete

Created 4 years ago by moo.tensai, updated 4 years ago by moo.tensai.

This is how i do before query on Yii 2.0

0 0
3 followers
Viewed: 13 337 times
Version: 2.0
Category: How-tos

Simple revealing and hiding the password in the password field

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

There are numerous usability problems:

2 0
4 followers
Viewed: 14 710 times
Version: 2.0
Category: How-tos

Execute migration on server/linux using shell

Created 3 years ago by darioo, updated 3 years ago by darioo.

It's easy to execute migration locally on XAMPP using cmd, but on server where you script is it's little bit harder.

0 0
3 followers
Viewed: 11 606 times
Version: 2.0
Category: How-tos

Automatic Parameter Binding to POST vars in Yii2

Created 5 years ago by aarondfrancis, updated 5 years ago by YiiJeka.

I wrote about this on my blog, but wanted to post it here too.

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