@extends('master')
@section('title')Edit Article « Admin CP « @stop
@section('content')
<form action="/admin/blog/{{ $id }}" method="post" accept-charset="utf-8" class="admin-form form">
{{ csrf_field() }}
{{ method_field('PUT') }}
<div>
<label for="title">Title (URL):</label>
<input type="text" name="title" id="title" value="{!! $post['0']['title'] !!}">
<input type="url" name="url" id="url" value="{!! $post['0']['url'] !!}">
</div>
<label for="main">Main:</label>
<textarea name="main" id="main">{{ $post['0']['main'] }}</textarea>
<div class="form-row">
<label for="published">Published:</label>
<input type="checkbox" name="published" value="1"@if($post['0']['published'] == '1') checked="checked"@endif>
<button type="submit" name="save">Save</button>
</form>
<hr>
<form action="/admin/blog/{{ $id }}" method="post" class="admin-form form">
{{ method_field('DELETE') }}
<button type="submit" name="delete">Delete</button>
@stop