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 | |
| namespace App\Exceptions; | |
| use Exception; | |
| use Symfony\Component\HttpKernel\Exception\HttpException; | |
| use Illuminate\Foundation\Exceptions\Handler as ExceptionHandler; | |
| class Handler extends ExceptionHandler | |
| { |
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
| In Blade.php | |
| {!! Form::open(['url' => 'product', 'method' => 'POST', 'class'=>'dropzone','id'=>'dropzone_file_upload']) !!} | |
| <!-- text input --> | |
| <div class="form-group"> | |
| <label>Product Title</label> | |
| <input type="text" required name="title" class="form-control" placeholder="Enter ..."> | |
| </div> | |
| <!-- textarea --> |
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
| public function fileView($id){ | |
| $photo_object =Notice::findOrFail($id); | |
| $headers = array('Content-Type' => 'pdf'); | |
| $response = \Response::download(public_path('notice_uploads/'.$photo_object->file), $photo_object->file, $headers); | |
| ob_end_clean(); | |
| return $response; | |
| } |
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
| Linux - create "Default (Linux).sublime-mousemap" in ~/.config/sublime-text-3/Packages/User | |
| Mac - create "Default (OSX).sublime-mousemap" in ~/Library/Application Support/Sublime Text 3/Packages/User | |
| Win - create "Default (Windows).sublime-mousemap" in %appdata%\Sublime Text 3\Packages\User | |
| [ | |
| { | |
| "button": "button1", | |
| "count": 1, | |
| "modifiers": ["ctrl"], | |
| "press_command": "drag_select", |
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
| if ($request->file('csv')->isValid()){ | |
| $csv = $request->file('csv'); | |
| $list_id = DB::table('list')->insertGetId(['list_name'=>$request->get('name'),'list_about'=>$request->get('about')]); | |
| if($list_id){ | |
| $csvContent = []; | |
| $file = fopen($csv->getRealPath(),"r"); | |
| while(!feof($file)) | |
| { |
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
| $csvContent = []; | |
| $file = fopen($csv->getRealPath(),"r"); | |
| while(!feof($file)) | |
| { | |
| // print_r(fgetcsv($file)); | |
| $content = fgetcsv($file); | |
| $csvContent[] = [ | |
| 'list_fullname' => $content[0], | |
| 'list_email' => $content[1] |
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
| Route::get('/csv', function() { | |
| $table = ApplyOnline::all(); | |
| $output = "Company Name,Company Address,Product Lineup,Name of Company Owner,Address of Company Owner,NID of Authorized Person,Company Trade License No,Company TIN No,Contact No,Repersentative,Email,Website\n"; | |
| $count= 0; | |
| foreach ($table as $data) { | |
| $output.= $data->companyname.","; | |
| $output.= $data->companyaddress.","; | |
| $output.= $data->lineup.","; | |
| $output.= $data->companyowner.","; |
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 | |
| if (!isset($_SESSION)) | |
| session_start(); // start Session, if not already started | |
| $filetxt = 'userson.txt'; // the file in which the online users /visitors are stored | |
| $timeon = 120; // number of secconds to keep a user online | |
| $sep = '^^'; // characters used to separate the user name and date-time | |
| $vst_id = '-vst-'; // an identifier to know that it is a visitor, not logged user | |
| // get the user name if it is logged, or the visitors IP (and add the identifier) | |
| $uvon = isset($_SESSION['uid']) ? $_SESSION['uid'] : $_SERVER['SERVER_ADDR'] . $vst_id; |
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 | |
| if (!isset($_SESSION)) | |
| session_start(); // start Session, if not already started | |
| $filetxt = APPPATH .'views/online_users/userson.txt'; // the file in which the online users /visitors are stored | |
| $timeon = 120; // number of secconds to keep a user online | |
| $sep = '^^'; // characters used to separate the user name and date-time | |
| $vst_id = '-vst-'; // an identifier to know that it is a visitor, not logged user | |
| $todate = date('Y-m-d'); |
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
| @extends('layouts.app') | |
| @section('content') | |
| <div class="container" id='todo2'> | |
| <div class="row"> | |
| <div class="col-md-8 col-md-offset-2"> | |
| <alert-success :alertmessage="alertMsg" v-if="success"></alert-success> | |
| <alert-danger :alertmessage="alertMsg" v-if="danger"></alert-danger> |
OlderNewer