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 | |
/** | |
* This script checks for security updates in the server and | |
* it's expected to be scheduled for a daily run. | |
* | |
* It will notify the $notify address if one or more security | |
* package updates are found. | |
*/ |
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 | |
/** | |
* Echo colored strings in the terminal (PHP-CLI). | |
* @use Colors::write("hello word!", "green", "light_green"); | |
*/ | |
class Colors | |
{ | |
/** @var array */ |
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 | |
public function uploadFileFromBlobString($base64string = '', $file_name = '', $folder = '') | |
{ | |
$file_path = ""; | |
$result = 0; | |
// Convert blob (base64 string) back to PDF | |
if (!empty($base64string)) { | |
$base64data = base64_decode($base64string, true); |
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 | |
public function uploadFileFromBlobString($base64string = '', $file_name = '', $folder = '') | |
{ | |
$file_path = ""; | |
$result = 0; | |
// Convert blob (base64 string) back to PDF | |
if (!empty($base64string)) { |
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
getFileInfo(evt: any): void { | |
const reader: FileReader = new FileReader(); | |
const files: Array<any> = evt.target.files || evt.dataTransfer.files; | |
reader.addEventListener( | |
'load', | |
() => { | |
this.form.file_path = reader.result; | |
}, | |
false |
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
{ | |
"env": { | |
"browser": true, | |
"node": true, | |
"jquery": true | |
}, | |
"extends": ["airbnb-base"], | |
"rules": { | |
"arrow-parens": ["error", "always"], | |
"camelcase": "off", |