{{ html()->form('POST', route('landing_page_settings_updates'))->attribute('enctype', 'multipart/form-data')->attribute('data-toggle', 'validator')->id('frontend_setting')->open() }} {{ html()->hidden('id', $landing_page->id)->class('form-control')->placeholder('id') }} {{ html()->hidden('type', $tabpage)->class('form-control')->placeholder('id') }}
status == 1 ? 'checked' : '' }}>
@include('partials._language_toggale') @foreach ($language_array as $language)
@php $title_key = 'title'; $description_key = 'description'; $title_value = $language['id'] == 'en' ? $landing_page->$title_key ?? '' : $landing_page->translate($title_key, $language['id']) ?? ''; $description_value = $language['id'] == 'en' ? $landing_page->$description_key ?? '' : $landing_page->translate($description_key, $language['id']) ?? ''; $title_name = $language['id'] == 'en' ? $title_key : "translations[{$language['id']}][$title_key]"; $description_name = $language['id'] == 'en' ? $description_key : "translations[{$language['id']}][$description_key]"; @endphp
{{ html()->label(trans('messages.title') . ' *', 'title')->class('form-control-label') }} {{ html()->text($title_name, old($title_name, $title_value))->id('title_' . $language['id'])->placeholder(trans('messages.title'))->class('form-control') }}
{{ html()->label(trans('messages.description') . ' *', 'description')->class('form-control-label') }} {{ html()->textarea($description_name, old($description_name, $description_value))->id('description_' . $language['id'])->placeholder(trans('messages.description'))->class('form-control textarea')->rows(2) }}
@endforeach
{{ html()->label(trans('messages.url') . ' *', 'url')->class('form-control-label') }} {{ html()->text('url', old('url'))->id('url')->class('form-control')->placeholder(trans('messages.url')) }}
{{ html()->file('vimage')->class('custom-file-input custom-file-input-sm detail')->id('vimage')->attribute('lang', 'en')->attribute('accept', 'image/*')->attribute('onchange', 'preview()') }} @if ($landing_page && getMediaFileExit($landing_page, 'vimage')) @else @endif
@if ($landing_page && $landing_page->value != null) @php $landingPageValue = json_decode($landing_page->value, true); @endphp @foreach ($landingPageValue['subtitle'] as $index => $subtitle)
@if (isset($landingPageValue['subtitle'][$index]) || $landingPageValue['subdescription'][$index])
{{ html()->label(__('messages.subtitle'), 'subtitle')->class('form-control-label') }} {{ html()->text("subtitle[$index]", is_array($subtitle) ? $subtitle[0] : $subtitle)->id("subtitle_$index")->class('form-control')->placeholder(trans('messages.subtitle'))->required() }}
{{ html()->label(__('messages.subdescription'), 'subdescription')->class('form-control-label') }} {{ html()->textarea("subdescription[$index]", is_array($landingPageValue['subdescription'][$index]) ? $landingPageValue['subdescription'][$index][0] : $landingPageValue['subdescription'][$index])->id('subdescription_' . $index)->class('form-control textarea')->rows(2)->placeholder(trans('messages.subdescription'))->required() }}
@endif
@endforeach @endif
{{ html()->submit(__('messages.save'))->class('btn btn-md btn-primary float-md-end submit_section1') }} {{ html()->form()->close() }}