How To: CRUD with Validation in Ember.js Using ember-easyForm, ember-validations, and Boostrap

Nailed it.

Aloysius Lim

One of the basic building blocks of any web application is CRUD, or Create, Read, Update and Delete.It allows users and administrators to manage the data in the application. Full-stack server-side MVC frameworks like Django or Ruby on Rails provide code generators that give you all the code needed for a basic CRUD interface. But what if you were usingEmber.js to build your application? Ember.js does not provide any code generators, and there is no established idiom or best practices for CRUD in Ember.js. In this series I will show how to build a basic CRUD interface in Ember.js, complete with user input validation.

View original post 2,430 more words

Traits in PHP


Laravel Tutorials, Tips & Tricks

If you worked with abstract objects before, you are aware of the single inheritance limitation, traits fix this in a very elegant way to allow us to write re-usable code.

Creating traits

Traits are created using the trait keyword:

Using traits

To add a trait to a class, use the use keyword within the class:

That’s it! now you have all the trait’s methods available, to use multiple traits you can declare them on the same line separating them with a comma:

Note: traits can’t be instantiated.

View original post