How to Fix Let’s Encrypt ACME v1 Disabled

Let’s Encrypt is popular free SSL service. My VPS which is using Virtualmin was unable to use Let’s Encrypt and throw an error “ACME v1 disabled”. To fix this problem, execute the following line in terminal: apt-get install socat certbot certbot register After that, complete the register with a valid e-mail address and try to…

Yii2 Custom Action Button

Use the following format code to make custom action button in Gridview: [ ‘class’ => ‘yii\grid\ActionColumn’, ‘header’ => ‘Actions’, ‘headerOptions’ => [‘style’ => ‘color:#337ab7’], ‘template’ => “{update} {print} {delete}”, ‘buttons’ => [ ‘view’ => function ($url, $model) { return Html::a(‘<span class=”glyphicon glyphicon-eye-open”></span>’, $url, [ ‘title’ => Yii::t(‘app’, ‘lead-view’), ]); }, ‘update’ => function ($url, $model) { return…

How to Create Bandwidth Usage Script on Linux

Using a tool called iftop we can monitor bandwidth usage via command line on Linux. But here we will create our own shell script to monitor bandwidth usage. The idea is to read rx_bytes and tx_bytes files inside /sys/class/net/[interface]/statistics/ folder. Create netspeed script in /usr/local/bin/ and copy and paste below script. Script content: Exit nano…

How to Check System Uptime on Windows

On Linux operating system, we can use command top to show system statistic, running processes, and uptime. How can we do it on Windows environment? Using Windows operating system, the similar to top command is net statistics server. Execute this command in command prompt will show summary of  Windows system statistic including when the system…

How to Update Twitter Timeline Using PHP

Guide on this article can be used to post Twitter using PHP. First of all, download source code from http://phpfashion.com/twitter-for-php. Extract downloaded file to your folder. Example: /public_html/twitter-php/. Then we create index.php file with the following code: The first line is to setup variables: username, password, and message. And the next part is to setup…