本文整理汇总了PHP中Photo::deletePhotos方法的典型用法代码示例。如果您正苦于以下问题:PHP Photo::deletePhotos方法的具体用法?PHP Photo::deletePhotos怎么用?PHP Photo::deletePhotos使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Photo
的用法示例。
在下文中一共展示了Photo::deletePhotos方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: delete
public static function delete($id)
{
global $db;
$db->query("DELETE FROM land WHERE id={$id}");
Photo::deletePhotos(HOUSE, $id);
}
示例2: delete
public static function delete($id)
{
global $db;
$db->query("SELECT id FROM flat WHERE tenement_id={$id}");
$rows = $db->fetchAll();
foreach ($rows as $row) {
Flat::delete($row['id']);
}
$db->query("DELETE FROM tenement WHERE id={$id}");
Photo::deletePhotos(TENEMENT, $id);
}
示例3: delete
public static function delete($id)
{
global $db;
$db->query("DELETE FROM commercial WHERE id={$id}");
Photo::deletePhotos(COMMERCIAL, $id);
}
示例4: action
function action()
{
$where = " WHERE 1";
if (isset($_POST['b1']) && $_POST['b1'] == "Удалить") {
foreach ($_REQUEST['id_check'] as $k => $v) {
Photo::deletePhotos($v, $this->class_name);
DB::query("DELETE FROM `" . $this->table_name . "` WHERE `id` = '" . $v . "'");
}
}
$a = array();
$a['categoryID'] = array('Родитель', '20%', true);
$a['name'] = array('Заголовок', '80%', true);
$btn = array();
$btn[] = "Удалить";
$category_id = isset($_GET['categoryID']) ? $_GET['categoryID'] : 0;
$where .= ' && `categoryID` = "' . DB::escape($category_id) . '"';
$oTable = new Table("admin.php?act=" . str_replace('action', '', __FUNCTION__) . "&page=");
return $this->InIndex('Категории', $oTable->getTable($this, $this->class_name, $this->table_name, $a, $this->links_per_page, $btn, $where));
}
示例5: action
function action()
{
$where = " WHERE 1";
if (isset($_POST['b1']) && $_POST['b1'] == "Удалить") {
foreach ($_REQUEST['id_check'] as $k => $v) {
Photo::deletePhotos($v, $this->class_name);
DB::query("DELETE FROM `" . $this->table_name . "` WHERE `id` = '" . $v . "'");
}
}
$a = array();
$a['main'] = array('Изображение', '15%', true);
$a['categoryID'] = array('Категория', '15%', true);
$a['name'] = array('Название', '20%', true);
$a['price'] = array('Стоимость', '50%', true);
$btn = array();
$btn[] = "Удалить";
$oTable = new Table("admin.php?act=" . str_replace('action', '', __FUNCTION__) . "&page=");
return $this->InIndex('Товары', $oTable->getTable($this, $this->class_name, $this->table_name, $a, $this->links_per_page, $btn));
}
示例6: delete
public static function delete($id)
{
global $db;
Photo::deletePhotos(FLAT, $id);
$db->query("DELETE FROM flat WHERE id={$id}");
}