Install two (02) Bower packages like jquery 2.2.4 and pickadate 3.5.6 with Composer configuration for Yii2 project
$ curl -sS https://getcomposer.org/installer | php
$ sudo mv composer.phar /usr/local/bin/composer
1. goto view , change $form and add field to input file | |
<?php $form = ActiveForm::begin(['options'=>['enctype'=>'multipart/form-data']]); ?> | |
... | |
<?= $form->field($model,'image)->fileInput() ?> <!-- field to input file --> | |
... | |
<?= ActiveForm::end() ?> | |
-- show running queries (>= 9.2) | |
SELECT pid, | |
age(clock_timestamp(), query_start) AS age, | |
usename, state, query, waiting, | |
age(clock_timestamp(), xact_start) AS xact_age | |
FROM pg_stat_activity | |
WHERE state != 'idle' | |
AND query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY age DESC; |
# membuat perulangan | |
# 10 | |
# 9 | |
# ... | |
# 1 | |
for a in range(10,0,-1): | |
print a | |
1. Sediakan gambar yang akan digunakan sebagai background | |
2. buka folder /usr/share/gnome-shell/theme | |
3. Buka file gdm3.css | |
4. Tekan ctrl+w kemudian input #lockDialogGroup | |
5. Ganti url background dengan gambar yang tadi telah di sediakan |
$ python sqlmap.py -u "http://192.168.21.128/sqlmap/mysql/get_int.php?id=1" -z "ign,flu,bat" --banner -f | |
sqlmap/1.0-dev-7614c81 - automatic SQL injection and database takeover tool | |
http://sqlmap.org | |
[!] legal disclaimer: Usage of sqlmap for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program | |
[*] starting at 10:30:49 | |
[10:30:49] [INFO] testing connection to the target url |
<?PHP | |
/** | |
* Spintax - A helper class to process Spintax strings. | |
* @name Spintax | |
* @author Jason Davis - https://www.codedevelopr.com/ | |
* Tutorial: https://www.codedevelopr.com/articles/php-spintax-class/ | |
*/ | |
class Spintax | |
{ | |
public function process($text) |
Install two (02) Bower packages like jquery 2.2.4 and pickadate 3.5.6 with Composer configuration for Yii2 project
$ curl -sS https://getcomposer.org/installer | php
$ sudo mv composer.phar /usr/local/bin/composer
<?php | |
namespace common\models; | |
use Yii; | |
use \common\models\base\ModuleBank as BaseModuleBank; | |
class ModuleBank extends BaseModuleBank | |
{ | |
... |
<?php | |
use yii\helpers\Html; | |
use kartik\export\ExportMenu; | |
use kartik\grid\GridView; | |
use yii\helpers\Url; | |
... | |
<div class="module-materi-index"> | |
<div class="box box-success"> | |
<div class="box-header"> | |
... |
# Created function to convert num to roman | |
def dec2rom(num): | |
_m = int(num / 1000) | |
num = num % 1000 | |
# | |
_d = int(num / 500) | |
num = num % 500 | |
# | |
_c = int(num / 100) |