That’s it!. Please share your thoughts or suggestions in the comments below.
Instead of PHPDoc annotations, you can now use structured metadata with PHP’s native syntax. That’s it!. Please share your thoughts or suggestions in the comments below.
Less boilerplate code to define and initialize properties. That’s it!. Please share your thoughts or suggestions in the comments below.
PHP 8 Nullsafe operator Instead of PHPDoc annotations for a combination of types, you can use native union type declarations that are validated at runtime. That’s it!. Please share your thoughts or suggestions in the comments below.
Instead of null check conditions, you can now use a chain of calls with the new nullsafe operator. When the evaluation of one element in the chain fails, the execution of the entire chain aborts and the entire chain evaluates to null. That’s it!. Please share your thoughts or suggestions in the comments below.
The new match is similar to switch and has the following features: Match is an expression, meaning its result can be stored in a variable or returned. Match branches only support single-line expressions and do not need a break; statement. Match does strict comparisons. That’s it!. Please share your thoughts or suggestions in the commentsRead more about PHP8 Match Expression[…]
It contains many new features and optimizations including named arguments, union types, attributes, constructor property promotion, match expression, nullsafe operator, JIT, and improvements in the type system, error handling, and consistency. Here is the list of main new features: Union Types Named Arguments Match Expressions Attributes Constructor Property Promotion Nullsafe Operator Weak Maps Just InRead more about What’s new in PHP 8[…]
In this article, We’ll get the filname from the path provided. To get the filename from path, we’ll use php’s inbuilt basename function. basename() function in PHP is an inbuilt function which is used to return the base name of a file if the path of the file is provided as a parameter. That’s it!.Read more about How to get filename from path in php?[…]
Laravel 7 released on Tue, 3 Mar 2020 and it includes many new features including Laravel airlock, speed routing, better eloquent, blade component tags and many more. According to Release Notes, new packages, improvements and features in Laravel 7 are as follows: Laravel Airlock by Taylor Otwell Custom Eloquent Casts Blade Component Tags HTTP ClientRead more about Laravel7 Features[…]
In this article, We’ll see how to send push notification to android and ios both using fcm. Firebase Cloud Messaging (FCM) is a new cloud messaging services to send push notifications to Android, iOS and Web applications. It is the newer version of GCM (google cloud messaging) with more features. To send notifications, we basicallyRead more about Send Push Notification using FCM in PHP[…]