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
@echo off | |
SET st3Path=C:\Program Files\Sublime Text 3\sublime_text.exe | |
rem add it for folders | |
@reg add "HKEY_CLASSES_ROOT\Directory\shell\Open with Sublime Text" /t REG_SZ /v "" /d "Open with Sublime Text" /f | |
@reg add "HKEY_CLASSES_ROOT\Directory\shell\Open with Sublime Text" /t REG_EXPAND_SZ /v "Icon" /d "%st3Path%,0" /f | |
@reg add "HKEY_CLASSES_ROOT\Directory\shell\Open with Sublime Text\command" /t REG_SZ /v "" /d "%st3Path% \"%%1\"" /f | |
pause |
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 | |
/** | |
* | |
* @author Saeedvir [ | |
* 'email' => '[email protected]', | |
* 'telegram' => 'https://t.me/PhpWebDeveloper' | |
* ] | |
* @usage : | |
$dataGenerator = new DataStructureGenerator('data', true,true); | |
$dataGenerator->setData('users', 8); |
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 | |
/** | |
* Standard API Response in PHP | |
* | |
* https://github.com/obiefy/api-response | |
* | |
* @author Saeedvir [ | |
* 'email' => '[email protected]', | |
* 'telegram' => 'https://t.me/PhpWebDeveloper' | |
* ] |
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
by: https://github.com/saeedvir | |
telegram : https://t.me/PhpWebDeveloper | |
============================================== | |
package : | |
https://github.com/spatie/laravel-medialibrary | |
("proc_open" function is disabled in shared host) | |
use this code in your model : |
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 | |
$to_store ='test-file.png'; | |
$img_data=null; | |
$fontSize = 20; | |
$imgWidth = 400; | |
$imgHeight = 80; | |
$angle = 0; | |
$font = 'font_name.ttf'; |
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
{"lastUpload":"2020-08-04T03:52:57.654Z","extensionVersion":"v3.4.3"} |
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
/* | |
** saeed abdollahian | |
** Freelance PHP developer & consultant. Laravel specialist. | |
** Freelance (available) | |
** https://t.me/PhpWebDeveloper | |
*/ | |
<?php | |
namespace App; | |
/* |
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 | |
class Debug { | |
/** | |
* A collapse icon, using in the dump_var function to allow collapsing | |
* an array or object | |
* | |
* @var string | |
*/ |
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
/* | |
* Laravel Route Or Controller | |
*/ | |
Route::post('tinymce-upload', function (Request $request) { | |
#Check For Upload (add your security !!!) | |
$fileName = request()->file('file')->getClientOriginalName(); | |
$path = request()->file('file')->storeAs('uploads', $fileName, 'public'); | |
return response()->json(['location' => "/storage/$path"]); |
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 | |
YourModel::updateOrCreate( | |
[ | |
'user_id' => '1', | |
'user_type' => 'admin' | |
], | |
[ | |
'user_id' => '1', | |
'user_type' => 'admin', | |
'value' => DB::raw('value + 1'), |
OlderNewer