Wiki articles

Showing 121-140 of 145 items.

How To: Custom Client Validation On Checkbox Toggle and Optional Input Field

Created 3 years ago by Wade Shuler, updated 3 years ago by Wade Shuler.

I just chased my tail around for a bit today. I got lost with setting the status of all inputs, and banging my head on why the "validate" function just wasn't working.

0 0
1 follower
Viewed: 12 549 times
Version: 2.0
Category: How-tos

A universal model attribute for its synthetic representation

Created 3 years ago by Alexandre Rodichevski, updated 3 years ago by Alexandre Rodichevski.

It is convenient to use the same identification attribute, say info, in all of the active records of your application. It should be a virtual read-only attribute defined by a getter method, its label being the model name.

0 0
3 followers
Viewed: 8 328 times
Version: 2.0
Category: Tips

REST API and null values in XML

Created 2 years ago by marko60, updated 2 years ago by marko60.

I have been working on a REST API using the excellent tools provided by Yii2. My problem was that I have to differentiate between empty values and null values. In other words, <elem></elem> is different from null as it represents an empty string. Also, although some use <elem/> to represent a null value it should still be interpreted as an empty string. In other cases, the absence of the eleme...

0 0
0 follower
Viewed: 13 159 times
Version: 2.0
Category: Tips
Tags: null, REST, XML

Working with relational removals by yii2

Created 2 years ago by AndroideLP, updated 2 years ago by Jairus Martin.

This tutorial shows you how to safely remove records between relationships.

0 0
2 followers
Viewed: 21 185 times
Version: 2.0
Category: Tutorials

Use non Gmail/Gsuite on Gcloud projects

Created a year ago by Luis Armando, updated a year ago by Maurizio Domba Cerin.

Small companies and startups use cheap email services or even Cpanel's mail services which are less secure and compete directly with bigger email providers like Microsoft with Outlook and Google with Gmail. This creates a problem when you try to use their services to send/receive emails from this cheap services. <img width="750" src="https://static.techspot.com/fileshost/newspics3/2017/google-clo...

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

Installare Yii 2.0.* usando XAMPP su Windows in versione portabile

Created 5 years ago by realtebo, updated 4 years ago by realtebo.

Personalmente trovo che la versione "portable" sia molto più semplice da aggiornare, ed io tengo sempre costantemente aggiornato TUTTO il parco software relativo al mio webserver.

0 0
2 followers
Viewed: 18 624 times
Version: 2.0
Category: Tutorials

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

Created 5 years ago by Kartik V, updated 5 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 3
36 followers
Viewed: 28 633 times
Version: 2.0
Category: Tutorials

How to read HTML5 Multiple File Input from controller?

Created 5 years ago by Kartik V, updated 9 months ago by samdark.
0 2
40 followers
Viewed: 13 792 times
Version: 2.0
Category: How-tos

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

Created 5 years ago by Kartik V, updated 5 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:

0 2
40 followers
Viewed: 33 283 times
Version: 2.0
Category: FAQs

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

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

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

0 3
40 followers
Viewed: 13 121 times
Version: 2.0
Category: Tutorials

Locking your Yii 2 project package versions with composer.lock

Created 5 years ago by Kartik V, updated 5 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: 10 090 times
Version: 2.0
Category: Tips

Save and Display Date/Time Fields in different formats in Yii2

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

You would find having such a need in most Yii Projects. Your database needs a specific format to store date fields, while you may want to display it in different formats to the users on forms and other views.

0 0
51 followers
Viewed: 144 787 times
Version: 2.0
Category: How-tos

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

Created 5 years ago by Kartik V, updated 5 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: 19 867 times
Version: 2.0
Category: Tips

using 'whenClient' for complex client side validation

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

You have a 'Category' model with Id, Name and Visibility (boolean, where 0 = Public, and 1 = Private).

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

Book Has Author - Many to Many relations using Kartik\Select2

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

I could make this work following same useful tips from this post.

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

Managing different Bootstrap form layouts with yii2-field-range extension.

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

This wiki will explain how you can use the Field range extension with multiple Bootstrap form layouts (vertical or horizontal). You maybe aware, that 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: 23 735 times
Version: 2.0
Category: How-tos

How to sum (Update) of all input button price value using jquery

Created 5 years ago by Ankit Modi, updated 5 years ago by Ankit Modi.

Hi Friends, In this tutorial, how to update the sum of all the button data-price value using jquery, Just Follow three step and it's work easily.I hope It may be some helpful to others. See Image

0 0
2 followers
Viewed: 13 595 times
Version: all
Category: How-tos

Manage Email Template content from database

Created 5 years ago by Ankit Modi, updated 5 years ago by Ankit Modi.

Hi Friends,

0 1
1 follower
Viewed: 11 706 times
Version: all
Category: Tutorials

Role Management

Created 5 years ago by Dency G B, updated 5 years ago by Dency G B.

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: 17 107 times
Version: 2.0
Category: How-tos
Tags: rbac, yii2

Update and Delete buttons on Breadcrumb

Created a year ago by Daniel.

The definition of breadcrumbs according to its documentation is as follow: Breadcrumbs displays a list of links indicating the position of the current page in the whole site hierarchy.

0 0
1 follower
Viewed: 29 495 times
Version: 2.0
Category: Tips