{{ !empty($interest) ? 'Edit Attraction' : 'Add Attraction' }}
Back
{{ Form::select('location_id', $locations, old('location_id'), ['class' => 'form-control', 'placeholder' => 'Select Location']) }}
{{ Form::text('title', old('title'), ['class' => 'form-control','placeholder' => 'Title']) }}
@if($errors->has('title'))
{{ $errors->first('title') }}
@endif
{{ Form::select('status', [1 => 'Active', 0 => 'Inactive'], old("status"), ['class' => 'form-control']) }}
{{ Form::textarea('description', old('description'), ['class' => 'form-control ckeditor','placeholder' => 'Description/History', 'rows' => 4]) }}
{{ Form::textarea('info_description', old('info_description'), ['class' => 'form-control ckeditor','placeholder' => 'Information Description', 'rows' => 4]) }}
{{ Form::textarea('fdescription', old('fdescription'), ['class' => 'form-control ckeditor','placeholder' => 'Whats on Description', 'rows' => 4]) }}
{{ $errors->first('fdescription ') }}
@if($errors->has('interest_images'))
@endif
@php
$inc = 0;
@endphp
@if(isset($interest->interest_images) || old('interest_images'))
@php
$interest_images = old('interest_images') ? old('interest_images') : $interest->interest_images;
//dump($interest_images);die;
@endphp
@foreach ($interest_images as $key => $limage)
@php
if(!is_object($limage))
$limage = (object) $limage;
$idc = !empty($limage->id) ? $limage->id : $inc;
@endphp
- {{ $errors->first('interest_images') }}
Images
@if (old('interest_images.'.$key.'.image'))
@php
$filename = old('interest_images.'.$key.'.image');
if(old('interest_images.'.$key.'.id'))
$filepath = '/storage/interest/';
else
$filepath = "/storage/temp/";
@endphp
@else
@php
$filename = isset($limage->image) ? $limage->image : "";
$filepath = '/storage/interest/';
@endphp
@endif
@if(!empty($filename) && file_exists( public_path() . $filepath . $filename))
@php $imageurl=\App\Helpers\MenuHelpers::imageUrl(url($filepath. $filename),'274','180','100') @endphp
![]() |
{{ Form::textarea('interest_images['.$inc.'][caption]',old('interest_images.'. $inc .'.caption')?old('interest_images.'. $inc .'.caption'):$limage->caption,['class'=>'form-control' ,'placeholder'=>'Image Caption','rows'=>'4']) }} | {{ Form::select('interest_images['.$inc.'][image_type]',$image_type,old('interest_images.'. $inc .'.image_type')?old('interest_images.'. $inc .'.image_type'):$limage->image_type,['class'=>'form-control']) }} | @if(!empty($limage->id)) Remove @else Remove @endif |
Please Select Images and Upload |
@if($errors->has('interest_audios'))
@endif
- {{ $errors->first('interest_audios') }}
Audio
Audio file | Audio Type | Audio Description | ||
{!! Form::file('interest_audios['.$inc.'][audio]') !!} @if (old('interest_audios.'.$key.'audio')) @php $filename = old('interest_audios.'.$key.'.audio'); if(old('interest_audios.'.$key.'.id')) $filepath = '/storage/interest/'; else $filepath = "/storage/temp/"; @endphp @else @php $filename = isset($laudio->audio) ? $laudio->audio : ""; $filepath = '/storage/interest/'; @endphp @endif @if(!empty($filename) && file_exists( public_path() . $filepath . $filename)) {{ url($filepath. $filename)}} @endif {{ Form::hidden('interest_audios['.$inc.'][audio]','',['class'=>'form-control']) }} @if (isset($laudio->id) && !empty($laudio->id)) {{ Form::hidden('interest_audios['.$inc.'][id]',old('interest_audios.'.$inc.'.id')?old('interest_audios.'.$inc.'.id'):$laudio->id,['class'=>'form-control']) }} @endif | {{ Form::select('interest_audios['.$inc.'][image_type]',$image_type,old('interest_audios.'.$inc.'.image_type')?old('interest_audios.'. $inc .'.image_type'):$laudio->image_type,['class'=>'form-control']) }} | {{ Form::textarea('interest_audios['.$inc.'][audio_description]', old('interest_audios.'.$inc.'.audio_description.')?old('interest_audios.'.$inc.'.audio_description.'):$laudio->audio_description, ['class' => 'form-control ','placeholder' => 'Audio Description','rows'=>4]) }} | @if(!empty($laudio->id)) Remove @else Remove @endif | |
{!! Form::file('interest_audios['.$i.'][audio]') !!} | {{ Form::select('interest_audios['.$i.'][image_type]',$image_type,['class'=>'form-control']) }} | {{ Form::textarea('interest_audios['.$i.'][audio_description]','', ['class' => 'form-control','placeholder' => 'Audio Description','rows'=>'4']) }} | ||
@if($errors->has('interest_videos'))
@endif
- {{ $errors->first('interest_videos') }}
Videos
Video file | Youtube video Id | Video Type | ||
{!! Form::file('interest_videos['.$inc.'][video]') !!} @if (old('interest_videos.'.$key.'video')) @php $filename = old('interest_videos.'.$key.'.video'); if(old('interest_videos.'.$key.'.id')) $filepath = '/storage/interest/'; else $filepath = "/storage/temp/"; @endphp @else @php $filename = isset($lvideo->video) ? $lvideo->video : ""; $filepath = '/storage/interest/'; @endphp @endif @if(!empty($filename) && file_exists( public_path() . $filepath . $filename)) {{url($filepath. $filename)}} @endif {{ Form::hidden('interest_videos['.$inc.'][video]','',['class'=>'form-control']) }} @if (isset($lvideo->id) && !empty($lvideo->id)) {{ Form::hidden('interest_videos['.$inc.'][id]',old('interest_videos.'.$inc.'.id')?old('interest_videos.'.$inc.'.id'):$lvideo->id,['class'=>'form-control']) }} @endif | {{ Form::text('interest_videos['.$inc.'][video_id]',old('interest_videos.'. $inc .'.video_id')?old('interest_videos.'. $inc .'.video_id'):$lvideo->video_id,['class'=>'form-control','placeholder'=>'Youtube Video Id']) }} | {{ Form::select('interest_videos['.$inc.'][image_type]',$image_type,old('interest_videos.'. $inc .'.image_type')?old('interest_videos.'. $inc .'.image_type'):$lvideo->image_type,['class'=>'form-control']) }} | @if(!empty($lvideo->id)) Remove @else Remove @endif | |
{!! Form::file('interest_videos['.$i.'][video]') !!} | {{ Form::text('interest_videos['.$i.'][video_id]',old('interest_videos.'. $i .'.video_id')?old('interest_videos.'. $i .'.video_id'):'',['class'=>'form-control','placeholder'=>'Youtube Video Id']) }} | {{ Form::select('interest_videos['.$i.'][image_type]',$image_type,old('interest_videos.'. $i .'.image_type')?old('interest_videos.'. $i .'.image_type'):'',['class'=>'form-control']) }} | ||
{{ Form::hidden('video_count',$count_video) }} |