Wiki articles tagged with "yii2"

Showing 61-80 of 85 items.

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

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

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.

3 0
46 followers
Viewed: 29 213 times
Version: 2.0
Category: Tips

Model validation for field ranges using yii2-field-range extension

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

The yii2-field-range extension enables you to easily setup ActiveField range fields with Bootstrap styling. You basically can setup two attributes joined together like a single field with combined validation error block.

0 0
37 followers
Viewed: 27 803 times
Version: 2.0
Category: Tips

Yii2 and Pdf files with Mpdf

Created 9 years ago by CTala, updated 9 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: 32 127 times
Version: 2.0
Category: How-tos

Displaying uploaded file from DB for update with FileInput widget

Created 10 years ago by Kartik V, updated 9 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?

2 3
43 followers
Viewed: 61 915 times
Version: 2.0
Category: How-tos

Using the yii2-datecontrol extension along with yii2-detail-view widget

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

The yii2-datecontrol extension allows you to control separate date formats for display and saving for form inputs.

1 0
37 followers
Viewed: 21 065 times
Version: 2.0
Category: How-tos

Filter & Sort by Summary Data in GridView Yii 2.0

Created 10 years ago by Kartik V, updated 9 years ago by Kartik V.

This wiki explains how to add summary data from related models into your Yii Framework 2.0 gridview with filtering and sorting by the summary columns.

5 2
48 followers
Viewed: 71 893 times
Version: 2.0
Category: Tutorials

Managing your nested dropdown dependency with DepDrop widget

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

If you are coming over to Yii 2 from Yii 1.x, you may have already read this useful wiki for creating dependent dropdowns. You can use a similar approach in Yii 2 to do the same. But if you are looking at a prebuilt solution that helps you manage it easier, read along.

2 3
42 followers
Viewed: 87 859 times
Version: 2.0
Category: Tutorials

How to store array/widget configuration to the database with config validation rules

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

Note the tag {{homeUrl}} will be dynamically replaced at runtime.

2 3
41 followers
Viewed: 23 776 times
Version: 2.0
Category: Tutorials

Managing a star rating with the StarRating widget in Yii 2

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

In Yii 1.x, there was a built in widget CStarRating based on the jquery star rating plugin. There exists no prebuilt solution in Yii2, however the same concepts can be extended using any jquery plugin.

1 3
41 followers
Viewed: 24 196 times
Version: 2.0
Category: How-tos

Install specific Yii2 vendor extension & dependency without updating other packages.

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

The tips here are for advanced usages of composer and its assumed you have read about using composer and have a knowledge of your vendor packages to be updated. Let's consider, you want to update only one specific yii2 vendor library, without updating all the other extension packages?

2 3
39 followers
Viewed: 43 486 times
Version: 2.0
Category: Tips

Locking your Yii 2 project package versions with composer.lock

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

Ok, you have installed a Yii 2 basic or advanced app for the first time and completed the post install steps. You have picked up a few extensions to install for the first time as well. You would already see a composer.lock file in your application root folder.

0 2
37 followers
Viewed: 16 689 times
Version: 2.0
Category: Tips

My Own Components Folder in Yii2

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

In Yii1 I used to have my own components under the components folder of the structure, now with namespacing this is a little bit different.

2 1
2 followers
Viewed: 20 898 times
Version: 2.0
Category: Tips

FORM with GET method causes repeated stacking of URL Parameters

Created 10 years ago by Kartik V, updated 10 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(); `

7 2
41 followers
Viewed: 61 659 times
Version: all
Category: Tips

Overcoming removal of client helpers (e.g. ajaxLink) and ClientScript in Yii 2.0

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

Alternatively, inline assets (JS/CSS) can be registered at runtime from within the View. For example you can clearly simulate the ajaxLink feature using a inline javascript. Its however recommended if you can merge where possible, client code (JS/CSS) into separate JS/CSS files and loaded through the AssetBundle. Note there is no more need of a CClientScript anymore:

1 2
41 followers
Viewed: 43 537 times
Version: 2.0
Category: FAQs

What to do when composer fails to update your vendor packages?

Created 10 years ago by Kartik V, updated 10 years ago by Kartik V.
  • Running a composer update does not fetch any new packages (even though the source is updated)
  • A specific vendor package never gets updated
  • Facing on and off problems when fetching packages while performing composer update.
  • You ran a composer update earlier, but it was partially done, before you lost network connectivity, and you cannot refresh packages anymore.
0 4
36 followers
Viewed: 49 774 times
Version: 2.0
Category: Tutorials

Yii2 default values for Index data Provider

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

Guys,

2 0
5 followers
Viewed: 31 661 times
Version: 2.0
Category: Tips

Cómo enviar emails usando SMTP

Created 10 years ago by robregonm, updated 10 years ago by robregonm.
2 0
2 followers
Viewed: 33 035 times
Version: 2.0
Category: How-tos

Displaying, Sorting and Filtering Model Relations on a GridView

Created 10 years ago by Antonio Ramirez, updated 10 years ago by Antonio Ramirez.

One of the things you will find tricky to implement is the the sorting and filtering of a GridView's column that displays related model data.

49 0
38 followers
Viewed: 326 715 times
Version: 2.0
Category: How-tos

How to use BootstrapInterface

Created 10 years ago by Antonio Ramirez, updated 10 years ago by Antonio Ramirez.

Yii2 introduces the BootstrapInterface to ease our application initialization tasks, whether they are composer based or Application bootstrap (do not mistaken with Bootstrap CSS Framework) based tasks. On this article, I am going to explain how to use it on y...

2 0
3 followers
Viewed: 19 752 times
Version: 2.0
Category: How-tos

Automatic Parameter Binding to POST vars in Yii2

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

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

0 0
4 followers
Viewed: 25 797 times
Version: 2.0
Category: How-tos