This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| $str = preg_replace_callback( | |
| '!s:(\d+):"(.*?)";!', | |
| function($m) { | |
| return 's:'.strlen($m[2]).':"'.$m[2].'";'; | |
| }, | |
| $str); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <script> | |
| function sortObj(list, key) { | |
| function compare(a, b) { | |
| a = a[key]; | |
| b = b[key]; | |
| var type = (typeof(a) === 'string' || | |
| typeof(b) === 'string') ? 'string' : 'number'; | |
| var result; | |
| if (type === 'string') result = a.localeCompare(b); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| function sortDescObj(list, key) { | |
| var sortedKeys = Object.keys(list).sort(function(a,b) { | |
| return list[a][key] > list[b][key] ? -1:1 | |
| }); | |
| var newObjectSort = [] | |
| var tem=[] | |
| for (let index = 0; index < sortedKeys.length; index++) { | |
| tem=[] | |
| newObjectSort.push(list[sortedKeys[index]]) | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| //update from https://datatables.net/forums/discussion/44562/datatables-1-10-with-codeigniter-3-1-5 | |
| class DataTables | |
| { | |
| protected $CI; | |
| private $database; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #need install package https://aur.archlinux.org/packages/yuicompressor | |
| #yum install yuicompressor | |
| #!/bin/bash | |
| #Minify CSS | |
| input='script/css/bbk_interactive/index.css'; | |
| output='script/css/bbk_interactive/index.min.css'; | |
| yuicompressor $input > $output | |
| echo 'Minified' $input '-->' $output; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| RewriteEngine On | |
| ErrorDocument 404 /images/mywebsite/404.php |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * | |
| * TextExport 1.3 - by Bramus! - http://www.bram.us/ | |
| * text layer style export added by Max Glenister (@omgmog) http://www.omgmog.net | |
| * | |
| * v 1.x - ????.??.?? - UPD: HTML Output (?) | |
| * v 1.3 - 2008.03.16 - UPD: Base rewrite, now gets all layers (sets & regular ones) in one variable. | |
| * - ADD: Layer Path & Layer Name in export | |
| * - ADD: Cycle Multiple Files | |
| * v 1.2 - 2008.03.11 - User friendly version Added filesave dialog (*FIRST RELEASE*) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| //php .\get_param.php 123 | |
| if (php_sapi_name() === "cli") { | |
| var_dump($argv[1]); | |
| }else{ | |
| exit('Not allow'); | |
| } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <title>Bootstrap Example</title> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1"> | |
| <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css"> | |
| <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/jquery.slim.min.js"></script> | |
| <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js"></script> | |
| <script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js"></script> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const mix = require('laravel-mix'); | |
| /* | |
| |-------------------------------------------------------------------------- | |
| | Mix Asset Management | |
| | https://laravel-mix.com/docs/6.0/what-is-mix | |
| |-------------------------------------------------------------------------- | |
| | npm install laravel-mix@latest --save-dev | |
| | npm run dev | |
| | npm run production |