-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
86 changed files
with
1,898 additions
and
1,769 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,23 @@ | ||
APP_ENV=local | ||
APP_DEBUG=true | ||
APP_URL=http://blog.dev | ||
APP_KEY=SomeRandomString | ||
|
||
DB_HOST=localhost | ||
DB_DATABASE=blog | ||
DB_USERNAME=root | ||
DB_PASSWORD=1234 | ||
DB_DATABASE=homestead | ||
DB_USERNAME=homestead | ||
DB_PASSWORD=secret | ||
|
||
CACHE_DRIVER=file | ||
SESSION_DRIVER=file | ||
QUEUE_DRIVER=sync | ||
|
||
REDIS_HOST=localhost | ||
REDIS_PASSWORD=null | ||
REDIS_PORT=6379 | ||
|
||
MAIL_DRIVER=smtp | ||
MAIL_HOST=mailtrap.io | ||
MAIL_PORT=2525 | ||
MAIL_USERNAME=null | ||
MAIL_PASSWORD=null | ||
MAIL_ENCRYPTION=null | ||
MAIL_ENCRYPTION=null |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
/vendor | ||
/node_modules | ||
Homestead.yaml | ||
Homestead.json | ||
.env |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,27 @@ | ||
Laravel Blog for developer | ||
============ | ||
## Laravel PHP Framework | ||
|
||
A Laravel 5.1 blog | ||
[![Build Status](https://travis-ci.org/laravel/framework.svg)](https://travis-ci.org/laravel/framework) | ||
[![Total Downloads](https://poser.pugx.org/laravel/framework/d/total.svg)](https://packagist.org/packages/laravel/framework) | ||
[![Latest Stable Version](https://poser.pugx.org/laravel/framework/v/stable.svg)](https://packagist.org/packages/laravel/framework) | ||
[![Latest Unstable Version](https://poser.pugx.org/laravel/framework/v/unstable.svg)](https://packagist.org/packages/laravel/framework) | ||
[![License](https://poser.pugx.org/laravel/framework/license.svg)](https://packagist.org/packages/laravel/framework) | ||
|
||
## Features | ||
Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable, creative experience to be truly fulfilling. Laravel attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as authentication, routing, sessions, queueing, and caching. | ||
|
||
* alias, published, multi category for posts | ||
* posts pagination | ||
* alias, published and order for categories | ||
* Bundled migration for building the database schema | ||
* powerful admin interface | ||
* newsletters after creating posts | ||
* | ||
Laravel is accessible, yet powerful, providing powerful tools needed for large, robust applications. A superb inversion of control container, expressive migration system, and tightly integrated unit testing support give you the tools you need to build any application with which you are tasked. | ||
|
||
## Official Documentation | ||
|
||
# init | ||
create .env config file from .env.example and change default values. | ||
run: | ||
Documentation for the framework can be found on the [Laravel website](http://laravel.com/docs). | ||
|
||
composer update | ||
php artisan migrate | ||
php artisan db:seed | ||
## Contributing | ||
|
||
Some Screenshot | ||
Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](http://laravel.com/docs/contributions). | ||
|
||
![alt tag](https://cloud.githubusercontent.com/assets/3877538/12076259/fb221706-b1b8-11e5-992f-56b42f51b361.PNG) | ||
## Security Vulnerabilities | ||
|
||
![alt tag](https://cloud.githubusercontent.com/assets/3877538/12076260/01a0ee0e-b1b9-11e5-8e4b-0b50d675cfe5.PNG) | ||
If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell at taylor@laravel.com. All security vulnerabilities will be promptly addressed. | ||
|
||
![alt tag](https://cloud.githubusercontent.com/assets/3877538/12076261/058278e4-b1b9-11e5-868c-9f06b311a7aa.PNG) | ||
|
||
![alt tag](https://cloud.githubusercontent.com/assets/3877538/12076262/0a0c0cd6-b1b9-11e5-87a4-efa71c93cba6.PNG) | ||
### License | ||
|
||
The Laravel framework is open-sourced software licensed under the [MIT license](http://opensource.org/licenses/MIT) |
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
<?php namespace Blog\Events; | ||
<?php | ||
|
||
namespace Blog\Events; | ||
|
||
abstract class Event | ||
{ | ||
|
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
<?php | ||
|
||
namespace Blog\Http\Controllers\Admin\Auth; | ||
|
||
use Blog\User; | ||
use Validator; | ||
use Blog\Http\Controllers\Controller; | ||
use Illuminate\Foundation\Auth\ThrottlesLogins; | ||
use Illuminate\Foundation\Auth\AuthenticatesAndRegistersUsers; | ||
|
||
class AuthController extends Controller | ||
{ | ||
/* | ||
|-------------------------------------------------------------------------- | ||
| Registration & Login Controller | ||
|-------------------------------------------------------------------------- | ||
| | ||
| This controller handles the registration of new users, as well as the | ||
| authentication of existing users. By default, this controller uses | ||
| a simple trait to add these behaviors. Why don't you explore it? | ||
| | ||
*/ | ||
|
||
use AuthenticatesAndRegistersUsers, ThrottlesLogins; | ||
|
||
/** | ||
* Where to redirect users after login / registration. | ||
* | ||
* @var string | ||
*/ | ||
protected $redirectTo = '/admin'; | ||
protected $redirectAfterLogout = '/admin/login'; | ||
|
||
/** | ||
* Create a new authentication controller instance. | ||
* | ||
*/ | ||
public function __construct() | ||
{ | ||
$this->middleware('guest', ['except' => 'logout']); | ||
} | ||
|
||
/** | ||
* Show the application login form. | ||
* | ||
* @return \Illuminate\Http\Response | ||
*/ | ||
public function showLoginForm() | ||
{ | ||
return view('admin.auth.login'); | ||
} | ||
|
||
/** | ||
* Get a validator for an incoming registration request. | ||
* | ||
* @param array $data | ||
* @return \Illuminate\Contracts\Validation\Validator | ||
*/ | ||
protected function validator(array $data) | ||
{ | ||
return Validator::make($data, [ | ||
'name' => 'required|max:255', | ||
'email' => 'required|email|max:255|unique:users', | ||
'password' => 'required|confirmed|min:6', | ||
]); | ||
} | ||
|
||
/** | ||
* Create a new user instance after a valid registration. | ||
* | ||
* @param array $data | ||
* @return User | ||
*/ | ||
protected function create(array $data) | ||
{ | ||
return User::create([ | ||
'name' => $data['name'], | ||
'email' => $data['email'], | ||
'password' => bcrypt($data['password']), | ||
]); | ||
} | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php namespace Blog\Http\Controllers\Admin\Auth; | ||
|
||
use Blog\Http\Controllers\Controller; | ||
use Illuminate\Foundation\Auth\ResetsPasswords; | ||
|
||
class PasswordController extends Controller | ||
{ | ||
/* | ||
|-------------------------------------------------------------------------- | ||
| Password Reset Controller | ||
|-------------------------------------------------------------------------- | ||
| | ||
| This controller is responsible for handling password reset requests | ||
| and uses a simple trait to include this behavior. You're free to | ||
| explore this trait and override any methods you wish to tweak. | ||
| | ||
*/ | ||
|
||
use ResetsPasswords; | ||
|
||
protected $resetView = 'admin.auth.passwords.reset'; | ||
|
||
/** | ||
* Create a new password controller instance. | ||
* | ||
*/ | ||
public function __construct() | ||
{ | ||
$this->middleware('guest'); | ||
} | ||
|
||
public function showLinkRequestForm() | ||
{ | ||
return view('admin.auth.passwords.email'); | ||
} | ||
} |
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.