PHP Frameworks Archives

How to validate records before inserting in CakePHP 2.X

Author - Webner
|
0 Comments
|

Problem:

Sometimes we only need to validate records before inserting operations in CakePHP. In the case of bulk insertion and CSV records validation, it’s very difficult to validate individual fields of bulk records.

Solution:

array (‘validate’ => ‘only’) parameter will do exactly that for us.

Read more…

Laravel 5.4 Logs And Errors

Author - Webner
|
0 Comments
|

Introduction

Logfiles:

Logs are files that keep a registry or records of events, processes, messages that occur in the operating system or any software that runs.

Laravel provides the robust logging services that allow the user to log messages to file.
Laravel uses the Monolog library Read more…

Firebase Integration With Laravel 6.x (Ubuntu 18.04)

Author - Webner
|
0 Comments
|

Below are the steps to integrate Firebase with Laravel 6.x

Step 1

To integrate Firebase with Laravel we first need a Laravel project. Create a new Laravel project using the given composer command.

composer create-project –prefer-dist laravel/laravel firebase

Step 2

Read more…

Regular expressions in PHP

Author - Webner
|
0 Comments
|

Regular expressions

Regular expressions use arithmetic operators like +,^,- and create complex expressions that can help to validate IP address, email address, telephone no, etc. They save our coding time.
Some of built-in PHP regular expressions are:

Preg_replace- perform pattern match on a string and returns true if Read more…

Convert PDF To Image In PHP

Author - Webner
|
0 Comments
|

How to convert PDF to image file using PHP?

Before installing PDF to Images package, firstly you need to install two PHP extensions
Imagick and Ghostscript.

Step 1: Install Imagick

sudo apt-get install php-imagick

Step 2: Restart Apache

In the second step Read more…

Introduction to MVC

Author - Webner
|
0 Comments
|

What is MVC?

The MVC is a very frequent web development architectural framework or application designing model which contains three main components the Model, the View and the Controller each of them performs different functions assigned to them.

It helps us to avoid complexity by dividing the application Read more…

Compress Videos using FFmpeg Laravel & shell_exec method

Author - Webner
|
0 Comments
|

Introduction

First of all, install FFmpeg in your composer. Perform the steps below to install it on Ubuntu:

composer require pbmedia/laravel-FFmpeg

Start by updating the packages list:

$ sudo apt update
– Next, install FFmpeg by typing the following command:

$ sudo apt install FFmpeg

– To check FFmpeg is Read more…

Reformat associative array in CakePHP 2.*

Author - Webner
|
0 Comments
|

How to use CakePHP 2.* Hash::combine method to reformat associative and find results array?

Sometimes we do a lot in the code to reformat find query results, to remove the table name (for example, User, Article, etc) from the array and sometimes use one of the column Read more…

Creating A New Laravel App With Initial Setup

Author - Harshit Gulati
|
0 Comments
|

How to create a new laravel app with initial setup and get everything up and running?

To create your first Laravel app, you will require some prerequisites and here is what you will need to have installed:

Composer

WebServer; I am using Apache ( For Windows and macOS, I Read more…

Laravel Events Introduction With Example

Author - Pawan Gulati
|
0 Comments
|

Laravel Events

Events are one of the many powerful features of the Laravel. The event basically means the thing that happens or takes place, especially the one that is important. So, in Laravel’s case, events are triggered when some condition is met like most websites have authentication Read more…

Validation vs. Application Rules In CakePHP

Author - Pawandeep Kaur
|
0 Comments
|

CakePHP uses a two-layered approach to validation:

1. Validation
It determines basic validity. It ensures that the data types, size, and format of data are correct. When we call newEntity() or patchEntity() methods, validations are triggered. For example, checking if an email address Read more…

Methods of Debugging – PHP

Author - Umang Pasricha
|
1 Comment
|

Methods of Debugging by dumping information

These methods are used for debugging in PHP. We can see the variable values in human-readable form on the console and can find errors in case there are issues due to variables incorrect values. print_r() and var_dump() are used Read more…

Collections in C#

Author - Monika Dhiman
|
0 Comments
|

Collections in C#

Arrays
Arrays are useful for creating and working with a fixed number of strongly typed objects.

Problem with Arrays:
1. Fixed length
2. Insert similar data type elements

Collections
Collections are used to create and Read more…

Progress Bar Using AJAX/PHP

Author - Webner
|
0 Comments
|

Progress Bar For Large Uploads Using AJAX/PHP

Problem:
When large files are being uploaded, a server at the back takes time to upload the same file. Users have to wait irrespective of knowing, whether the file is even being uploaded or not and how much Read more…

How to set the values of Metadata (column fields) of Sharepoint Documents

Author - Umang Pasricha
|
0 Comments
|

How to set the values of Metadata(Column fields) of Sharepoint Documents

Here is the code in C# which helps you to change the metadata field values of Sharepoint Files.

//This manager class can be used to obtain a SharePointContext object
OfficeDevPnP.Core.AuthenticationManager authMgr = new Read more…

Paytm gateway integration in PHP

Author - Vikas Dalal
|
1 Comment
|

Paytm gateway integration in PHP

Paytm is a very popular way to make payments these days. To integrate Paytm in our site we need to follow the given steps –

Step 1. First, we need to create an account at https://business.paytm.com/ and get our Read more…

Fill a PDF form using C# console application

Author - Mahesh Kumar
|
0 Comments
|

Fill a PDF form using C# console application

We will be using the SyncFusion Package to fill out the PDF Form Fields. To add SyncFusion to your project follow these steps :

1. Go to Tool -> NuGet Package Manager -> Manage NuGet Packages For Solution
2. Then search Read more…

Showing Deletion Confirmation box in Laravel datatables

Author - Komal Dhiman
|
0 Comments
|

Showing Deletion Confirmation box in Laravel datatables

Datatables are the finest way to show the larger number of records to the user on a single page as it provides so many features like sorting, pagination, etc. Sometimes we need to provide the facility to edit or Read more…

Deploy the laravel project on 1&1 production server

Author - Manoj Thakur
|
0 Comments
|

How to deploy the laravel project on Shared hosting server

On shared Environment:

Step 1: Push the code to Production Server.

I’m assuming that your project is running perfectly on your localhost and now you are ready to push it to Read more…

Download files from S3 disk in Laravel

Author - Navneet Kaur
|
0 Comments
|

how to download file from s3 disk in Laravel

What is AWS S3?
Amazon Simple Storage Service (Amazon S3) is an object storage service that offers industry-leading scalability, data availability, security, and performance. S3 helps you securely upload and download your data with Read more…

1 2 3 4 5 6 ... 13 Next page ›