In this article we will learn collection count and detect or check empty eloquent collection in laravel. Laravel collection is used to simplify the operations of array. Illuminate\Support\Collection library is used to handle the collection and arrays in laravel. Laravel…
Readerstack

How to check user agent in angular ?
In this post, we will show you how to check user agent in Angular. user-agent header is a string that contains information about the browser and operating system. It is set by the browser and sent to the server with…

How to use laravel whereNotIn query with example ?
In this guide we will learn to create SQL not in query using laravel whereIn eloquent builder. whereNotIn laravel can used multiple ways to build the query one the of the feature of laravel eloquent is creating dynamic query based…

How to use moment js in angular ?
This post covers how to use Moment.js in Angular. We’ll go over why Moment.js is useful, how to install it, and how to use it in Angular to manipulate dates and times. Moment.js is a powerful and flexible library for…

How to get laravel application root path ?
In this blog post, we’ve shown you how to get the path to your Laravel application root path directory. If you need to get the path from anywhere in your application, you can use the Laravel public_path() helper function. If…

How to get random rows in laravel example ?
In this blog post, we’ll take a look at how to get random rows in Laravel database. We’ll explore the use of the QueryBuilder, Eloquent, and the DB facade. laravel has inbuilt eloquent method to get the random records from…

Angular ngClass conditional class Example
In this blog post, we’ll explore Angular ngClass conditional class Example in component’s styles based on certain conditions. Sometimes in our application we want dynamically change the color, size, font, background images so Angular provides various ways to conditionally apply…

Laravel multiple orderBy clause with example
In this blog post, we will take a look at how to use the multiple orderBy clause in the Laravel Eloquent ORM. You can order query results by multiple columns using the orderBy method. This is useful when you want…

Angular Dynamic Style CSS with Example
In this blog post, we’ll explore Angular dynamic style CSS with example in component’s styles based on certain conditions. Sometimes in our application we want dynamically change the color, size, font, background images so Angular provides various ways to conditionally…

Laravel orderBy clause in eloquent with example
In this blog post, we will take a look at how to use the orderBy clause in the Laravel Eloquent ORM.Laravel provides an expressive, fluent interface for creating and retrieving records in your database. When we work with databases in…