本文整理汇总了PHP中crud::delete方法的典型用法代码示例。如果您正苦于以下问题:PHP crud::delete方法的具体用法?PHP crud::delete怎么用?PHP crud::delete使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类crud
的用法示例。
在下文中一共展示了crud::delete方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
</div>
</form>
</div>
</div>
</div>
</div>
<?php
if (empty($sidErr) && empty($websiteErr) && empty($mpErr) && !empty($sid) && !empty($website) && !empty($mp) && empty($widgetErr) && !empty($widget2) && !empty($pubid) && empty($pubidErr) && $submit === "update") {
$piwik = 2;
$cache = true;
$abtest = false;
$allowedParameters = array();
$crud = new crud();
$crud->update($pubid, $name, $website, $piwik, $cache, $allowedParameters, $abtest, $mp, $widget2);
} else {
if (empty($sidErr) && !empty($sid) && !empty($pubid) && empty($pubidErr) && $submit === "delete") {
$crud = new crud();
$crud->delete($sid, $pubid);
}
}
?>
</body>
</html>
l
示例2: user_hapus
public function user_hapus()
{
if (akses::aksesLogin() == TRUE or akses::aksesUser() == TRUE) {
$id = $this->encrypt->decode_url($_GET['id']);
crud::delete('tbl_user', 'username', $id);
$this->session->set_flashdata('pengaturan', '<div class="alert alert-success">Username : <b>' . $id . '</b>, berhasil dihapus !!</div>');
redirect('page=pengaturan&act=user_list');
} else {
$this->session->set_flashdata('login', '<div class="alert alert-danger">Maaf, anda session habis. Silahkan login ulang.</div>');
redirect(site_url());
}
}
示例3: menu_hapus
public function menu_hapus()
{
// if (akses::aksesLogin() == TRUE OR akses::aksesUser() == TRUE) {
$id = $this->encrypt->decode_url($_GET['id']);
crud::delete('tbl_menu', 'id_menu', $id);
redirect('page=menu&act=menu_list');
// } else {
// $this->session->set_flashdata('login', '<div class="alert alert-danger">Maaf, anda session habis. Silahkan login ulang.</div>');
// redirect(site_url());
// }
}
示例4: deleteOpcao
public function deleteOpcao()
{
parent::setTabela('sebraeprev_enquete_opcoes');
$resultado = parent::delete("id_enquete = '{$this->id_enquete}'");
return $resultado;
}
示例5: array
* berikut adalah cara untuk melakukan execute pada function2nya
======== insert ==========
$data = array( 'nim' => "061250259",
'nm_mhs' => "Syafi'i",
'alamat' => "jalan ulujami Raya Gg.pancoran",
'tanggal' => "2011-03-09"
);
echo $db->insert($tabel, $data);
*
========update==========
* $updateField = array('nm_mhs' => "fitriyana1",
'alamat' => "fadly");
$where = "nim = '061250256'";
echo $db->update("mahasiswa", $updateField, $where);
*
*
========select===========
$field = "*";
$where = "nim = '061250256'";
$db->select($tabel, $field, $where);
$hasil = $db->getResult();
echo $hasil;
*/
$where = array("nim" => "061250256");
echo $db->delete($tabel, $where);