Shahadat Hossain Khan Razon
Office Address: 450/A # South Goran (2nd Fl.), Dhaka

COVID 19 Update

[HOT Numbers] IEDCR: 10655 | Health Department: 16263 | Health News: 333

the fact of real shit

Changing ZF2 Core 2.4.13 Zend\View\Helper\HeadLink::createDataStylesheet
class: Zend\View\Helper\HeadLinkfunction: createDataStylesheetphp version: 7.3 public function createDataStylesheet(array $args) { $rel = ‘stylesheet’; $type = ‘text/css’; $media = ‘screen’; $conditionalStylesheet = false; $href = array_shift($args); if ($this->isDuplicateStylesheet($href)) { return false; } if (0 < count($args)) { $media = array_shift($args); if (is_array($media)) { $media = implode(',', $media); } else { $media = (string) $media; } } […]
Install php 7.2 ssh2 in ubuntu 16x
recently i need to install ssh2 connection through my php code to connect remote server by sftp for file transfer. i’m using php 7.2 and face a “sigment fault” issue for normal installation. i solved this issue by install required demon. hope it may help someone who face same issue. first you need to install/upgrade […]
changing zf2 core 2.4.13 Zend/Stdlib/ArrayObject.php
class : Zend\Stdlib\ArrayObject function: unserialize($data) php version: 7.3 previous (original) code /** * Unserialize an ArrayObject * * @param string $data * @return void */ public function unserialize($data) { $ar = unserialize($data); $this->protectedProperties = array_keys(get_object_vars($this)); $this->setFlags($ar[‘flag’]); $this->exchangeArray($ar[‘storage’]); $this->setIteratorClass($ar[‘iteratorClass’]); foreach ($ar as $k => $v) { switch ($k) { case ‘flag’: $this->setFlags($v); break; case ‘storage’: $this->exchangeArray($v); break; case […]
kill mysql process which is ideal for N seconds
step 1: login mysql through putty step 2: execute – SELECT GROUP_CONCAT(‘KILL ‘,id,’; ‘ SEPARATOR ‘ ‘) FROM information_schema.processlist WHERE time > 500 AND user<>’system user’; step 3: you will get a string as output. copy that string and paste into mysql command prompt and press enter… nJoy
going to change ZF2.4.9 core
I decided to change ZF 2.4.9 core. I know its a wired decision. But I don’t have any choice, cause they didn’t provide any release for PHP 7x. But the change will noted in this site by adding post for future. Today I’m changing – class: Zend\Validator\EmailAddress function: idnToAscii($email) and function:¬†idnToUtf8($email) Previous (original) code – […]
Hello world!
Welcome to WordPress. This is your first post. Edit or delete it, then start writing!
change mysql data directory ubuntu 17.xx
Follow¬† NOTE: you can skip empty directory (/var/lib/mysql/mysql) creation script in ubuntu 17.xx version. Then try to start mysql server. If fail then log messages are telling you that /usr/sbin/mysqld needs read (r) access to open /proc/14767/status, /sys/devices/system/node/ (trailing slash because it wants to read the directory), and /proc/14767/task/14767/mem. The file to edit is /etc/apparmor.d/usr.sbin.mysqld. […]
network adapter at guest [ubuntu] while setup host only network at virtualbox
I’m trying to setup host only network at virtualbox by following but facing to choice network adapter at guest [ubuntu] To see a list of the adapters your virtual machine can access, use this: ls /sys/class/net This will show you the interface names. For example, with two network adapters set up, my Ubuntu guest […]
JavaScript class encaptulation
My favorite JavaScript class structure – (function(exports) { "use strict"; var mySuperDupparClassOfSHKR=function(pValue){ var myPrivateValue; this.setValue=function(pValue){ myPrivateValue=pValue; return this; }; var __construct = function(that, pValue) { return that.setValue(pValue); }(this, pValue); }; exports.SuperDupparClass = { create : function(pValue) { if(typeof pValue==='undefined') throw 'please provide a value, unable to continue...'; return new mySuperDupparClassOfSHKR(pValue); }, }; })(this); Usage as […]
Install PHP-Redis on PHP5.6 Centos 7
Assume that PHP 5.6 installed and working properly. Now execute following command sudo yum install php56w-devel sudo yum install git-core git clone git:// cd phpredis/ sudo phpize sudo ./configure sudo make sudo make install sudo echo "">/etc/php.d/redis.ini sudo apachectl restart Its pretty simple!