Results: 1580
Notes
  • Newest first
  • Oldest first
  • Newest first(All)
  • Oldest first(All)
It will remove devDependencies from
package.json
like
bootstrap, jquery, popper.js, vue
(removes frontend scaffolding)
php artisan preset none
Except the following packages
"devDependencies": {
    "axios": "^0.19",
    "cross-env": "^7.0",
    "laravel-mix": "^5.0.1",
    "lodash": "^4.17.19",
    "resolve-url-loader": "^3.1.0",
    "sass": "^1.15.2",
    "sass-loader": "^8.0.0"
}
by Valeri Tandilashvili
4 years ago
0
Laravel
0
Only the post author will be able to edit the post
public function edit($id)
{
    $post = POST::find($id);

    // Check for correct user
    if (auth()->user()->id !== $post->user_id) {
        return redirect('/posts')->with('error', 'Unauthorized page');
    }

    return view('posts.edit')->with('post', $post);
}
by Valeri Tandilashvili
4 years ago
0
Laravel
auth
Laravel From Scratch
0
Adds exceptions so that unauthorized users will be able to see all posts and individual post
public function __construct() {
    $this->middleware('auth', ['except'=>['index', 'show']]);
}
by Valeri Tandilashvili
4 years ago
0
Laravel
auth
Laravel From Scratch
0
git commit amend
change commit name or add some changes in previous commit
git commit -amend -m "comment"
by Luka Tatarishvili
4 years ago
0
Git
commands
Git Tutorials
0
Button types with html examples
<button type="button" class="btn btn-primary">Primary</button>
<button type="button" class="btn btn-secondary">Secondary</button>
<button type="button" class="btn btn-success">Success</button>
<button type="button" class="btn btn-danger">Danger</button>
<button type="button" class="btn btn-warning">Warning</button>
<button type="button" class="btn btn-info">Info</button>
<button type="button" class="btn btn-light">Light</button>
<button type="button" class="btn btn-dark">Dark</button>

<button type="button" class="btn btn-link">Link</button>
Special classes for different button types:
btn-primary
btn-secondary
btn-success
btn-danger
btn-warning
btn-info
btn-light
btn-dark
by Valeri Tandilashvili
4 years ago
0
Bootstrap
buttons
Bootstrap official doc
0
.container
class sets a max-width at each responsive breakpoint
by Valeri Tandilashvili
4 years ago
0
Bootstrap
layout
Bootstrap v5: Getting Started (Buttons, Responsive Columns, Accordion)
0
Two columns with equal width on all devices and viewport (from
xs
to
xl
)
<div class="row">
    <div class="col">
      1 of 2
    </div>
    <div class="col">
      2 of 2
    </div>
  </div>
Three equal width columns
<div class="row">
    <div class="col">
      1 of 3
    </div>
    <div class="col">
      2 of 3
    </div>
    <div class="col">
      3 of 3
    </div>
  </div>
by Valeri Tandilashvili
4 years ago
0
Bootstrap
layout
Bootstrap official doc
0
The column in the middle has specified width and the rest of the space is divided equally for the other columns
<div class="container">
  <div class="row">
    <div class="col">
      1 of 3
    </div>
    <div class="col-6">
      2 of 3 (wider)
    </div>
    <div class="col">
      3 of 3
    </div>
  </div>
  <div class="row">
    <div class="col">
      1 of 3
    </div>
    <div class="col-5">
      2 of 3 (wider)
    </div>
    <div class="col">
      3 of 3
    </div>
  </div>
</div>
by Valeri Tandilashvili
4 years ago
0
Bootstrap
layout
Bootstrap official doc
0
pointer-events: none
The element does not react to pointer events. It's a way to disable inputs inside the div
style="pointer-events: none;" 
by Luka Tatarishvili
1 year ago
0
CSS
css property
0
Permission problem - composer install/update
1 ./vendor/bin/sail exec laravel.test bash 2 mkdir -p /var/www/html/vendor/setasign 3 chmod -R 777 /var/www/html/vendor 4 chown -R sail:sail /var/www/html/vendor 5 exit 6 ./vendor/bin/sail composer require mpdf/mpdf
by Luka Tatarishvili
3 weeks ago
0
MySQL
0
Results: 1580