This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<form action="{!! route('[email protected]') !!}" method="post" autocomplete="off"> | |
{!! csrf_field() !!} | |
<div class="form-group"> | |
<label for="site_name">Site Adı : </label> | |
<input type="text" class="form-control" id="site_name" name="settings[site_name]" placeholder="Site Adı"> | |
@if($errors->has('settings.site_name')) <span class="help-block">{!! $errors->first('settings.site_name') !!}</span> @endif | |
</div> | |
<div class="form-group"> | |
<label for="site_slogan">Site Sloganı : </label> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Unal\Http\Requests\Admin\Settings; | |
use Unal\Http\Requests\Request; | |
class General extends Request | |
{ | |
/** | |
* Determine if the user is authorized to make this request. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* index.blade.php'de jQuery'nin yüklü olması gerekiyor. | |
* index.blade.php'de head tagları arasına | |
* <meta name="_token" content="{!! csrf_token !!}" /> 'i ekliyoruz | |
*/ | |
$.ajaxSetup({ | |
// Ajax Post işlemi sırasında Laravel'in TokenMismatchException hatası vermemesi için | |
'datatype' :'json', | |
'method' : 'post', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
Route::group(['middleware' => 'web'],function(){ | |
Route::get('post',['as' => 'post.index','uses' => 'PostController@index']); // Burada Post sayfasını görüntüleyeceğiz. | |
Route::post('post',['middleware' => 'throttle:5','uses' => 'PostController@store']) // middleware eklememizin sebebi, art arda sunucu istekleini engellemek | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http\Controllers; | |
use App\Http\Requests\Post as Request; | |
use App\Http\Controllers\Controller; | |
class PostController extends Controller | |
{ | |
public function index(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http\Requests; | |
use App\Http\Requests\Request; | |
class Post extends Request | |
{ | |
/** | |
* Determine if the user is authorized to make this request. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html lang="tr"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="author" content="Ferdi ÜNAL"> | |
<meta name="_token" content="{!! csrf_token() !!}"> | |
<title>Post</title> | |
</head> | |
<body> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Http; | |
use Illuminate\Foundation\Http\Kernel as HttpKernel; | |
class Kernel extends HttpKernel | |
{ | |
/** | |
* The application's global HTTP middleware stack. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Bootstrap; | |
class Application extends Illuminate\Foundation\Application | |
{ | |
/** | |
* The Laravel framework version. | |
* | |
* @var string | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
export DEBIAN_FRONTEND=noninteractive | |
# Update Package List | |
apt-get update | |
# Update System Packages | |
apt-get -y upgrade |