Posts

[JS] Check select2 jquery plugin loaded or not

Image
Read How to async defer CSS JS perfectly if (jQuery.fn.select2) { //jquery select2 loaded or not false or not undefined => return array jQuery.fn.select2.defaults.set( "theme", "bootstrap" ); //then select themes } Example: How to change select2 jQuery plugin using jQuery.val() $('#mySelect2').val('US'); // Change the value or make some change to the internal state if (jQuery.fn.select2) { $('#mySelect2').trigger('change.select2'); // Notify only Select2 of changes }

Create Folder Recursive PHP

Image
How to automatically create folder if not exists on spesific PATH Bagaimana cara membuat folder secara rekursif bila tidak ada pada spesifik PATH <?php // define document root first define document root dahulu define('APP', $_SERVER['DOCUMENT_ROOT'], true); // [func] path extraction and creation function _folder_($d){ $d = str_replace(APP, '', rtrim($d, '/')); $explode = explode('/', rtrim($d,'/')); $explode = array_filter($explode); $ready = (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN' ? '' : '/'); foreach ($explode as $x) { $ready = rtrim($ready,'/'); $ready .= '/'.$x; $status = file_exists(APP.$ready); if ($status === false){ mdir(APP.$ready); } } return $d; } // [func] create folder permission 777 function mdir($x) { $oldmask = umask(0); mkdir($x, 0777); umask($oldmask); } // Usage Penggunaan $folder_target = ?

Cygwin In Context Menus

Image
How might I make a Cygwin alternate way that will open Cygwin at a particular envelope? This would hinder composing cd disc/cygdrive/c/Users/Tom/Desktop/ each time I dispatch Cygwin. When you introduce Cygwin (or in the event that you've just introduced it, download it again and begin setup again to run an update), ensure that you select the chere bundle under the "Shells" classification. After Cygwin is launched, open Cygwin terminal and type command: chere -i -t mintty -s bash Presently you bought to have "Bash Prompt Here" in the Windows right-click setting menu. ( mintty is Cygwin's default terminal. If you don't choose it with the -t option, your "Bash Prompt Here" will use the same terminal as the Windows Command Prompt, which prevents horizontal resizing.)

Simontok Update Terbaru 19 Juni 2019

Download Si montok terbaru Si montok update 2019 Si montok update juni 2019 Si montok mod 2019

5 Ekstensi VSCode Teratas untuk Pengembangan JavaScript yang Efisien

Image
Ekstensi adalah sumber daya eksternal yang membantu Anda meningkatkan kemampuan bawaan VSCode. Dalam posting ini, kita melihat 5 ekstensi teratas untuk meningkatkan keterampilan pengembangan JavaScript kita. Salah satu hal paling luar biasa tentang Visual Studio Code adalah kemampuan untuk meningkatkan kemampuannya dengan penambahan ekstensi eksternal. Namun, ada banyak ekstensi di pasar. Dalam pos ini, kami akan membahas 5 ekstensi teratas yang secara drastis akan meningkatkan pengembangan JavaScript Anda di VS Code. ESLint ESLint adalah alat linter pluggable dan dapat dikonfigurasi untuk mengidentifikasi dan melaporkan pola pengembangan dalam JavaScript. Ini membantu Anda menjaga kualitas dan struktur kode Anda dengan mudah. Menambahkan ekstensi ini ke VSCode akan membantu Anda memformat kode Anda secara otomatis, menegakkan kode yang lebih bersih, terstruktur dengan baik, dan konsisten. Debugger untuk Chrome Debugger untuk Chrome adalah ekstensi VS Code yang digunakan unt

Chrome Allow Localhost SSL XAMPP

Image
Input into chrome address bar : chrome://flags/#allow-insecure-localhost enable it, then restart the chrome browser. seems like this :

Sublime Text 3 Shortcut Open Folder

open folder with sublime text 3