本文整理汇总了PHP中city::delete方法的典型用法代码示例。如果您正苦于以下问题:PHP city::delete方法的具体用法?PHP city::delete怎么用?PHP city::delete使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类city
的用法示例。
在下文中一共展示了city::delete方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __autoload
<center>
<br/>
<h1>Deleted from the list</h1>
</center>
<?php
function __autoload($className)
{
$fullPath = $className . ".php";
$finalDis = "/../../../" . str_replace("\\", "/", $fullPath);
//echo $finalDis;
include_once $finalDis;
}
use src\Bitm\SEIP117637\city\City;
$city = new city();
$city->delete();
echo "<hr>";
示例2: while
}
break;
case 'letter':
$result = $db->query("SELECT * FROM {$DT_PRE}city WHERE letter=''");
while ($r = $db->fetch_array($result)) {
$letter = $do->letter($r['name']);
$db->query("UPDATE {$DT_PRE}city SET letter='{$letter}' WHERE areaid={$r['areaid']}");
}
dmsg('更新成功', '?file=' . $file);
break;
case 'delete':
if ($areaid) {
$areaids = $areaid;
}
$areaids or msg();
$do->delete($areaids);
dmsg('删除成功', '?file=' . $file);
break;
case 'update':
foreach ($post as $v) {
$do->update($v);
}
dmsg('更新成功', '?file=' . $file);
break;
default:
$condition = '1';
if ($kw) {
$condition .= " AND (name LIKE '%{$keyword}%' OR domain LIKE '%{$keyword}%')";
}
$lists = $do->get_list($condition);
include tpl('city');
示例3: urldecode
require 'path.php';
init_cobalt('Delete city');
if (isset($_GET['city_id'])) {
$city_id = urldecode($_GET['city_id']);
require_once 'form_data_city.php';
}
if (xsrf_guard()) {
init_var($_POST['btn_cancel']);
init_var($_POST['btn_delete']);
require 'components/query_string_standard.php';
if ($_POST['btn_cancel']) {
log_action('Pressed cancel button');
redirect("listview_city.php?{$query_string}");
} elseif ($_POST['btn_delete']) {
log_action('Pressed delete button');
require_once 'subclasses/city.php';
$dbh_city = new city();
$object_name = 'dbh_city';
require 'components/create_form_data.php';
$dbh_city->delete($arr_form_data);
redirect("listview_city.php?{$query_string}");
}
}
require 'subclasses/city_html.php';
$html = new city_html();
$html->draw_header('Delete City', $message, $message_type);
$html->draw_listview_referrer_info($filter_field_used, $filter_used, $page_from, $filter_sort_asc, $filter_sort_desc);
$html->draw_hidden('city_id');
$html->detail_view = TRUE;
$html->draw_controls('delete');
$html->draw_footer();