当前位置: 首页>>代码示例>>PHP>>正文


PHP url_change函数代码示例

本文整理汇总了PHP中url_change函数的典型用法代码示例。如果您正苦于以下问题:PHP url_change函数的具体用法?PHP url_change怎么用?PHP url_change使用的例子?那么, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了url_change函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: drawStaffList

function drawStaffList($where, $searchterms = false)
{
    global $isAdmin, $_josh;
    $return = drawJumpToStaff() . '<table class="left" cellspacing="1">';
    if ($isAdmin) {
        $colspan = 5;
        $return .= drawHeaderRow(false, $colspan, "new", "add_edit.php");
    } else {
        $colspan = 4;
        $return .= drawHeaderRow(false, $colspan);
    }
    $return .= '<tr>
		<th class="image"></th>
		<th>Name / Office</th>
		<th>Title / Department</th>
		<th class="r">Phone</th>';
    if ($isAdmin) {
        $return .= '<th></th>';
    }
    $return .= '</tr>';
    $result = db_query("SELECT \n\t\t\tu.userID, \n\t\t\tu.lastname,\n\t\t\tISNULL(u.nickname, u.firstname) firstname, \n\t\t\tu.bio, \n\t\t\tu.phone,\n\t\t\tc.description corporationName,\n\t\t\tu.corporationID,\n\t\t\to.name office, \n\t\t\tu.title, \n\t\t\td.departmentName\n\t\tFROM intranet_users u\n\t\tLEFT JOIN intranet_departments d\tON d.departmentID = u.departmentID \n\t\tLEFT JOIN organizations c\t\t\tON u.corporationID = c.id\n\t\tLEFT JOIN intranet_offices o\t\tON o.id = u.officeID\n\t\tWHERE " . $where . "\n\t\tORDER BY u.lastname, ISNULL(u.nickname, u.firstname)");
    $count = db_found($result);
    if ($count) {
        if ($count == 1 && $searchterms) {
            $r = db_fetch($result);
            $_josh["slow"] = true;
            url_change("view.php?id=" . $r["userID"]);
        } else {
            while ($r = db_fetch($result)) {
                $return .= drawStaffRow($r, $searchterms);
            }
        }
    } else {
        $return .= drawEmptyResult("No staff match those criteria.", $colspan);
    }
    return $return . '</table>';
}
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:37,代码来源:include.php

示例2: url_change

            if ($ct == 'news') {
                ?>
current<?php 
            }
            ?>
">News<span class="fright">(<?php 
            echo $news_counter;
            ?>
)</span></a><?php 
        }
        ?>
						<?php 
        if ($article_counter > 0) {
            ?>
<a href="<?php 
            echo url_change('article', 'content-type');
            ?>
#list" class="<?php 
            if ($ct == 'article') {
                ?>
current<?php 
            }
            ?>
">Analysis<span class="fright">(<?php 
            echo $article_counter;
            ?>
)</span></a><?php 
        }
        ?>
					</div>
				</div>
开发者ID:epforgpl,项目名称:web-transparencee,代码行数:31,代码来源:index.php

示例3: db_query

<?php

include "../../include.php";
if ($posting) {
    $theuser_id = $page['is_admin'] ? $_POST["created_user"] : $_SESSION["user_id"];
    db_query("UPDATE press_releases SET\n\t\t\theadline       = '{$_POST["headline"]}',\t\n\t\t\tdetail         = '{$_POST["detail"]}',\t\n\t\t\tlocation       = '{$_POST["location"]}',\t\n\t\t\ttext           = '" . format_html($_POST["text"]) . "',\t\n\t\t\tcorporationID = {$_POST["corporationID"]},\n\t\t\tupdated_date     = GETDATE(),\n\t\t\tupdated_user     = {$theuser_id}\n\t\t\tWHERE id = " . $_GET["id"]);
    url_change("../?id=" . $_GET["id"]);
}
echo drawTop();
$r = db_grab("SELECT id, headline, detail, location, releaseDate, corporationID, text FROM press_releases WHERE id = " . $_GET["id"]);
$form = new intranet_form();
if ($page['is_admin']) {
    $form->addUser("created_user", "Posted By", $_SESSION["user_id"], false, "EEDDCC");
}
$form->addRow("itext", "Headline", "headline", $r["headline"], "", true, 255);
$form->addRow("itext", "Detail", "detail", $r["detail"], "", false, 255);
$form->addRow("itext", "Location", "location", $r["location"], "", true, 255);
$form->addRow("select", "Organization", "corporationID", "SELECT id, title from organizations ORDER BY title", $r["corporationID"]);
$form->addRow("date", "Date", "releaseDate", $r["releaseDate"]);
$form->addRow("textarea", "Text", "text", $r["text"], "", true);
$form->addRow("submit", "update press release");
$form->draw("Update Release");
echo drawBottom();
开发者ID:Rhenan,项目名称:intranet-1,代码行数:23,代码来源:edit.php

示例4: format_post_nulls

<?php

include "include.php";
if ($posting) {
    $user_id = $page['is_admin'] ? $_POST["user_id"] : $_SESSION["user_id"];
    format_post_nulls("type_id");
    $id = db_query("INSERT INTO helpdesk_tickets (\r\n    \tcreated_user,\r\n    \ttype_id,\r\n\t\tpriorityID,\r\n\t\tdepartmentID,\r\n\t\tdescription,\r\n\t\tstatusID,\r\n\t\tipAddress,\r\n\t\tcreated_date,\r\n\t\tupdated_date,\r\n\t\ttitle\r\n\t) VALUES (\r\n\t\t" . $user_id . ",\r\n\t\t" . $_POST["type_id"] . ",\r\n\t\t'" . $_POST["priorityID"] . "',\r\n\t\t'" . $_POST["departmentID"] . "',\r\n\t\t'" . $_POST["description"] . "',\r\n\t\t1,\r\n\t\t'{$_SERVER["REMOTE_ADDR"]}',\r\n\t\tGETDATE(),\r\n\t\tGETDATE(),\r\n\t\t'" . $_POST["title"] . "'\r\n    );");
    //$r = db_grab("SELECT MAX(id) id FROM helpdesk_tickets");
    //todo - email mohammed for critical
    emailITTicket($id, 'new');
    //special for carla
    url_change('ticket.php?id=' . $id);
}
echo drawTop();
echo drawMessage($helpdeskStatus, "center");
?>

<script language="javascript">
	<!--
	function updateTypes(departmentID) {
		var types = new Array(3, 8);
		<?php 
$types = db_query("SELECT id, departmentID, description FROM helpdesk_tickets_types ORDER BY departmentID, description");
$options = array();
while ($t = db_fetch($types)) {
    $options[$t["departmentID"]][] = '"' . $t["id"] . '|' . $t["description"] . '"';
}
while (list($key, $value) = each($options)) {
    ?>
			types[<?php 
    echo $key;
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:index.php

示例5: db_table

<?php

include "../../include.php";
if (url_id('module_id')) {
    $result = db_table('SELECT p.id, p.title, p.url, p.is_hidden FROM pages p WHERE module_id = ' . $_GET['module_id'] . ' ORDER BY p.precedence');
} elseif (url_id('modulette_id')) {
    $result = db_table('SELECT p.id, p.title, p.url, p.is_hidden FROM pages p WHERE modulette_id = ' . $_GET['modulette_id'] . ' ORDER BY p.precedence');
} else {
    url_change('./');
}
echo drawTop();
//pages list
$t = new table('pages', drawHeader());
$t->set_column('is_hidden', 'd', '&nbsp;');
$t->set_column('draggy', 'd', '&nbsp;');
$t->set_column('title', 'l', getString('title'));
$t->set_column('url');
$t->set_draggable('draggy');
foreach ($result as &$r) {
    $r['is_hidden'] = draw_form_checkbox('foo', !$r['is_hidden'], false, 'ajax_set(\'pages\', \'is_hidden\', ' . $r['id'] . ', ' . abs($r['is_hidden'] - 1) . ');');
    $r['draggy'] = draw_img('/images/icons/move.png');
    $r['title'] = draw_link('page.php?id=' . $r['id'], $r['title']);
    if (empty($r['url'])) {
        $r['url'] = 'index.php';
    }
}
echo $t->draw($result, 'No pages');
echo drawBottom();
开发者ID:Rhenan,项目名称:intranet-1,代码行数:28,代码来源:pages.php

示例6: isset

    $laptopIsWireless = isset($_POST["laptopIsWireless"]) ? 1 : 0;
    if (isset($_GET["id"])) {
        db_query("UPDATE it_laptops SET\r\n\t\t\tlaptopName      = '" . $_POST["laptopName"] . "',\r\n\t\t\tlaptopModel      = '" . $_POST["laptopModel"] . "',\r\n\t\t\tlaptopHomeID      = " . $_POST["laptopHomeID"] . ",\r\n\t\t\tlaptopSerial     = '" . $_POST["laptopSerial"] . "',\r\n\t\t\tlaptopExpressServiceCode     = '" . $_POST["laptopExpressServiceCode"] . "',\r\n\t\t\tlaptopServiceTag = '" . $_POST["laptopServiceTag"] . "',\r\n\t\t\tlaptopOS         = '" . $_POST["laptopOS"] . "',\r\n\t\t\tlaptopOffice     = '" . $_POST["laptopOffice"] . "',\r\n\t\t\tlaptopIsWireless = {$laptopIsWireless},\r\n\t\t\tlaptopMACAddress    = '" . $_POST["laptopMACAddress"] . "',\r\n\t\t\tlaptopPurpose    = '" . $_POST["laptopPurpose"] . "'\r\n\t\t\tWHERE laptopID = " . $_GET["id"]);
        db_query("DELETE FROM it_laptops_2_accessories WHERE laptopID = " . $_GET["id"]);
    } else {
        $_GET["id"] = db_query("INSERT INTO it_laptops (\r\n\t\t\tlaptopName,\r\n\t\t\tlaptopModel,\r\n\t\t\tlaptopHomeID,\r\n\t\t\tlaptopSerial,\r\n\t\t\tlaptopExpressServiceCode,\r\n\t\t\tlaptopstatusID,\r\n\t\t\tlaptopServiceTag,\r\n\t\t\tlaptopOS,\r\n\t\t\tlaptopOffice,\r\n\t\t\tlaptopIsWireless,\r\n\t\t\tlaptopMACAddress,\r\n\t\t\tlaptopPurpose\r\n\t\t) VALUES (\r\n\t\t\t'" . $_POST["laptopName"] . "',\t\t\t\r\n\t\t\t'" . $_POST["laptopModel"] . "',\t\t\t\r\n\t\t\t" . $_POST["laptopHomeID"] . ",\t\t\t\r\n\t\t\t'" . $_POST["laptopSerial"] . "',\r\n\t\t\t'" . $_POST["laptopExpressServiceCode"] . "',\r\n\t\t\t2,\r\n\t\t\t'" . $_POST["laptopServiceTag"] . "',\t\t\t\r\n\t\t\t'" . $_POST["laptopOS"] . "',\t\t\t\r\n\t\t\t'" . $_POST["laptopOffice"] . "',\t\t\t\r\n\t\t\t{$laptopIsWireless},\t\t\t\r\n\t\t\t'" . $_POST["laptopMACAddress"] . "',\r\n\t\t\t'" . $_POST["laptopPurpose"] . "'\r\n\t\t)");
    }
    //accessories
    reset($_POST);
    while (list($key, $value) = each($_POST)) {
        @(list($control, $accessoryID) = explode("_", $key));
        if ($control == "chkacc") {
            db_query("INSERT INTO it_laptops_2_accessories (\r\n\t\t\t\tlaptopID,\r\n\t\t\t\taccessoryID\r\n\t\t\t) VALUES (\r\n\t\t\t\t" . $_GET["id"] . ",\r\n\t\t\t\t" . $accessoryID . "\r\n\t\t\t);");
        }
    }
    url_change("laptop.php?id=" . $_GET["id"]);
}
echo drawTop();
if (isset($_GET["id"])) {
    $r = db_grab("SELECT \r\n\t\t\t\t\t\tl.laptopName,\r\n\t\t\t\t\t\tl.laptopPurpose,\r\n\t\t\t\t\t\tl.laptopModel,\r\n\t\t\t\t\t\tl.laptopHomeID,\r\n\t\t\t\t\t\tl.laptopSerial,\r\n\t\t\t\t\t\tl.laptopExpressServiceCode,\r\n\t\t\t\t\t\tl.laptopServiceTag,\r\n\t\t\t\t\t\tl.laptopOS,\r\n\t\t\t\t\t\tl.laptopOffice,\r\n\t\t\t\t\t\tl.laptopIsWireless,\r\n\t\t\t\t\t\tl.laptopMACAddress\r\n\t\t\t\t\tFROM it_laptops l\r\n\t\t\t\t\tWHERE laptopID = " . $_GET["id"]);
    $openEnded = empty($r["laptopEnd"]) ? true : false;
}
?>

<a name="closedtickets"></a>
<table class="left" cellspacing="1">
	<?php 
echo drawHeaderRow("Add Laptop", 2);
?>
	<form method="post" action="<?php 
echo $request["path_query"];
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:laptop_add_edit.php

示例7: db_save

<?php

include "../../include.php";
if ($posting) {
    $id = db_save("queries");
    url_change("./");
}
echo drawTop();
if (isset($_GET["id"])) {
    $r = db_grab("SELECT \n\t\t\tq.databaseID,\n\t\t\td.dbname,\n\t\t\tq.name,\n\t\t\tq.description,\n\t\t\tq.query,\n\t\t\tq.is_active\n\t\tFROM queries q \n\t\tJOIN queries_databases d ON d.id = q.databaseID\n\t\tWHERE q.id = " . $_GET["id"]);
    /*db_switch($r["dbname"]);
    	db_query($r["query"], false, true);
    	db_switch($_josh["db"]["database"]);*/
} else {
    $r["is_active"] = 1;
}
$form = new intranet_form();
$form->addRow("hidden", "", "is_active", $r["is_active"]);
$form->addRow("select", "Database", "databaseID", "SELECT id, dbname from queries_databases order by dbname", @$r["databaseID"], true);
$form->addRow("itext", "Name", "name", @$r["name"], "", false, 50);
$form->addRow("textarea", "Description", "description", @$r["description"]);
$form->addRow("textarea-plain", "Query", "query", @$r["query"]);
$form->addRow("submit", "Save Changes");
if (isset($_GET["id"])) {
    $form->draw("<a href='/queries/'>Database Queries</a> &gt; Edit Query");
} else {
    $form->draw("Add New Query");
}
echo drawBottom();
开发者ID:Rhenan,项目名称:intranet-1,代码行数:29,代码来源:query_edit.php

示例8: url_query_require

function url_query_require($target = "./", $index = "id")
{
    //requires a _GET variable to be defined or eject page
    if (!url_id($index)) {
        url_change($target);
    }
}
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:7,代码来源:url.php

示例9: db_delete

<?php

include "../../include.php";
if (url_action("delete")) {
    db_delete("openings");
    url_drop();
} elseif ($posting) {
    //debug();
    if ($id = db_save("openings")) {
        url_change("position.php?id=" . $id);
    }
}
echo drawTop();
?>
<table class="left" cellspacing="1">
	<?php 
if ($page['is_admin']) {
    $colspan = 4;
    echo drawHeaderRow("Open Positions", $colspan, "new", "#bottom");
} else {
    $colspan = 3;
    echo drawHeaderRow("Open Positions", $colspan);
}
?>
	<tr>
		<th width="50%">Title</th>
		<th width="30%">Location</th>
		<th class="r" width="20%"><nobr>Last Update</nobr></th>
		<?php 
if ($page['is_admin']) {
    ?>
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:index-old.php

示例10: isset

}
if (!empty($_POST)) {
    $isActionItem = isset($_POST["chkActionItem"]) ? 1 : 0;
    $isReport = isset($_POST["chkReport"]) ? 1 : 0;
    $isInternal = $_POST["isInternal"] == "true" ? 1 : 0;
    db_query('UPDATE funders_activity SET 
		activityTitle      = "' . $_POST["activityTitle"] . '",
		activityDate       = ' . format_date_sql($_POST["activityDateMonth"], $_POST["activityDateDay"], $_POST["activityDateYear"]) . ',
		activityAssignedTo = ' . $_POST["activityAssignedTo"] . ',
		isComplete         = "' . $_POST["isComplete"] . '",
		isActionItem       = ' . $isActionItem . ',
		isReport           = ' . $isReport . ',
		isInternalDeadline = ' . $isInternal . ',
		activityText       = "' . $_POST["activityText"] . '"
		WHERE activityID   = ' . $_GET["id"]);
    url_change('activity_view.php?id=' . $_GET['id']);
}
echo drawTop();
$r = db_grab("SELECT \n\t\t\t\ta.activityID, \n\t\t\t\ta.funderID, \n\t\t\t\tf.name,\n\t\t\t\tw.awardTitle,\n\t\t\t\ta.awardID, \n\t\t\t\ta.activityTitle, \n\t\t\t\ta.activityText, \n\t\t\t\ta.activityDate, \n\t\t\t\ta.activityAssignedTo, \n\t\t\t\ta.isActionItem, \n\t\t\t\ta.isComplete, \n\t\t\t\ta.isReport, \n\t\t\t\ta.isInternalDeadline, \n\t\t\t\ta.activityPostedOn\n\t\t\tFROM funders_activity a\n\t\t\tINNER JOIN funders_awards w  ON a.awardID = w.awardID\n\t\t\tINNER JOIN funders f ON w.funderID = f.funderID\n\t\t\tWHERE activityID = " . $_GET["id"]);
?>

	<script language="javascript">
	<!--
	function checkInternal() {
		if (document.frmActivity.chkActionItem.checked) {
			document.all["internal"].style.visibility = "visible";
		} else {
			document.all["report"].style.visibility = "hidden";
			document.all["internal"].style.visibility = "hidden";
			document.frmActivity.isInternal[0].checked = true;
			document.frmActivity.isInternal[1].checked = false;
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:activity_edit.php

示例11: format_post_bits

<?php

include "../include.php";
if ($posting) {
    format_post_bits("isInstancePage, isSecure, isAdmin");
    db_query("UPDATE pages SET \n\t\tname = '{$_POST["title"]}',\n\t\tisAdmin = {$_POST["isAdmin"]},\n\t\tprecedence = {$_POST["precedence"]},\n\t\tisInstancePage = {$_POST["isInstancePage"]},\n\t\tisSecure = {$_POST["isSecure"]},\n\t\tmoduleID = '{$_POST["moduleID"]}',\n\t\thelpText = '{$_POST["helpText"]}'\n\t\tWHERE id = " . $_GET["id"]);
    url_change($_POST["returnTo"]);
}
drawTop();
$r = db_grab("SELECT\n\tp.id,\n\tp.name title,\n\tp.helpText,\n\tm.id moduleID,\n\tm.name module,\n\tp.isAdmin,\n\tp.isSecure,\n\tp.precedence,\n\tp.isInstancePage,\n\tp2.url\n\tFROM pages p\n\tJOIN modules m ON p.moduleID = m.id\n\tJOIN pages p2 ON m.homePageID = p2.id\n\tWHERE p.id = " . $_GET["id"]);
$form = new intranet_form();
$form->addRow("hidden", "", "returnTo", $_GET["returnTo"]);
$form->addRow("itext", "Title", "title", $r["title"], "", true, 50);
$form->addRow("itext", "Precedence", "precedence", $r["precedence"], "", true, 50);
$form->addRow("checkbox", "Is Admin", "isAdmin", $r["isAdmin"], "", true, 50);
$form->addRow("checkbox", "Is Instance Page", "isInstancePage", $r["isInstancePage"], "", true, 50);
$form->addRow("checkbox", "Is Secure", "isSecure", $r["isSecure"], "", true, 50);
$form->addRow("select", "Module", "moduleID", "SELECT id, name FROM modules WHERE isActive = 1 ORDER BY name", $r["moduleID"], $r["moduleID"]);
//$form->addRow("text", "Module", "", "<span class='" . str_replace("/", "", $r["url"]) . " block'>" . $r["module"] . "</span>");
$form->addRow("textarea", "Help Text", "helpText", $r["helpText"]);
$form->addRow("submit", "Save Changes");
$form->draw("Edit Page Info");
drawBottom();
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:23,代码来源:edit-help.php

示例12: db_query

<?php

include "include.php";
//delete type
if (isset($_GET["deleteType"])) {
    db_query("DELETE FROM helpdesk_tickets_types WHERE id = " . $_GET["id"]);
    url_change("types.php");
}
echo drawTop();
$where1 = isset($_GET["id"]) ? "= " . $_GET["id"] : "IS NULL";
$tickets = db_query("select\r\n\t\t\tt.title,\r\n\t\t\tt.statusID,\r\n\t\t\tt.type_id,\r\n\t\t\t(SELECT COUNT(*) FROM helpdesk_tickets_followups f WHERE f.ticketID = t.id) as ticketfollowups,\r\n\t\t\tt.created_user,\r\n\t\t\tt.updated_date,\r\n\t\t\tt.id,\r\n\t\t\tt.ownerID,\r\n\t\t\tt.priorityID,\r\n\t\t\tt.created_date,\r\n\t\t\tISNULL(u.nickname, u.firstname) first,\r\n\t\t\tu.lastname last,\r\n\t\t\t(SELECT COUNT(*) FROM users_to_modules a WHERE a.module_id = 3 AND a.user_id = t.created_user) is_adminIT\r\n\t\tFROM helpdesk_tickets t\r\n\t\tINNER JOIN users   u ON u.id    = t.created_user\r\n\t\tWHERE t.type_id {$where1} {$where}\r\n\t\tORDER BY t.created_date DESC");
echo drawTicketFilter();
?>

<table class="left" cellspacing="1">
	<?php 
if (isset($_GET["id"])) {
    $type = db_grab("SELECT description name FROM helpdesk_tickets_types WHERE id = " . $_GET["id"]);
    if (db_found($tickets)) {
        echo drawHeaderRow("<a class='white' href='types.php'>Types</a> &gt; " . $type . " (" . db_found($tickets) . ")", 5, "edit name", "type_add_edit.php?id=" . $_GET["id"]);
        echo drawTicketHeader();
        while ($r = db_fetch($tickets)) {
            echo drawTicketRow($r, "type");
        }
    } else {
        if ($filtered) {
            echo drawHeaderRow("<a class='white' href='types.php'>Types</a> &gt; " . $type . " (" . db_found($tickets) . ")", 5);
            echo drawEmptyResult("No tickets have this type / month / year.", 5);
        } else {
            echo drawHeaderRow("<a class='white' href='types.php'>Types</a> &gt; " . $type . " (" . db_found($tickets) . ")", 5, "edit name", "type_add_edit.php?id=" . $_GET["id"], "delete", $request["path_query"] . "&deleteType=true");
            echo drawEmptyResult("No tickets are tagged as this type.  You can delete the type above.", 5);
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:type.php

示例13: db_query

<?php

include "../include.php";
if ($_POST) {
    db_query("UPDATE intranet_users SET password = PWDENCRYPT('{$_POST["password1"]}') WHERE userID = " . $user["id"]);
    $r = db_grab("SELECT p.url homepage FROM intranet_users u JOIN pages p ON u.homePageID = p.id WHERE u.userID = " . $user["id"]);
    url_change($r);
}
?>
<html>
	<head>
		<title>Update Your Password</title>
		<link rel="stylesheet" type="text/css" href="<?php 
echo $locale;
?>
style.css" />
		<script language="javascript" src="/javascript.js"></script>
	</head>
	<body>
<br>
<table width="600" align="center">
	<tr>
		<td>
<?php 
$form = new intranet_form();
$form->addRow("password", "Password", "password1", "", "", true);
$form->addRow("password", "Confirm", "password2", "", "", true);
$form->addRow("submit", "Save");
$form->addJavascript("(form.password1.value != form.password2.value)", "Passwords don't match!");
$form->draw("Update Your Password");
?>
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:31,代码来源:password_update.php

示例14: elseif

                $message .= '<td>' . $r . '</td></tr>';
            } elseif ($key == "officeID") {
                $r = db_grab("SELECT name FROM intranet_offices WHERE id = " . $value);
                $message .= '<td>' . $r . '</td></tr>';
            } elseif ($key == "corporationID") {
                $message .= '<td>' . db_grab("SELECT description FROM organizations WHERE id = " . $value) . '</td></tr>';
            } elseif ($key == "Additional Info") {
                $message .= '<td>' . nl2br($value) . '</td></tr>';
            } else {
                $message .= '<td>' . $value . '</td></tr>';
            }
        }
        $message .= '<tr><td colspan="2" class="bottom"><a href="http://' . $request["host"] . '/staff/add_edit.php?requestID=' . $id . '">click here</a></td></tr>';
        email_user($_josh["email_admin"], "New User Request", $message, 2);
    }
    url_change("account_confirm.php");
}
?>
<html>
	<head>
		<title>Request an Account</title>
		<link rel="stylesheet" type="text/css" href="<?php 
echo $locale;
?>
style.css" />
			<script language="javascript" type="text/javascript" src="/javascript.js"></script>
			<script language="javascript" type="text/javascript" src="<?php 
echo $locale;
?>
tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
			<script language="javascript">
开发者ID:joshreisner,项目名称:hcfa-cc,代码行数:31,代码来源:account_request.php

示例15: list

    //included
    $_josh["request"]["path_query"] = "/news/edit.php";
} else {
    //page loaded on its own
    include "../../include.php";
    if ($posting) {
        if (isset($_FILES["content"]["name"]) && !empty($_FILES["content"]["name"])) {
            list($_POST["content"], $_POST["fileTypeID"]) = file_get_uploaded("content", "docs_types");
        }
        if (isset($_FILES["image"]["name"]) && !empty($_FILES["image"]["name"])) {
            list($_POST["image"], $_POST["imageTypeID"]) = file_get_uploaded("image", "docs_types");
            //die($_POST["image"]);
        }
        $id = db_save("news_stories");
        db_checkboxes("corporationID", "news_stories_to_organizations", "newsID", "organizationID", $id);
        url_change("./?id=" . $id);
    }
    echo drawTop();
    $r = db_grab("SELECT \n\t\tn.headline,\n\t\tn.outlet,\n\t\tn.pubdate,\n\t\tn.url,\n\t\tn.description\n\t\tFROM news_stories n\n\t\tWHERE id = " . $_GET["id"]);
}
$form = new intranet_form();
$form->addCheckboxes("corporationID", "Organization", "organizations", "news_stories_to_organizations", "newsID", "organizationID", @$_GET["id"]);
$form->addRow("itext", "Headline", "headline", @$r["headline"], "", true, 255);
$form->addRow("itext", "News Outlet", "outlet", @$r["outlet"], "", true, 255);
$form->addRow("date", "Date", "pubdate", @$r["pubdate"], "", true);
$form->addRow("file", "Image<br>(optional)", "image", "", "", false);
$form->addRow("file", "File<br>(optional)", "content", "", "", true);
$form->addRow("itext", "URL<br>(optional)", "url", @$r["url"], "", false, 255);
$form->addRow("textarea-plain", "Description<br>(optional)", "description", @$r["description"]);
$form->addRow("submit", "Save Changes");
if (url_id()) {
开发者ID:Rhenan,项目名称:intranet-1,代码行数:31,代码来源:edit.php


注:本文中的url_change函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。