관리-도구
편집 파일: 9166147b3ed651237b5ebb3609325774e5507e22.php
<?php $__env->startPush('styles'); ?> <style> .imgPreview img { padding: 8px; max-width: 150px; } </style> <?php $__env->stopPush(); ?> <?php $__env->startSection('content'); ?> <!-- Content Wrapper. Contains page content --> <div class="content-wrapper"> <!-- Content Header (Page header) --> <div class="content-header"> <div class="container-fluid"> <div class="row mb-2"> <div class="col-sm-6"> <h1 class="m-0">Create an Album <a href="<?php echo e(route('album.index')); ?>" class="btn btn-primary">View Albums</a></h1> </div><!-- /.col --> <div class="col-sm-6"> <ol class="breadcrumb float-sm-right"> <li class="breadcrumb-item"><a href="<?php echo e(route('dashboard')); ?>">Home</a></li> <li class="breadcrumb-item active">Albums</li> </ol> </div><!-- /.col --> </div><!-- /.row --> </div><!-- /.container-fluid --> </div> <!-- /.content-header --> <!-- Main content --> <section class="content"> <div class="container-fluid"> <?php if(session('success')): ?> <div class="col-sm-12"> <div class="alert alert-success alert-dismissible fade show" role="alert"> <?php echo e(session('success')); ?> <button type="button" class="close" data-dismiss="alert" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> </div> <?php endif; ?> <?php if(session('error')): ?> <div class="col-sm-12"> <div class="alert alert-danger alert-dismissible fade show" role="alert"> <?php echo e(session('error')); ?> <button type="button" class="close" data-dismiss="alert" aria-label="Close"> <span aria-hidden="true">×</span> </button> </div> </div> <?php endif; ?> <div class="row"> <div class="col-md-12"> <div class="card"> <div class="card-body"> <form action="<?php echo e(route('album.store')); ?>" method="POST" enctype="multipart/form-data"> <?php echo csrf_field(); ?> <?php echo method_field("POST"); ?> <div class="row"> <div class="col-md-6"> <div class="form-group"> <label for="album_cover">Album Cover:</label> <div class="input-group"> <span class="input-group-btn"> <a id="lfm" data-input="thumbnail" data-preview="holder" class="btn btn-primary"> <i class="fa fa-picture-o"></i> Choose </a> </span> <input id="thumbnail" class="form-control" type="text" name="album_cover" value="<?php echo e(old('album_cover')); ?>"> </div> <img id="holder" style="margin-top:15px;max-height:100px;"> <?php $__errorArgs = ['album_cover']; $__bag = $errors->getBag($__errorArgs[1] ?? 'default'); if ($__bag->has($__errorArgs[0])) : if (isset($message)) { $__messageOriginal = $message; } $message = $__bag->first($__errorArgs[0]); ?> <span class="text-danger"><?php echo e($message); ?></span> <?php unset($message); if (isset($__messageOriginal)) { $message = $__messageOriginal; } endif; unset($__errorArgs, $__bag); ?> </div> </div> <div class="col-md-6"> <div class="form-group"> <label for="Album Title">Album Title (In english):</label> <input type="text" class="form-control" name="album_title[en]" placeholder="Enter Album Title"> <p class="text-danger"> <?php echo e($errors->first('album_title')); ?> </p> </div> </div> <div class="col-md-6"> <div class="form-group"> <label for="Album Title">Album Title (In nepali):</label> <input type="text" class="form-control" name="album_title[np]" placeholder="Enter Album Title"> <p class="text-danger"> <?php echo e($errors->first('album_title')); ?> </p> </div> </div> <div class="col-md-12 text-center"> <hr> <h3>Meta Information</h3> <hr> </div> <div class="col-md-6"> <div class="form-group"> <label for="meta_title">Meta Title(Optional): </label> <input type="text" class="form-control" name="meta_title" placeholder="Meta Title for SEO" value=""> <p class="text-danger"> <?php echo e($errors->first('meta_title')); ?> </p> </div> </div> <div class="col-md-6"> <div class="form-group"> <label for="meta_keywords">Meta Keywords(Optional): </label> <input type="text" class="form-control" name="meta_keywords" placeholder="Meta Keywords for SEO" value=""> <p class="text-danger"> <?php echo e($errors->first('meta_keywords')); ?> </p> </div> </div> <div class="col-md-12"> <div class="form-group"> <label for="meta-description">Meta Description (optional):</label> <textarea name="meta_description" cols="30" rows="5" class="form-control" placeholder="Meta description.."></textarea> </div> </div> <div class="col-md-6"> <div class="form-group"> <label for="og_image">OG Image (1200 X 600): </label> <div class="input-group"> <span class="input-group-btn"> <a id="lfm1" data-input="thumbnail1" data-preview="holder" class="btn btn-primary"> <i class="fa fa-picture-o"></i> Choose </a> </span> <input id="thumbnail1" class="form-control" type="text" name="og_image" value="<?php echo e(old('og_image')); ?>"> </div> <img id="holder" style="margin-top:15px;max-height:100px;"> <?php $__errorArgs = ['og_image']; $__bag = $errors->getBag($__errorArgs[1] ?? 'default'); if ($__bag->has($__errorArgs[0])) : if (isset($message)) { $__messageOriginal = $message; } $message = $__bag->first($__errorArgs[0]); ?> <span class="text-danger"><?php echo e($message); ?></span> <?php unset($message); if (isset($__messageOriginal)) { $message = $__messageOriginal; } endif; unset($__errorArgs, $__bag); ?> </div> </div> <div class="col-md-12 text-center"> <hr> <h3>Album Images</h3> <hr> </div> <div class="col-md-6"> <div class="form-group"> <label for="album_images">Select album images (Multiple images can be selected):</label> <div class="input-group"> <span class="input-group-btn"> <a id="lfm2" data-input="thumbnail2" data-preview="holder" class="btn btn-primary"> <i class="fa fa-picture-o"></i> Choose </a> </span> <input id="thumbnail2" class="form-control" type="text" name="album_images" value="<?php echo e(old('album_images', @$album->album_images)); ?>"> </div> <img id="holder" style="margin-top:15px;max-height:100px;"> <?php $__errorArgs = ['album_images']; $__bag = $errors->getBag($__errorArgs[1] ?? 'default'); if ($__bag->has($__errorArgs[0])) : if (isset($message)) { $__messageOriginal = $message; } $message = $__bag->first($__errorArgs[0]); ?> <span class="text-danger"><?php echo e($message); ?></span> <?php unset($message); if (isset($__messageOriginal)) { $message = $__messageOriginal; } endif; unset($__errorArgs, $__bag); ?> </div> </div> </div> <div class="col-md-12 user-image mb-3 text-center"> <div class="imgPreview"> </div> </div> <div class="col-md-12"> <button type="submit" class="btn btn-success">Submit</button> </div> </div> </form> </div> </div> </div> </div> </div> </section> <!-- /.content --> </div> <!-- /.content-wrapper --> <?php $__env->stopSection(); ?> <?php $__env->startPush('scripts'); ?> <script> var loadCover = function(event) { var output = document.getElementById('album_cover_output'); output.src = URL.createObjectURL(event.target.files[0]); output.onload = function() { URL.revokeObjectURL(output.src) } }; </script> <!-- jQuery --> <script> $(function() { // Multiple images preview with JavaScript var multiImgPreview = 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) { $($.parseHTML('<img>')).attr('src', event.target.result).appendTo(imgPreviewPlaceholder); } reader.readAsDataURL(input.files[i]); } } }; $('#images').on('change', function() { multiImgPreview(this, 'div.imgPreview'); }); }); </script> <script> var loadOg = function(event) { var output = document.getElementById('current_og'); output.src = URL.createObjectURL(event.target.files[0]); output.onload = function() { URL.revokeObjectURL(output.src) } }; </script> <Script> $(document).ready(function(){ $('#lfm').filemanager('image'); $('#lfm1').filemanager('image'); $('#lfm2').filemanager('image'); }); </Script> <?php $__env->stopPush(); ?> <?php echo $__env->make('backend.layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home2/nepaldsdforg/public_html/resources/views/backend/album/create.blade.php ENDPATH**/ ?>