PHP Frameworks

Understanding Inflector in Cakephp

Author - Parminder Kaur
|
0 Comments
|

Understanding the purpose and usage of Inflector in Cakephp

The Inflector class in cakephp is used to modify single/multi word strings into different formats using its build-in methods. We don’t need to use core php methods such as str_replace if you want to Read more…

Laravel Database Migration

Author - Umang Pasricha
|
0 Comments
|

What is Laravel Database Migration?

Laravel Migration provides a mechanism to propagate database changes from one machine to another (like development to production). It is a kind of version control of the database.

Create an application after installing laravel by using composer (like in the example Read more…

Laravel Log storage in S3 bucket

Author - Harpal Singh
|
0 Comments
|

How to Save Logs of Laravel in Amazon S3 Bucket?

Problem – We are working on a laravel project in which logs are saved in the storage folder of laravel and it is using a lot of space. We need to save logs of laravel in Amazon Read more…

Integrate Laravel web service with custom alexa skill

Author - Dalbir Kaur

Steps for integrating Laravel web service with custom alexa skill:

Step 1: Your web service should be on secure HTTP connection and should have SSL/TLS. Alexa strictly enforces for this to protect the confidentiality and integrity of your data.

Step 2: Open your amazon developer Read more…

Laravel’s powerful validation rules

Author - Pawandeep Kaur
|
0 Comments
|

Laravel’s powerful validation rules

When we develop any application in Laravel, various validation rules are available which are used to validate data from all incoming HTTP requests.

Some Examples:

1. First let’s create a controller named RegistrationController by executing the following command:Read more…

Reflection Api in Php

Author - Gopi Chand
|
0 Comments
|

Reflection Api in Php

What is Reflection and why is it useful?
Reflection is generally defined as a program’s ability to examine itself and modify its logic/methods at execution time. In simple terms, reflection is asking an object to tell you about Read more…

Integrate Razorpay in CakePHP application

Author - Rita Sharma
|
0 Comments
|

Integrate Razorpay in CakePHP application

Step 1: Create Razor Pay Account

First of all you need a test account for Razorpay integration. Click the below link https://dashboard.razorpay.com/#/access/signup and set up a test account there:

Step 2: Get your Read more…

PHP_CodeSniffer Introduction

Author - Preeti Bisht
|
0 Comments
|

What Is PHP_CodeSniffer?

PHP_CodeSniffer is an essential development tool that helps developers to work in a standardise format so as to make code clean and consistent. It ensures that same coding style is being followed. It allows a set of rules or a standard to be Read more…

Introducing WordPress versions 4.9.4 and 4.9.5

Author - Sukhpreet Singh
|
0 Comments
|

WordPress Version 4.9.5

WordPress 4.9.5 is released on 3rd April 2018. This version is released to fix the security issues. There were three major security issues which are solved by the WordPress community in this version:

1. Don’t treat Read more…

Migrate codeigniter (2.0.3) from php 5.3 to php 5.6 or higher version – conflicts

Author - Rita Sharma
|
0 Comments
|

I am working on a client project which is using Codeigniter running on version 2.0.3 and PHP 5.3. I got a requirement from client to upgrade the PHP version from 5.3 to 5.6 or higher. While I tried to upgrade the PHP version I have Read more…

In Laravel how to redirect to 404 page on accessing post route

Author - Dalbir Kaur

In Laravel, when a user directly accesses a post route then an exception page is shown. How to show a 404 page instead?

To fix this issue :

Firstly, you need to create an error page in view folder of your project like 404.blade.php and Read more…

PHP | Show star rating (empty or filled stars)

Author - Komal Dhiman
|
0 Comments
|

Sometimes situation arises when we have to show the ratings on our site like user rating of all the products available on our site. Then we have to first get the rating from where we have it like sometimes it may be from the third party etc. Once we have Read more…

Eclipse | Enable Php Support for extra features

Author - Parminder Kaur
|
0 Comments
|

In Eclipse (Luna Service Release 2 (4.4.2), jump to method definition is available for Java and other languages. But sometimes, it gets disabled for PHP.

For example ,if eclipse crashes. So to enable this, first you have to select the Php Perspective in Eclipse:

– Right Click on your Read more…

Capture Screenshot of a Webpage from its URL in PHP

Author - Gopi
|
0 Comments
|

Generally, Google PageSpeed Insights API is used to measure the performance of a web page but you can also use Google PageSpeed Insights API to get a screenshot of the website from URL. In this post, we will show you how to capture a screenshot of the webpage using its Read more…

Configure PHPMYADMIN to connect to different servers

Author - Ashish

Here are the steps to set up PHPMYADMIN to connect to database servers located at different ip addresses:

1. Open config.inc.php located in C:\xampp\phpMyAdmin directory in windows and located in /etc/phpmyadmin directory in Ubuntu.

2. Add the below written code at the end of the Read more…

CakePHP | Date format translation using internationalization

Author - Parminder Kaur
|
0 Comments
|

In Cakephp, To translate the application language into another, we use internationalization and localization. To display the correct translated date string on change of locale, we need to use right classes.

use Cake\I18n\I18n;
use Cake\I18n\Time;

I18n::Locale(‘es’’); // es locale is for Spanish
$date = ‘2017-08 Read more…

SQL Transaction in Cakephp 3

Author - Parminder Kaur
|
0 Comments
|

SQL transaction in Cakephp 3 is a series of statements working in a logical order to handle database errors and ensure data integrity. There are four main methods being used in Sql transaction in Cakephp 3.

1. Initialize the statement using begin() method.

2. Execute the statement which Read more…

How to integrate CyberSource payment gateway with CakePHP 2.*

Author - Webner
|
0 Comments
|

Steps to integrate CyberSource payment gateway with CakePHP 2.*:

1. Download zip file of CyberSource library from “https://github.com/chrismeller/cybersource”.

2. Extract cybersource-master folder into cakephp vendors folder.

3. Create tests/config.php for test transaction with code and add credentials like below:

<?phpRead more…

CakePHP | How to change Epoch timestamp (unix timestamp) timezone in cakephp find query

Author - Kailash
|
0 Comments
|

Suppose we have a table cake_test with a column named modified that contains epoch values.

CakePHP code:
$options = array (
‘fields’ => array (
“modified”,
“to_timestamp(modified) as New__original”,
“to_timestamp(modified) AT TIME ZONE ‘America/Denver’ as New__converted”
)
);
$result = $this->CakeTest->find ( ‘all’, $options );

In the above query we have Read more…

CakePHP | Call to a member function schema() on a non-object

Author - Manju Kashyap
|
0 Comments
|


Error:
Call to a member function schema() on a non-object
File: /home/user/git/!defaultRepo!/Appname/lib/Cake/Model/Datasource/Database/Postgres.php

Line: 404

Description: I was trying to execute the following cake query to fetch the records:
$records = $this->find ( ‘all’, array Read more…

1 2 3 4 5 6 7 8 9 10 Next page ›
Send your message