/
var
/
www
/
flurhymez
/
resources
/
views
/
admin
/
testimonials
/
/var/www/flurhymez/resources/views/admin/testimonials
mkdir
upload
Name
Size
Mode
Actions
add.blade.php
8171
0644
edit
dl
rm
edit.blade.php
8851
0644
edit
dl
rm
listing.blade.php
3610
0644
edit
dl
rm
Edit:
/var/www/flurhymez/resources/views/admin/testimonials/edit.blade.php
(8851B)
@extends('admin.layout.app') @section('title', $testimonial->name) @section('actions') <button type="submit" class="btn btn-success" form="testimonialForm"><i class="fa fa-save mr-1"></i>{{ __('admin.buttons.save_changes') }}</button> @endsection @section('js') <script> var getImageData = function(input, imgPreviewPlaceholder) { if (input.files) { var filesAmount = input.files.length; for (i = 0; i < filesAmount; i++) { var reader = new FileReader(); reader.onload = function(event) { //console.log(event.target); $($.parseHTML('<img class="img-preview mr-4">')).attr('src', event.target.result).appendTo( imgPreviewPlaceholder); } $('#selectedImageName').append(input.files[i]['name'] + ' '); reader.readAsDataURL(input.files[i]); } } }; </script> @endsection @section('content') <section class="page-content testimonials"> <form id="testimonialForm" action="{{ route('testimonials.update', ['id' => $testimonial->id]) }}" method="POST" enctype="multipart/form-data"> @csrf @if ($errors->any()) <div class="alert alert-danger mb-3"> <ul> @foreach ($errors->all() as $error) <li>{{ $error }}</li> @endforeach </ul> </div> @endif <div class="card card-small mb-4"> <div class="card-header"> {{ __('admin.testimonials.testimonial_image') }} </div> <div class="card-body"> <div class="form-row"> <div class="form-group col-md-6"> <div id="selectedImage"> @foreach ($testimonial->getMedia('testimonials') as $image) <img src="{{ asset($image->getUrl()) }}" class="img-preview mr-3"> @endforeach </div> <div class="custom-file mb-3"> <input onchange="getImageData(this, '#selectedImage')" type="file" name="image" class="custom-file-input" id="customFile" lang="{{ app()->getLocale() }}"> <label id="selectedImageName" class="custom-file-label" for="customFile"> @foreach ($testimonial->getMedia('testimonials') as $image) {{ $image->name }} @endforeach </label> </div> </div> </div> </div> </div> <div class="card card-small mb-4"> <div class="card-header"> {{ __('admin.testimonials.testimonial_name') }} </div> <div class="card-body"> <div class="form-row"> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_name_en') }}</label> <input type="text" name="name_en" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_name_en') }}" value="{{ $testimonial->getTranslation('name', 'en') }}"> </div> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_name_ar') }}</label> <input type="text" name="name_ar" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_name_ar') }}" value="{{ $testimonial->getTranslation('name', 'ar') }}"> </div> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_name_tr') }}</label> <input type="text" name="name_tr" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_name_tr') }}" value="{{ $testimonial->getTranslation('name', 'tr') }}"> </div> </div> </div> </div> <div class="card card-small mb-4"> <div class="card-header"> {{ __('admin.testimonials.testimonial_position') }} </div> <div class="card-body"> <div class="form-row"> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_position_en') }}</label> <input type="text" name="position_en" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_position_en') }}" value="{{ $testimonial->getTranslation('position', 'en') }}"> </div> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_position_ar') }}</label> <input type="text" name="position_ar" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_position_ar') }}" value="{{ $testimonial->getTranslation('position', 'ar') }}"> </div> <div class="form-group col-md-4"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_position_tr') }}</label> <input type="text" name="position_tr" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_position_tr') }}" value="{{ $testimonial->getTranslation('position', 'tr') }}"> </div> </div> </div> </div> <div class="card card-small mb-4"> <div class="card-header"> {{ __('admin.testimonials.testimonial_description') }} </div> <div class="card-body"> <div class="form-row"> <div class="form-group col-12"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_description_en') }}</label> <textarea name="description_en" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_description_en') }}" rows="3">{{ $testimonial->getTranslation('description', 'en') }}</textarea> </div> <div class="form-group col-12"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_description_ar') }}</label> <textarea name="description_ar" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_description_ar') }}" rows="3">{{ $testimonial->getTranslation('description', 'ar') }}</textarea> </div> <div class="form-group col-12"> <label class="font-sm text-gray">{{ __('admin.testimonials.testimonial_description_tr') }}</label> <textarea name="description_tr" class="form-control form-control-lg" placeholder="{{ __('admin.testimonials.testimonial_description_tr') }}" rows="3">{{ $testimonial->getTranslation('description', 'tr') }}</textarea> </div> </div> </div> </div> </form> </section> @endsection
Save
@extends('admin.layout.app') @section('title', $testimonial->name) @section('actions')
{{ __('admin.buttons.save_changes') }}
@endsection @section('js') @endsection @section('content')
@csrf @if ($errors->any())
@foreach ($errors->all() as $error)
{{ $error }}
@endforeach
@endif
{{ __('admin.testimonials.testimonial_image') }}
@foreach ($testimonial->getMedia('testimonials') as $image)
@endforeach
@foreach ($testimonial->getMedia('testimonials') as $image) {{ $image->name }} @endforeach
{{ __('admin.testimonials.testimonial_name') }}
{{ __('admin.testimonials.testimonial_name_en') }}
{{ __('admin.testimonials.testimonial_name_ar') }}
{{ __('admin.testimonials.testimonial_name_tr') }}
{{ __('admin.testimonials.testimonial_position') }}
{{ __('admin.testimonials.testimonial_position_en') }}
{{ __('admin.testimonials.testimonial_position_ar') }}
{{ __('admin.testimonials.testimonial_position_tr') }}
{{ __('admin.testimonials.testimonial_description') }}
{{ __('admin.testimonials.testimonial_description_en') }}
{{ $testimonial->getTranslation('description', 'en') }}
{{ __('admin.testimonials.testimonial_description_ar') }}
{{ $testimonial->getTranslation('description', 'ar') }}
{{ __('admin.testimonials.testimonial_description_tr') }}
{{ $testimonial->getTranslation('description', 'tr') }}
@endsection