Category:

Fix PHPMyAdmin redirect issue after login

Last updated on January 1st, 2020 at 09:16 pmLearn how to fix the PHPmyadmin Redirection issue with simple steps. Steps to fix PHPMyAdmin redirection issue Login to server via terminal using SSH Open PHPMyAdmin Config file “sudo nano /etc/phpmyadmin/config.inc.php” Add this code near configure option $cfg[‘PmaAbsoluteUri’] = $_SERVER[HTTP_HOST].dirname($_SERVER[SCRIPT_NAME]); Done Hope this tip help you

Continue Reading
Posted On :
Category:

Enable Gmail Notification in desktop

In this tip, I explain how we can enable Gmail desktop notification. This is very easy to do you can simply follow bellow step to enable notification. Steps to Enable Gmail Notification Login to Gmail in you desktop Go to Setting ⇒ General and look for desktop notification menu and click on enable desktop notification as shown […]

Continue Reading
Posted On :
Category:

Detect is your website is access from Mobile and Device

This is very simple and useful tip to detect that your user is using Android or iOs device to log in to your website in CakePHP 3 it is even easier CakePHP 3 device detection  $isMobile = $this->request->is(‘mobile’); $isAndroid = stripos($this->request->header(‘User-Agent’), ‘Android’); $isIPhone = stripos($this->request->header(‘User-Agent’), ‘iPhone’); $isIPad = stripos($this->request->header(‘User-Agent’), ‘iPad’); Core PHP $iPhone = stripos($_SERVER[‘HTTP_USER_AGENT’],”iPhone”); $iPad […]

Continue Reading
Posted On :
Category:

Fixing Composer killed in terminal while updating application

When I try to update my application packages using composer in terminal it shows me Killed error and terminate the process. It is mainly due to server Memory Issue. You can fix using bellow command. I test this command on my live server and it works well for me. /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024 /sbin/mkswap /var/swap.1 sudo […]

Continue Reading
Posted On :
Category:

Update or Recover ARO|ACO in Cakephp 3

Sometime in Cakephp3 while working with ACL we get some error related to ACO|ARO or our table is corrupt we can solve those issue using bellow commands  To recover ACO table run bellow command in terminal bin/cake AclExtras recover aco To recover ARO table bin/cake AclExtras recover aro If you want to check some other […]

Continue Reading
Posted On :
Category:

Round off decimal to nearest highest value

If you wan’t to round off decimal value to nearest heights value you can use bellow code <?php if( !function_exists(‘ceiling’) ) { function ceiling($number, $significance = 1) { $value = ( is_numeric($number) && is_numeric($significance) ) ? (ceil($number/$significance)*$significance) : false; if(!isFloatWith2Decimals($value)){ return $value.’0′; }else{ return $value; } } } function isFloatWith2Decimals($number) { return (bool) preg_match(‘/^(?:[1-9]{1}\d*|0)\.\d{2}$/’, $number); […]

Continue Reading
Posted On :