本文整理汇总了PHP中param::post方法的典型用法代码示例。如果您正苦于以下问题:PHP param::post方法的具体用法?PHP param::post怎么用?PHP param::post使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类param
的用法示例。
在下文中一共展示了param::post方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: session
require_once "inc/path.php";
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_pj = $param->post("id_pj");
if (strlen($id_pj) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$nom_pj = $param->post("upload_name_pj");
if (strlen($nom_pj) > 0) {
$source = getcwd() . "/" . _UPLOAD_DOSSIER . $nom_pj;
if (file_exists($source)) {
$xml_doc = new xml_document();
$xml_doc->ouvrir(_XML_PATH . _XML_DOCUMENT . _XML_EXT);
$xml_doc->ouvrir(_XML_PATH_PAGES . $page . "/" . _XML_DOCUMENT . _XML_EXT);
$doc = $xml_doc->get_document($id_pj);
if ($doc) {
$destination = getcwd() . "/" . $doc->get_fichier();
示例2: param
<?php
require_once "inc/path.php";
require_once "user/user.php";
inclure_inc("const", "param", "session");
define("_MSG_ERREUR_CONNEXION", "0");
define("_MSG_SUCCES_CONNEXION", "1");
$param = new param();
// Contrôle du code secret
$code_secret = $param->post(_PARAM_CODE_SECRET);
if (strlen($code_secret) > 0) {
echo _MSG_ERREUR_CONNEXION;
exit;
}
// Contrôle de la page à administrer
$page = $param->post(_PARAM_PAGE);
if (strlen($page) == 0) {
echo _MSG_ERREUR_CONNEXION;
exit;
}
// Cas particulier de la page actu
if (!strcmp($page, _HTML_PREFIXE_ACTU)) {
echo _MSG_ERREUR_CONNEXION;
exit;
}
$est_actu = preg_match("/^" . _HTML_PREFIXE_ACTU . "-[1-5]\$/", $page);
if ($est_actu == 1) {
$dossier = _XML_PATH_PAGES . _HTML_PREFIXE_ACTU;
} else {
$dossier = _XML_PATH_PAGES . $page;
}
示例3: session
}
}
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_image = $param->post("id_image");
if (strlen($id_image) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$src_image = $param->post("src_image");
if (strlen($src_image) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
if (!strcmp($src_image, _XML_SOURCE_SITE)) {
$fichier_xml = _XML_PATH . _XML_MEDIA . _XML_EXT;
} elseif (!strcmp($src_image, _XML_SOURCE_PAGE)) {
$fichier_xml = _XML_PATH_PAGES . $page . "/" . _XML_MEDIA . _XML_EXT;
示例4: session
require_once "inc/path.php";
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_sommaire = (int) $param->post("id_sommaire");
if ($id_sommaire < 1 || $id_sommaire > 5) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$no_actu = (int) $param->post("no_actu");
if ($no_actu < 0 || $no_actu > 5) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$fichier_xml = _XML_PATH_MODULES . _XML_MODULE_ACTU . _XML_EXT;
$xml_actu = new xml_module_actu();
$ret = $xml_actu->ouvrir($fichier_xml);
if ($ret) {
示例5: session
require_once "inc/path.php";
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_image = $param->post("id_image");
if (strlen($id_image) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$src_image = $param->post("src_image");
if (strlen($src_image) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
if (!strcmp($src_image, _XML_SOURCE_SITE)) {
$fichier_xml = _XML_PATH . _XML_MEDIA . _XML_EXT;
} elseif (!strcmp($src_image, _XML_SOURCE_PAGE)) {
$fichier_xml = _XML_PATH_PAGES . $page . "/" . _XML_MEDIA . _XML_EXT;
示例6: trim
return trim($ret);
}
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_texte = $param->post("id_texte");
if (strlen($id_texte) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$src_texte = $param->post("src_texte");
if (strlen($src_texte) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
if (!strcmp($src_texte, _XML_SOURCE_SITE)) {
$fichier_xml = _XML_PATH . _XML_TEXTE . _XML_EXT;
} elseif (!strcmp($src_texte, _XML_SOURCE_PAGE)) {
$fichier_xml = _XML_PATH_PAGES . $page . "/" . _XML_TEXTE . _XML_EXT;
示例7: session
require_once "inc/path.php";
$session = new session();
if (is_null($session)) {
header("Location: " . _SESSION_URL_FERMETURE);
exit;
}
$session->check_session();
$page = $session->get_session_param(_SESSION_PARAM_PAGE);
if (strlen($page) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$param = new param();
$id_cal = $param->post("id_calendrier");
if (strlen($id_cal) == 0) {
$session->fermer_session();
header("HTTP/1.0 404 Not Found");
exit;
}
$date_debut = $param->post("date_debut");
$date_fin = $param->post("date_fin");
$statut = $param->post("statut");
if (strlen($date_debut) > 0 && strlen($date_fin) > 0 && strlen($statut) > 0) {
$module_resa = new xml_module_resa();
$ret = $module_resa->ouvrir($id_cal, _XML_PATH_MODULES . $id_cal . "/" . _XML_MODULE_RESA . _XML_EXT);
if ($ret) {
list($jour_deb, $mois_deb, $an_deb) = explode("/", $date_debut);
list($jour_fin, $mois_fin, $an_fin) = explode("/", $date_fin);
$module_resa->set_info_resa($id_cal, (int) $jour_deb, (int) $mois_deb, (int) $an_deb, (int) $jour_fin, (int) $mois_fin, (int) $an_fin, $statut);