@extends('layouts.master')

@section('title')
    SPORTPESA | Image Advertisement
@endsection
@section('page')
    New Ads
@endsection
@section('content')
    <div class="col">
        <br>
        <?php
        $date = new dateTime();
        $d = $date->format('j F, Y');
        ?>
        @if(isset($success))
            <script>
                alert('{{$success}}');
            </script>
        @endif

        <form action="{{route('/newAds')}}" method="POST" id="adsForm" enctype="multipart/form-data">
            <div class="row">
            <div class="col-md-4">
                <div class="col-sm-8 col-md-offset-2">
                    <label>ADs IMAGE</label>
                    <div class="fileupload fileupload-new" data-provides="fileupload">
                        <div class="fileupload-new thumbnail" style="width: 250px; height: 150px;"><img src="{{asset('images/demoUpload.jpg')}}" alt="" /></div>
                        <div class="fileupload-preview fileupload-exists thumbnail" style="max-width: 160px; max-height: 150px; line-height: 20px;"></div>
                        <div>
                <span class="btn btn-sm btn-file btn-default"><span class="fileupload-new">SELECT IMAGE</span><span class="fileupload-exists">Change</span>
                <input type="file" name="file" required/></span>
                            <a href="#" class="btn btn-sm btn-danger fileupload-exists" data-dismiss="fileupload">Remove</a>
                        </div>
                    </div>
                </div>

                </div>

                <div class="col-md-7">
                <div class="form-group col-sm-6">
                    <label>ADS TYPE</label>
                    <select name="position" class="form-control" required>
                        <option value="">*_*_*_*_*_*_*_*</option>
                        <option value="Square">Square Banner</option>
                        <option value="Banner">Banner (Inline)</option>
                    </select>
                </div>

                <div class="form-group col-sm-6">
                    <label>ADS POSITION</label>
                    <select name="location" class="form-control" required>
                        <option value="">*_*_*_*_*_*_*_*</option>
                        <option value="header">All Page Header</option>
                        {{--<option value="bFree">Before Free Tips</option>--}}
                        <option value="uFree">Under Free Tips</option>
                        {{--<option value="uUpcoming">Under Upcoming Picks Banner</option>--}}
                        <option value="bStore">Before Categories</option>
                    </select>
                </div>

                <div class="form-group col-sm-4">
                    <label>ADS PAGE</label>
                    <select name="page" class="form-control" required>
                        <option value="">*_*_*_*_*_*_*_*</option>
                        <option value="All">All Pages</option>
                        <option value="Homepage">Homepage</option>
                    </select>
                </div>

                <div class="form-group col-sm-8">
                    <label>WEBSITE URL (if any)</label>
                    <input class="form-control" name="url" placeholder="URL here">
                </div>

                <div class="form-group col-sm-4">
                    <label>DISPLAY CONTROL</label>
                    <select name="displayControl" class="form-control" required>
                        <option value="">*_*_*_*_*_*_*_*</option>
                        <option value="1">Hide on PC/Show Mobile</option>
                        <option value="2">Hide on Mobile/Show PC</option>
                        <option value="0">Show on All</option>
                    </select>
                </div>

                <div class="form-group col-sm-8">
                    <label>THUMBNAIL DESCRIPTION (if any)</label>
                    <input class="form-control" name="description" placeholder="Description here" maxlength="50">
                </div>

                    {!! csrf_field() !!}
                    <div class="form-group col-sm-12">
                        <button class="btn btn-md btn-success" name="submit" id="adsBtn">UPLOAD AD</button>
                    </div>

                </div>

            </div>
        </form>
    </div>


@endsection
