本文整理汇总了PHP中Area::GetName方法的典型用法代码示例。如果您正苦于以下问题:PHP Area::GetName方法的具体用法?PHP Area::GetName怎么用?PHP Area::GetName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Area
的用法示例。
在下文中一共展示了Area::GetName方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: profiling_end
profiling_end('deal with tags and procd_descr');
profiling_start('wrap up processing and package data for the view');
$args['pagetitle'] = "{$icrs->title} ({$icrs->code})";
$args['pageurl'] = $_SERVER['REQUEST_URI'];
$args['course'] = array('id' => (int) $icrs->id, 'title' => $icrs->title, 'code' => $icrs->code, 'descr' => $icrs->descr);
$args['searchresults'] = $search_results;
$args['comment_id'] = $icrs->cid;
$args['comments'] = array_map(function ($a) {
return $a['id'];
}, Comment::ListAll($icrs->cid));
$args['actions'] = $ACTIONS;
$_SESSION['lastargs'] = $args;
preg_match('/^[a-zA-Z]+/', $icrs->code, $matches);
$args['code'] = $matches[0];
$args['university'] = array('id' => $icrs->university, 'name' => University::GetName($icrs->university));
$args['area'] = array('id' => $areaid = University::GetAreaID($args['university']['id']), 'name' => Area::GetName($areaid));
$args['country'] = array('id' => $countryid = Area::GetCountryID($args['area']), 'name' => Country::GetName($countryid));
reset_loading_screen_counter();
profiling_end('wrap up processing and package data for the view');
include "views/search.view.php";
}
} else {
if ($action == 'list') {
$args = array('pagetitle' => 'List', 'pageurl' => $_SERVER['REQUEST_URI'], 'courses' => CourseDefn::ListAll(), 'actions' => $ACTIONS);
$_SESSION['lastargs'] = $args;
include "views/list.view.php";
} else {
if (isset($_GET['action']) && $_GET['action'] != '') {
// Action with no params
$action = $_GET['action'];
$args = array('pagetitle' => ucfirst($action), 'pageurl' => $_SERVER['REQUEST_URI'], 'actions' => $ACTIONS);
示例2: Area
require '../../' . $WEB_SITE . 'src/cdUser.php';
require '../../' . $WEB_SITE . 'src/cdSession.php';
require '../../' . $WEB_SITE . 'src/cdGuardian.php';
$screen_module_name = "Área";
if (isset($_POST["p_action"])) {
$action = $_POST["p_action"];
$area_id = $_POST["p_area_id"];
$area_name = $_POST["p_area_name"];
$message = "";
if ($action == 1) {
$area = new Area();
$area->SetDatabase($database);
$area->SetId($area_id);
$area->SelectById();
$area_id = $area->GetId();
$area_name = $area->GetName();
if ($area_id == "") {
$message = $screen_module_name . " não encontrada.";
$area_id = "";
$area_name = "";
}
}
if ($action == 2) {
$area = new Area();
$area->SetDatabase($database);
$area->SetName($area_name);
if ($area->Insert()) {
$message = $screen_module_name . " incluída com sucesso.";
$area_id = "";
$area_name = "";
} else {
示例3: Subject
<option value="">Selecione</option>
<?php
$subject = new Subject();
$subject->SetDatabase($database);
$result = $subject->Select();
while ($data = $database->FetchArray($result)) {
$subj_id = $data["subj_id"];
$subj_name = $data["subj_name"];
$subj_area_id = $data["subj_area_id"];
$area = new Area();
$area->SetDatabase($database);
$area->SetId($subj_area_id);
$area->SelectById();
if ($arti_subj_id == $subj_id) {
echo "<option value=\"" . $subj_id . "\" selected>" . $subj_name . " (" . $area->GetName() . ")</option>";
} else {
echo "<option value=\"" . $subj_id . "\">" . $subj_name . " (" . $area->GetName() . ")</option>";
}
}
?>
</select>
<font class="form_error"><?php
if ($message_position == 3) {
echo $message;
}
?>
</font>
</td>
</tr>