Starting with Google Chrome v63, any domain using the .dev extension will be forced to use HTTPS. What does this mean? If you're using .dev in combination with Laravel Valet, you should switch to .test which is reserved specifically for developer use. You can easily do this by running the following Valet command: valet domain test Once you've done this, don't forget to update the APP_URL in your project's .env file and you should be good to go.…

When building an application that handles events, appointments, or any sort of data with a start and end time, you'll eventually find that you need to do a MySQL query for events that overlap a date range. The two most common uses include: Allow users to filter events by date range Ensuring calendar appointments don't overlap If you've never written a query to do this before, it can be confusing and easily overcomplicated. Thankfully it's actually pretty simple. The Solution I figure some of you will just want the solution, so we'll start there and work backwards. Assume we have…

With Bootstrap 4 now in beta, many people are beginning to switch their projects over to V4. Obviously the migration process requires changing existing markup, which you can learn more about in the official guide), but for this guide I'll only be covering how to integrate it in your Laravel Mix build process. Remove the old Bootstrap dependency To remove the old dependency, we just need to run this command in our project directory: npm uninstall bootstrap-sass --save-dev Install the beta dependencies We'll need to install both the Bootstrap 4 beta as well as Popper.js (used by Bootstrap for…

One of the many useful features of Eloquent is the ability to define accessors and mutators. Mutators can help you if there's something you'd like to do with a value (like hashing a password) every time it gets set on your model. Accessors are for doing something every time you retrieve an attribute (like converting markdown to HTML). You can even use an accessor to dynamically create additional properties on your model (like a full name that concatenates first and last names). Those are great features, but we also have attribute casting so we can convert attributes to common data…

If anyone knows the U.S. Women's National Team inside and out, it's Sweden. Facing Pia Sundhage, who left her role as the U.S. head coach shortly after winning gold in the London Olympics, has always made me nervous. My most vivid memory from the group stage of the 2015 World Cup was watching the crossbar bounce up and down after Meghan Klingenberg's headed clearance off the line, a play that saved the US from a loss to Sundhage's Sweden. I loved watching Pia coach the USWNT. She always seemed like she was having fun, had a good relationship…