-
Notifications
You must be signed in to change notification settings - Fork 0
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
4 changed files
with
92 additions
and
2 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,8 +1,38 @@ | ||
# NAVER SMART Editor for Laravel | ||
|
||
## document | ||
|
||
[공식사이트](https://www.onstory.fun/doc/programming/laravel/package.laraveleditor) | ||
|
||
|
||
## document | ||
## Installation | ||
``` | ||
composer require wangta69/laravel-editor | ||
php artisan editor:install | ||
``` | ||
|
||
## Tests | ||
> goto https://yourdomain/editor/smart-editor | ||
|
||
## Ex | ||
### before | ||
``` | ||
<form> | ||
<textarea name="comment"></textarea> | ||
<button type="submit">Save</button> | ||
</form> | ||
``` | ||
### after | ||
``` | ||
<form> | ||
@include ('editor::smart-editor.editor', ['name'=>'comment', 'id'=>'comment-id', 'value'=>'', 'attr'=>['class'=>'']]) | ||
<button type="submit">Save</button> | ||
</form> | ||
``` | ||
![laravel WYSIWYG editor](./resources/assets/editor-sample.png) | ||
|
||
- for more [visit](https://www.onstory.fun/doc/programming/laravel/package.laraveleditor) | ||
|
||
|
||
[공식사이트](https://www.onstory.fun/doc/programming/laravel/package.laraveleditor) | ||
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,53 @@ | ||
<?php | ||
|
||
namespace Pondol\Editor\Console; | ||
|
||
use Illuminate\Console\Command; | ||
// use Illuminate\Filesystem\Filesystem; | ||
// use Illuminate\Support\Str; | ||
// use Symfony\Component\Process\PhpExecutableFinder; | ||
// use Symfony\Component\Process\Process; | ||
|
||
class InstallCommand extends Command | ||
{ | ||
// use InstallsBladeStack; | ||
|
||
/** | ||
* The name and signature of the console command. | ||
* | ||
* @var string | ||
*/ | ||
protected $signature = 'editor:install'; | ||
|
||
/** | ||
* The console command description. | ||
* | ||
* @var string | ||
*/ | ||
protected $description = 'Install the Laravel Editor controllers and resources'; | ||
|
||
|
||
public function __construct() | ||
{ | ||
parent::__construct(); | ||
} | ||
|
||
public function handle() | ||
{ | ||
return $this->installLaravelEditor(); | ||
} | ||
|
||
|
||
private function installLaravelEditor() | ||
{ | ||
|
||
\Artisan::call('storage:link'); | ||
\Artisan::call('vendor:publish', [ | ||
'--force'=> true, | ||
'--provider' => 'Pondol\Editor\EditorServiceProvider' | ||
]); | ||
$this->info('The laravel editor installed successfully.'); | ||
} | ||
|
||
|
||
} |
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.