Tag: Business Website
How To get list of all system defined properties in java
Just write below line in your main java program and it will show you all System defined properties. System.out.println(System.getProperties()); Some of the important properties that we can use generally: 1. user.dir will give project root directory location. 2. java.class.path will
SFTP to server using FileZilla without password
We can connect to a remote server via SFTP without password, using PEM file of server. The PEM file is public key certificate file of the server to which we have to connect. We’ll need to have following details in
Mysql | How to drop table having dot (.) in the table name in MySQL
We had a table in our database having dot in the table name as below: Table name – kpc.product_categories On trying to delete kpc.product_categories using below command: drop table kpc.product_categories It used to give error that no such table exists.
Cakephp | URL routing using prefix before domain name
Routes in an application are configured in app/Config/routes.php. Defining your own routes allows you to define where your application will take the control to for a given URL. Default routing is like this: domain/controller/action Ex. www.xyz.com/user/login Prefix routing will add
Run embedded batch files
In one of the projects we had a batch file which runs another batch file within it in a loop. This was not working. It used to run once and then used to get stuck. This is sample code of
PHP | Clone arrays containing objects
In PHP you need deep cloning to clone arrays containing objects. Suppose we have $cold_items as an array of objects. To clone it appropriately so that while changing the values in one array does not impact the other one, use
Java | Shallow and Deep comparison of objects
There are two types of object comparison in java – shallow and deep. when you use ‘==’ operator, you are comparing the references for equality. It means you are comparing memory addresses of the objects. It is called shallow comparison.
Call third party JSON webservice in cakephp 3.0
To call third-party web service in CakePHP 3.0. You can use Http client available in CakePHP core lib (CakeNetworkHttpClient). Include CakeNetworkHttpClient in your controller. use CakeNetworkHttpClient; Here is the method to call third-party web service. You can use this method
Cakephp | URL routing using prefix after domain name
Routes in an application are configured in app/Config/routes.php. Defining your own routes allows you to define where your application will take the control to for a given URL. Default routing is like this: domain/controller/action Ex. www.xyz.com/user/login Prefix routing will add