Install PHPMailer: You can install PHPMailer using Composer or by downloading it manually from GitHub. Here’s how to install it via Composer: composer require phpmailer/phpmailer Include PHPMailer Autoload File: Include the PHPMailer…
Category: PHP Code
How to send JWT Token to Mobile app from PHP API
To send a JWT (JSON Web Token) to a mobile app using a PHP API, you typically follow these steps: Here’s a basic example in PHP demonstrating how you might generate and…
How to send Push Notification to a Topic using Firebase Cloud Messaging (FCM)
To send a push notification to a topic using Firebase Cloud Messaging (FCM), you can follow these steps: Here’s an example PHP code snippet to send a push notification to a topic…
How to send Push Notification to particular App user, using Firebase Cloud Messaging (FCM) & Device Token
To send push notifications to a particular app user using Firebase Cloud Messaging (FCM), you can follow these steps: Here’s an example code snippet in PHP to send a push notification to…
How to upload .CSV file with millions of records without using any loop statement
If you want to upload a csv file have large number of records and you don’t want to use any loop statement then You can use MySQL’s LOAD DATA INFILE statement to…
How to Implementing Paging in PHP ?
In the world of web development, efficient data presentation is crucial, especially when dealing with large datasets. Paging, also known as pagination, is a technique that allows you to break down and…
What is the difference between mysqli_fetch_array and mysqli_fetch_assoc?
Both mysqli_fetch_array and mysqli_fetch_assoc are PHP functions used to fetch rows from a MySQL database result set. However, they differ in how they return the fetched data. Example usage of mysqli_fetch_array: Example…
How to enable “Authorization” or all header in Bitnami LAMP on AWS ?
To allow all headers in Apache, you can add the following directive to your Apache configuration: This directive tells Apache to allow all headers by setting the value of the Access-Control-Allow-Headers header…
How to implement url rewriting in core php website?
URL rewriting in a Core PHP website can be implemented by creating a .htaccess file in the website’s root directory and adding the necessary rules. Here are the steps to follow: To…
How to start a new page for printing from a particular part of a page in PHP?
If you want to print output from a PHP page and you want to start the new page for printing from a particular part of a page in PHP, you can use…