Category : laravel-blade

I want to change input type password ,placeholder value.When i updated the placeholder value it’s not showing .But it shows only the previous placeholder value.When page loading,it will show the new placeholder (1second) and then again switched into the previous value. <div class="input-with-icon-left"> <i class="icon-material-outline-lock"></i> <input type="password" class="input-text with-border" {{ (isset($customer) ? ” : ‘required’) ..

Read more

I’ve been trying to implement a blade component that includes its own javascript in my case I have a blade component named: DashboardLongStatWidget with an ApexChart in it when calling the blade component it only loads the first chart and ignores the second chart even though I have set the jQuerySelector to dynamically look for ..

Read more

I am using laravel-7. I am making a job site,where applicant can upload resume (pdf) and company can view the pdf from laravel view page. I uploaded the file successful. But I am unable to view the pdf in view page. code: <td> {{$applicant_details->resume }} <iframe src="{{asset(‘resume/’.$applicant_details->resume) }}" width=”100%” height=”100%”> This browser does not support ..

Read more

There is page where i submit id and then middleware checks if it’s right and the redirects to another route. Middleware works good but, i can’t get messages in my blades. middleware: public function handle($request, Closure $next) { $exists =Kuponas::where(‘id’, $request->id)->exists(); if (!$exists) { return Redirect::to(url(‘/’))->with(‘pin’,’Duomenys neteisingi, patikrinkite ‘); } return $next($request); } Blade: @error(‘pin’) ..

Read more

i am using laravel. i am trying to create a badge in the navbar and getting the number of rows from a specific table in the database. i have the following codes for the navbar: @php !empty(session(‘notifications.all2’)) ? print(array_sum(session(‘notifications.all2’))) : "" @endphp and this for the controller: class NotificationsController extends Controller { public function index ..

Read more

I’m trying to mark as selected, an option of a select element, but they are all being selected. BLADE HTML <h1>value = {{ $entity->field ?? ‘this is new’ }}</h1> <select name="field"> <option value="option_a" @if ($entity->field ?? ” == ‘option_a’) selected="selected" @endif>Option A</option> <option value="option_b" @if ($entity->field ?? ” == ‘option_b’) selected="selected" @endif>Option B</option> <option value="option_c" ..

Read more

So i have this project on React and Laravel and i’m trying to use some React components that i already have on a Laravel blade. And the view is rendering just fine but the components are not. This is my laravel blade view, called policies.blade.php: @extends(‘agencies.layout.app’) @section(‘content’) <p>Hello</p> <div id="app-policies"> </div> <div id="Policies"> </div> <div ..

Read more

I am using laravel 7. For excel download I am using laravel excel ( documentation: https://docs.laravel-excel.com/3.1/getting-started/) but It only downloading the data in xlsx file, there is no column heading. I want column heading with the data. UserExport file in App/Exports public function collection() { $user=DB::table(‘admin’)->get(); return $user; } controller function: public function export() { ..

Read more

Route::group([‘middleware’ =>’auth’], function(){ Route::prefix(‘/user/’)->group(function(){ Route::get(‘galleries/create’, [GalleryController::class, ‘gallerycreate’])->name(‘galleryCreate’); Route::post(‘galleries/store’, [GalleryController::class, ‘gallerystore’])->name(‘galleryStore’); }); <div class="card-header">Create New Gallery</div> <div class="card-body"> <form action=" {{ route(‘galleryStore’) }}" method="POST" enctype="multipart/form-data"> {{ csrf_field() }} @csrf <div class="row"> <div class="col-md-12"> <label for="description">Gallery Description</label> <textarea name="description" rows="3" class="form-control"></textarea> </div> </div> <br> <button class="btn btn-primary" type="submit">Create Gallery</button> </form> </div> Sourc..

Read more

I’m new with Laravel and I found this confusing error when try to display array inside array into table. I want to display this but it give error Undefined, Here my Controller public function table() { $coin = DB::table(‘data’)->groupBy(‘coin’)->take(10)->get(); foreach($coin as $c){ $btc = DB::table(‘data’)->where(‘coin’,$c->coin)->where(‘pair’,’BTC’)->get(); $data[] = [ ‘coin’ => $c->coin, ‘btc’ => $btc ]; ..

Read more