• Uyarı

Arama sonuçlarınız

  1. anıl

    Trickler Basit captche oluşturma

    composer require haruncpi/laravel-simple-captcha //paket yüklemesi için {!! getCaptchaBox() !!} //blade içerisinde captcha görüntülemek için $this->validate($request,['cevap'=>'simple_captcha']) //Validate olmasını istediğiniz field
  2. anıl

    Trickler Dinamik Cache'leme

    public function commentDetails($slug){ $comments = Cache::remember('comments.'.$slug, function($slug) use($slug) { return Comment::where('slug',$slug)->first(); }); return view('frontend.comments.comment-details',['comment'=>$comment]); } Yukarıda da görüldüğü gibi...
  3. anıl

    Trickler Tablodan rastgele "n" tane veri getirme

    $questions = Question::orderByRaw('RAND()')->take(10)->get(); Question tablosundan rastgele 10 adet satır getirir.
  4. anıl

    Trickler Eloquent Tarih Filtrelemeleri

    $q->whereDate('created_at', date('Y-m-d')); $q->whereDay('created_at', date('d')); $q->whereMonth('created_at', date('m')); $q->whereYear('created_at', date('Y'));
  5. anıl

    Trickler 3 farklı where kullanımları

    $products = Product::where('category', '=', 3)->get(); $products = Product::where('category', 3)->get(); $products = Product::whereCategory(3)->get();