本文整理汇总了PHP中sotf_Utils::registerGlobalParameters方法的典型用法代码示例。如果您正苦于以下问题:PHP sotf_Utils::registerGlobalParameters方法的具体用法?PHP sotf_Utils::registerGlobalParameters怎么用?PHP sotf_Utils::registerGlobalParameters使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类sotf_Utils
的用法示例。
在下文中一共展示了sotf_Utils::registerGlobalParameters方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: raiseError
<?php
require "init.inc.php";
if (sotf_Utils::getParameter('newProg')) {
$smarty->assign("PAGETITLE", $page->getlocalized("New_prog_step1"));
} else {
$smarty->assign("PAGETITLE", $page->getlocalized("Edit_files"));
}
$page->forceLogin();
sotf_Utils::registerGlobalParameters('id', 'okURL', 'copy');
$ok = sotf_Utils::getParameter('ok');
$okURL = sotf_Utils::getParameter('okURL');
$send = sotf_Utils::getParameter('send');
$selectedUserFiles = sotf_Utils::getParameter('userfiles');
$selectedOtherFiles = sotf_Utils::getParameter('otherfiles');
$deluser = sotf_Utils::getParameter('deluser');
$delother = sotf_Utils::getParameter('delother');
$itemtoftp = sotf_Utils::getParameter('itemtoftp');
$ftptoaudio = sotf_Utils::getParameter('ftptoaudio');
$ftptoother = sotf_Utils::getParameter('ftptoother');
$ftptoicon = sotf_Utils::getParameter('ftptoicon');
$smarty->assign("OKURL", $okURL);
$prg =& new sotf_Programme($id);
// admins or owners can change files
if (!$prg->isEditable()) {
raiseError("no permission to change files in this programme");
exit;
}
if ($ok) {
if ($okURL) {
$page->redirect($okURL);
示例2: rawurlencode
<?php
require "init.inc.php";
// todo id must be sql safe
sotf_Utils::registerGlobalParameters('id', 'popup');
$smarty->assign("PAGETITLE", $page->getlocalized("get"));
$smarty->assign("OKURL", $_SERVER['PHP_SELF'] . "?id=" . rawurlencode($id));
if ($id) {
$smarty->assign('ID', $id);
$prg =& new sotf_Programme($id);
$smarty->assign_by_ref('PRG', $prg);
if ($prg->isEditable()) {
$smarty->assign('EDIT_PERMISSION', true);
}
/* rights have to be get from sotf_files table
$smarty->assign('RIGHT_DOWNLOAD',$right_download);
$smarty->assign('RIGHT_DOWNLOAD24',$right_download24);
$smarty->assign('RIGHT_LISTEN',$right_listen);
$smarty->assign('RIGHT_LISTEN24',$right_listen24);
*/
// ??? $smarty->assign('UPLOAD_PERMISSION',$page->getPermission('upload',$idObj->stationId));
$smarty->assign('OTHERFILES', $prg->listOtherFiles());
$smarty->assign('AUDIOFILES', $prg->listAudioFiles());
$smarty->assign('PAGETITLE', htmlspecialchars($prg->get('title')));
$smarty->assign('REFERENCES', $prg->getRefs());
/** stats and refs are collected via xml-rpc ??
if($localItem) {
$smarty->assign($repo->getStats($idObj));
$smarty->assign('REFS', $repo->getRefs($idObj));
}
*/