當前位置: 首頁>>代碼示例>>PHP>>正文


PHP DB::delete方法代碼示例

本文整理匯總了PHP中Illuminate\Support\Facades\DB::delete方法的典型用法代碼示例。如果您正苦於以下問題:PHP DB::delete方法的具體用法?PHP DB::delete怎麽用?PHP DB::delete使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Illuminate\Support\Facades\DB的用法示例。


在下文中一共展示了DB::delete方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: bannerSil

 function bannerSil($sil)
 {
     $bannerSil = DB::delete("delete from banner where id = ?", array($sil));
     if ($bannerSil) {
         return Redirect::to('admin/bannerListele');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:bannerListeleController.php

示例2: mesajSil

 function mesajSil($sil)
 {
     $mesajSil = DB::delete("delete from mesajlar where id = ?", array($sil));
     if ($mesajSil > 0) {
         return Redirect::to('admin/mesajlar');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:mesajlarController.php

示例3: store

 public function store(SetupRequest $request)
 {
     DB::delete('delete from settings');
     DB::table('settings')->insert([['name' => 'name', 'value' => e($request->input('name'))], ['name' => 'cover', 'value' => 'images/cover.jpg'], ['name' => 'avatar', 'value' => 'images/avatar.png'], ['name' => 'bio', 'value' => e($request->input('bio'))], ['name' => 'email', 'value' => 'hsinlu@live.com'], ['name' => 'title', 'value' => e($request->input('title'))], ['name' => 'subtitle', 'value' => e($request->input('subtitle'))], ['name' => 'keywords', 'value' => e($request->input('keywords'))], ['name' => 'description', 'value' => e($request->input('description'))], ['name' => 'paginate_size', 'value' => 5]]);
     event(new \App\Events\DoneSetupEvent());
     return redirect('/');
 }
開發者ID:angelWendy,項目名稱:streamlet,代碼行數:7,代碼來源:SetupController.php

示例4: urunSil

 function urunSil($urunsil)
 {
     $urunsil = DB::delete("delete from urunler where id = ?", array($urunsil));
     if ($urunsil > 0) {
         return Redirect::to('admin/urun');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:urunController.php

示例5: yorumSil

 function yorumSil($sil)
 {
     $yorumSil = DB::delete("delete from yorumlar where id = ?", array($sil));
     if ($yorumSil > 0) {
         return Redirect::to('admin/urunYorum');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:urunYorumController.php

示例6: icerikSil

 function icerikSil($iceriksil)
 {
     $iceriksil = DB::delete("delete from icerikler where id = ?", array($iceriksil));
     if ($iceriksil > 0) {
         return Redirect::to('admin/icerik');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:icerikController.php

示例7: videoSil

 function videoSil($videoSil)
 {
     $videoSil = DB::delete("delete from videolar where id = ?", array($videoSil));
     if ($videoSil > 0) {
         return Redirect::to('admin/video');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:videoController.php

示例8: sil

 public function sil($sil)
 {
     $data = DB::delete("delete from linkler where id=?", array($sil));
     if ($data > 0) {
         return Redirect::to('admin/linkler');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:linklerController.php

示例9: haberSil

 function haberSil($habersil)
 {
     $habersil = DB::delete("delete from haberler where id = ?", array($habersil));
     if ($habersil > 0) {
         return Redirect::to('admin/haberler');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:7,代碼來源:haberlerController.php

示例10: sil

 public function sil($id)
 {
     $silIslem = DB::delete("delete from kullanicilar where id = ?", array($id));
     //echo "<script>alert('".$silIslem."');</script>";
     if ($silIslem > 0) {
         return Redirect::to('admin/kullanicilar');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:8,代碼來源:kullanicilarController.php

示例11: silData

 public function silData($sil)
 {
     // data silme işlemi
     $silIslem = DB::delete("delete from kullanicilar where id = ?", array($sil));
     //echo "<script>alert('".$silIslem."');</script>";
     if ($silIslem > 0) {
         return Redirect::to('veritabani');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:9,代碼來源:veritabaniController.php

示例12: delete

 static function delete($id, $pass)
 {
     $entry = DB::select("SELECT password FROM Entries WHERE rowid=?", [$id]);
     if (Hash::check($pass, $entry[0]->password)) {
         DB::delete('DELETE FROM Entries WHERE rowid=?', [$id]);
         DB::delete('DELETE FROM Entries WHERE id_team=?', [$id]);
         return 1;
     }
     return 0;
 }
開發者ID:grit45,項目名稱:EEISTI-Tournaments,代碼行數:10,代碼來源:Entry.php

示例13: sliderSil

 function sliderSil($sil)
 {
     $silenecek = DB::select("select yol from slider where id = ?", array($sil));
     $fileName = $silenecek[0]->yol;
     File::delete("slider/" . $fileName);
     $sliderSil = DB::delete("delete from slider where id = ?", array($sil));
     if ($sliderSil > 0) {
         return Redirect::to('admin/sliderYonetimi');
     }
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:10,代碼來源:sliderController.php

示例14: olay

 public function olay()
 {
     $durum = Input::all();
     if (isset($durum["sil"])) {
         // silme işlemi
         $sil_id = $durum["topCategory"];
         $silIslem = DB::delete("delete from kategoriler where id = ?", array($sil_id));
     }
     return Redirect::to('admin/kategori');
 }
開發者ID:hakanozer,項目名稱:laravelAdmin,代碼行數:10,代碼來源:kategoriController.php

示例15: silForm

 /**
  * Kullanıcı silme işlemi.
  * @param $kul_id
  * @return redirect
  */
 public function silForm($kul_id)
 {
     // Kullanıcı silme işlemi.
     $q = "DELETE FROM kullanicilar WHERE id = ?";
     $islem = DB::delete($q, array($kul_id));
     if ($islem) {
         $mesaj = "basarili";
     } else {
         $mesaj = "basarisiz";
     }
     return redirect("kullanicilar/liste")->with("mesaj", $mesaj);
 }
開發者ID:hramose,項目名稱:Laravel5-Admin-3,代碼行數:17,代碼來源:KullanicilarController.php


注:本文中的Illuminate\Support\Facades\DB::delete方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。