Amit Merchant

Amit Merchant

A blog on PHP, JavaScript, and more

  • Articles
  • Projects
  • Uses
  • Art
  • About
  • Ctrl K
  • Search
Laravel PHP JavaScript Git React

Loop over and include Blade views simultaneously using @each in Laravel

November 6, 2020 — Sometimes, there comes a scenario where you want to loop over a collection or array and include Blade views based on the iteration of that collection/array. You can use @foreach and @include for this purpose but there’s a handy way using which you can simplify this process.

Read More ⟶ ⋆ Laravel

Using .htaccess to access environment variables in PHP

November 3, 2020 — If you’re working with the latest frameworks, it’s not very difficult to set up environment variables for your app.

Read More ⟶ ⋆ PHP

Generate temporary URLs of AWS S3 files in Laravel

November 2, 2020 — Sometimes, all you want to do is generate temporary URLs for files that you have stored on your AWS S3 bucket. For instance, you would want to use this to prevent hotlinking of images.

Read More ⟶ ⋆ Laravel

How to upgrade legacy codebase to use PHP 8.0 features using Rector

November 1, 2020 — The newest version of PHP, the PHP 8.0, is coming later this year (November 26, 2020) and it will come packed with many new features such as constructor property promotion, match expressions, nullsafe operator, attributes and a lot others.

Read More ⟶ ⋆ PHP

How to use Attributes and their real-world usage in PHP 8.0

October 30, 2020 — Of many great new features that PHP 8 has introduced, one of the most confusing that I found were called “Attributes”, until today. Attributes in PHP 8 got revised many times before gets settled to the current implementation that we will see in a bit.

Read More ⟶ ⋆ PHP

Composer 2.0 — How to upgrade and features overview

October 26, 2020 — I’ve said it earlier and I’m saying it today as well that Composer is the backbone of modern development in the PHP landscape. It has been so much easier to pull in open-source packages into your projects which weren’t possible in the pre-Composer era.

Read More ⟶ ⋆ PHP

Custom Eloquent collections to make queries more readable in Laravel

October 23, 2020 — If you’ve worked with Laravel, you might be aware of the fact that all the multi-result sets returned by Eloquent are instances of the Illuminate\Database\Eloquent\Collection object. So, for instance, if you have a User model, you can get all the users like so.

Read More ⟶ ⋆ Laravel

Insert or update multiple records using upsert in Laravel 8.x

October 20, 2020 — It would be useful sometimes when you’re not sure if you want to insert or update records and you’d let the system decide that. Laravel comes with one such feature that lets you do just that.

Read More ⟶ ⋆ Laravel

Convert HTML to PDF like a pro using DocRaptor API (Sponsor)

October 16, 2020 — If you’ve ever worked on enterprise-level web applications, there’s a good chance that you would have in need to convert documents from one format to another such as converting an HTML document to PDF.

Read More ⟶ ⋆ PHP

How to use .env values in Laravel Envoy

October 14, 2020 — Laravel Envoy is a great tool if you want to create deployment flow for your application or even something as small as writing a script to pull the latest code and deploy the application right away.

Read More ⟶ ⋆ Laravel
« Prev 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 Next »

Download my eBook

PHP 8 in a Nutshell

Newsletter

By subscribing, you agree with Revue’s Terms of Service and Privacy Policy.

Follow me everywhere

My Tiny YouTube Channel ⟶ YouTube Icon

Recently Published

  • Do cleanup from useEffect in React.js whenever possible NEW

  • Plural strings based on the count in Laravel

  • Detecting slow database operations in Laravel 9.x

  • Keeping track of the last value of state in React.js

  • How to validate JSON in Laravel

Top Categories

Laravel PHP JavaScript Miscellaneous CSS React Git Jekyll VS Code ➔
Home About Contact Categories Guestbook
Previous page Next page
Amit Merchant
About Contact Categories Guestbook
Copyright © 2022 — Amit Merchant