Friday, 2 August 2019

How to set cron job in heroku in PHP | Codeigniter

Step 1:  Install Heroku Scheduler add-ons from Heroku.


Step 2: Goto Heroku Scheduler page and add Job, set time interval and add command " php /app/index.php orderupdate crontset jaydip "
  1. php = server language
  2. /app/index.php = Path of the project root index.php
  3. orderupdate = name of controller
  4. crontset = name of function
  5. jaydip = variable name which you want to get into crontset function
Step 3: open Orderupdate.php controller

public crontset function($name){

echo $name;

}

Wednesday, 31 July 2019

Thursday, 18 July 2019

How to run composer install in another PHP version

How to tell Composer to use Different PHP Version
#ea-php72 /opt/cpanel/composer/bin/composer install
You can get list of php by using following command
# ls /usr/bin/ | grep php 

Check list of Installed PHP versions and PHP CLI version into cpanel

# ls /usr/bin/ | grep php
Result
alt-php-mysql-reconfigure@
alt-php-mysql-reconfigure.py*
ea-php54@
ea-php54-pear@
ea-php54-pecl@
ea-php55@
ea-php55-pear@
ea-php55-pecl@
ea-php56@
ea-php56-pear@
ea-php56-pecl@
ea-php70@
ea-php70-pear@
ea-php70-pecl@
ea-php71@
ea-php71-pear@
ea-php71-pecl@
ea-php72@
ea-php72-pear@
ea-php72-pecl@
lsphp*
php*
php5@
php5-cli@
php-cgi@
php-cli@



Friday, 5 July 2019

How to add file into gitignore which is already push into github

Step 1 : You need to soft remove from git : $ git rm --cached tax.txt
Step 2 : Add tax.txt file in .gitignore
Step 3 : commit and push.
Step 4 : Finished!

Saturday, 29 June 2019

How to change startSymbol endSymbol of Angular JS

I face the issue when use Angular JS in shopify liquid file at that time I have use following script.

var fetch = angular.module('myapp', []).config(function ($interpolateProvider) {
    $interpolateProvider.startSymbol('{[{').endSymbol('}]}');
});

Friday, 28 June 2019

How to disable Right click inside the Iframe

<iframe style="pointer-events:none;" src="https://jaydip+kansagra.com/landscape.pdf#toolbar=0&navpanes=0"/>