~/devreads

#laravel

16 posts

7 May 2018

Junior Grossi 4 min read

Laravel is a PHP framework that uses Eloquent, a powerful and amazing ORM that allows you to do complex SQL queries in a very easy way. But sometimes you need more, and here I’m gonna give you an interesting tip that can bring you a lot of flexibility. When dealing with simple database queries in … Continue reading Querying and…

laravelphp

30 Apr 2018

23 Apr 2018

Junior Grossi 10 min read

Having a clean code with single responsibility is important, and doing that for model filtering can be easy and very powerful. Believe me. This blog post is related to a talk I gave on April, 2018 on Darkmira Tour PHP 2018, in Brasília/DF, Brazil, with the same title. The slides are on SpeakerDeck. Filtering models … Continue reading QueryFilter: A…

laravelopen sourcephptalks

1 Aug 2015

Schakko 1 min read

When using the Mail facade in Laravel it is not so easy to test the output of the parsed mail template. Like http://stackoverflow.com/questions/31120567/unittesting-laravel-5-mail-using-mock I received the error Method Mockery_0__vendor_Swift_Mailer::getTransport() does not exist on this mock object. I ended up in listening to the mailer.sending event: public function testRegistrationMailIsSend_afterSubmittingForm() { // […] The post Integration testing the mail dispatching in Laravel…

laravel

28 Jul 2015

Schakko 2 min read

In my last post I wrote about how to define the test environment for database integration tests. Now I want to describe, how the database can be populated with test or stam data. First of all, every test inherited from the generated TestCase class executes the Artisan migrate command (TestCase::prepareForTests()). […] The post Seeding the database for integration tests in…

laravel

27 Jul 2015

Schakko 1 min read

As far as I have read, in Laravel 4 you could define your database integration test environment by adding a testing/database.php or .env.testing.php file containing your configuiration. In Laravel 5 both ways does no longer work. To switch your environment you have two options: Put both configuration definitions (testing, dev/production) […] The post Test environments for database integration tests in…

laravel

25 Jul 2015

Luciano Mammino 15 min read

This post highlights 6 important rules to keep in mind when developing performant web applications: avoid premature optimization, do the minimum required work, defer non-critical tasks, leverage caching, avoid N+1 queries, and design for horizontal scaling. Following these guidelines will help you write efficient code from the start and build apps ready to handle growth.

phpsymfonylaravelperformancescalability

18 Apr 2015

27 Feb 2015

26 Apr 2014

Junior Grossi 5 min read

Hi everybody! Updated Mar 3rd 2015: Are you using Laravel 5? Check these changes! Updated May 11th 2014: Using Corcel project Currently I am working on a project where I had to make some choices about technologies and how work with them together. First this project will be developed using WordPress only. It’s a College … Continue reading Working with…

laravellaravel 4phpweb serverwordpress

4 Nov 2013

Junior Grossi 4 min read

Generally assets are stored in your public directory, right? They are public, so anyone can get access to them. But nowadays the performance is a very important factor when deploying a new app. I strongly recommend you to minify and cache your assets, like CSS files, Javascript files and Images. If you are using 11 … Continue reading Managing assets…

composerlaravellaravel 4php

14 Oct 2013

Junior Grossi 1 min read

One of the best improvements of the PHP 5.4 was the built-in web server. Like in Ruby On Rails, now you do not need Apache or Nginx inside your development machine. To start a web server is easy: php -S localhost:8000 Remember you can choose the port you want. You can use localhost:8000 or localhost:8080 … Continue reading Working with…

laravellaravel 4php

18 Sept 2013

Junior Grossi 1 min read

These days I’m thinking about productivity and the use of PHP frameworks. I’ve read some posts about framework X or Y, defending a framework instead of another one. I know people that use a framework like Zend Framework to develop a simple website just to say they’re using it, and not an “easy” framework. I … Continue reading Solve the…

composerlaravelphpwordpresszend framework

26 Jan 2013

Junior Grossi 6 min read

Hello! One of the most big changes happening in PHP world is the Composer. I’m shure you heard about it but maybe you don’t know why you should use it and how much it is good for you and your projects. What is Composer? When you need some specific code in PHP you can go … Continue reading Why you…

composerlaravelphp

22 Jan 2013

Junior Grossi 3 min read

Hello everyone! Use or not to use a PHP Framework on your new projects? Here I’ll talk about my personal opinion about that and I wish help you. First, I have a simple concept about languages and respectives frameworks: a framework must make the development simpler. Every software has a single purpose: work! This is … Continue reading Why you…

composerlaravelphp

11 Oct 2012

Junior Grossi 3 min read

Hello! Laravel is an awesome PHP framework created by Taylor Otwell. Actually, it is on the third version and it is one of the great PHP frameworks we have today. As a lot of frameworks, we have to create our own Apache Virtual Host to point to the public dir to improve security and only … Continue reading Deploying Laravel…

laravelphpuncategorized