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


PHP isActionAccessible函数代码示例

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


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

示例1: getHighestGroupedAction

it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/Planner/planner_view_full_submit_edit.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Get action with highest precendence
    $highestAction = getHighestGroupedAction($guid, $_GET["q"], $connection2);
    if ($highestAction == FALSE) {
        print "<div class='error'>";
        print _("The highest grouped action cannot be determined.");
        print "</div>";
    } else {
        $viewBy = $_GET["viewBy"];
        $subView = $_GET["subView"];
        if ($viewBy != "date" and $viewBy != "class") {
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:planner_view_full_submit_edit.php

示例2: PDO

include '../../functions.php';
include '../../config.php';
//New PDO DB connection
try {
    $connection2 = new PDO("mysql:host={$databaseServer};dbname={$databaseName};charset=utf8", $databaseUsername, $databasePassword);
    $connection2->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $connection2->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);
} catch (PDOException $e) {
    echo $e->getMessage();
}
@session_start();
//Set timezone from session variable
date_default_timezone_set($_SESSION[$guid]['timezone']);
$gibbonSchoolYearID = $_POST['gibbonSchoolYearID'];
$URL = $_SESSION[$guid]['absoluteURL'] . '/index.php?q=/modules/' . getModuleName($_POST['address']) . '/badges_grant_add.php&gibbonPersonID2=' . $_GET['gibbonPersonID2'] . '&badgesBadgeID2=' . $_GET['badgesBadgeID2'] . "&gibbonSchoolYearID={$gibbonSchoolYearID}";
if (isActionAccessible($guid, $connection2, '/modules/Badges/badges_grant_add.php') == false) {
    //Fail 0
    $URL .= '&return=error0';
    header("Location: {$URL}");
} else {
    //Proceed!
    if (isset($_POST['gibbonPersonIDMulti'])) {
        $gibbonPersonIDMulti = $_POST['gibbonPersonIDMulti'];
    } else {
        $gibbonPersonIDMulti = null;
    }
    $badgesBadgeID = $_POST['badgesBadgeID'];
    $date = $_POST['date'];
    $comment = $_POST['comment'];
    if ($gibbonPersonIDMulti == null or $date == '' or $badgesBadgeID == '' or $gibbonSchoolYearID == '') {
        //Fail 3
开发者ID:GibbonEdu,项目名称:module-badges,代码行数:31,代码来源:badges_grant_addProcess.php

示例3: getModuleName

the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
$_SESSION[$guid]["report_student_emergencySummary.php_choices"] = "";
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/Library/report_catalogSummary.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > </div><div class='trailEnd'>" . _('Catalog Summary') . "</div>";
    print "</div>";
    print "<h3>";
    print _("Search & Filter");
    print "</h3>";
    //Get current filter values
    $ownershipType = NULL;
    if (isset($_POST["ownershipType"])) {
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:report_catalogSummary.php

示例4: date_default_timezone_set

@session_start();
//Set timezone from session variable
date_default_timezone_set($_SESSION[$guid]['timezone']);
//Search & Filters
$search = null;
if (isset($_GET['search'])) {
    $search = $_GET['search'];
}
$filter2 = null;
if (isset($_GET['filter2'])) {
    $filter2 = $_GET['filter2'];
}
$visualAssessmentGuideID = $_POST['visualAssessmentGuideID'];
$URL = $_SESSION[$guid]['absoluteURL'] . '/index.php?q=/modules/' . getModuleName($_POST['address']) . "/guides_manage_delete.php&visualAssessmentGuideID={$visualAssessmentGuideID}&search={$search}&filter2={$filter2}";
$URLDelete = $_SESSION[$guid]['absoluteURL'] . '/index.php?q=/modules/' . getModuleName($_POST['address']) . "/guides_manage.php&search={$search}&filter2={$filter2}";
if (isActionAccessible($guid, $connection2, '/modules/Visual Assessment/guides_manage_delete.php') == false) {
    //Fail 0
    $URL .= '&return=error0';
    header("Location: {$URL}");
} else {
    //Get action with highest precendence
    $highestAction = getHighestGroupedAction($guid, $_POST['address'], $connection2);
    if ($highestAction == false) {
        //Fail2
        $URL .= '&return=error2';
        header("Location: {$URL}");
    } else {
        if ($highestAction != 'Manage Assessment Guides_all' and $highestAction != 'Manage Assessment Guides_myDepartments') {
            //Fail 0
            $URL .= '&return=error0';
            header("Location: {$URL}");
开发者ID:GibbonEdu,项目名称:module-visualAssessment,代码行数:31,代码来源:guides_manage_deleteProcess.php

示例5: getModuleName

it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/School Admin/externalAssessments_manage_edit.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/externalAssessments_manage.php'>" . _('Manage External Assessments') . "</a> > </div><div class='trailEnd'>" . _('Edit External Assessment') . "</div>";
    print "</div>";
    if (isset($_GET["updateReturn"])) {
        $updateReturn = $_GET["updateReturn"];
    } else {
        $updateReturn = "";
    }
    $updateReturnMessage = "";
开发者ID:dpredster,项目名称:core,代码行数:31,代码来源:externalAssessments_manage_edit.php

示例6: PDO

try {
    $connection2 = new PDO("mysql:host={$databaseServer};dbname={$databaseName};charset=utf8", $databaseUsername, $databasePassword);
    $connection2->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $connection2->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);
} catch (PDOException $e) {
    echo $e->getMessage();
}
@session_start();
//Set timezone from session variable
date_default_timezone_set($_SESSION[$guid]["timezone"]);
$value = $_POST["value"];
$descriptor = $_POST["descriptor"];
$sequenceNumber = $_POST["sequenceNumber"];
$gibbonScaleID = $_POST["gibbonScaleID"];
$URL = $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_POST["address"]) . "/gradeScales_manage_edit_grade_add.php&gibbonScaleID={$gibbonScaleID}";
if (isActionAccessible($guid, $connection2, "/modules/School Admin/gradeScales_manage_edit_grade_add.php") == FALSE) {
    //Fail 0
    $URL .= "&addReturn=fail0";
    header("Location: {$URL}");
} else {
    //Proceed!
    //Validate Inputs
    if ($gibbonScaleID == "" or $value == "" or $descriptor == "" or $sequenceNumber == "") {
        //Fail 3
        $URL .= "&addReturn=fail3";
        header("Location: {$URL}");
    } else {
        //Check unique inputs for uniquness
        try {
            $data = array("value" => $value, "sequenceNumber" => $sequenceNumber, "gibbonScaleID" => $gibbonScaleID);
            $sql = "SELECT * FROM gibbonScaleGrade WHERE ((value=:value) OR (sequenceNumber=:sequenceNumber)) AND gibbonScaleID=:gibbonScaleID";
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:gradeScales_manage_edit_grade_addProcess.php

示例7: getModuleName

it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/Timetable/report_viewAvailableSpaces.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > </div><div class='trailEnd'>" . _('View Available Spaces') . "</div>";
    print "</div>";
    print "<h2>";
    print _("Choose Options");
    print "</h2>";
    $gibbonTTID = NULL;
    if (isset($_GET["gibbonTTID"])) {
        $gibbonTTID = $_GET["gibbonTTID"];
    }
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:report_viewAvailableSpaces.php

示例8: getModuleName

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
if (isActionAccessible($guid, $connection2, "/modules/User Admin/userFields_delete.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/User Admin/userFields.php'>" . _('Manage Custom Fields') . "</a> > </div><div class='trailEnd'>" . _('Delete Custom Field') . "</div>";
    print "</div>";
    if (isset($_GET["deleteReturn"])) {
        $deleteReturn = $_GET["deleteReturn"];
    } else {
        $deleteReturn = "";
    }
    $deleteReturnMessage = "";
开发者ID:dpredster,项目名称:core,代码行数:30,代码来源:userFields_delete.php

示例9: getHighestGroupedAction

it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/Markbook/markbook_edit_targets.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    $highestAction = getHighestGroupedAction($guid, $_GET["q"], $connection2);
    if ($highestAction == FALSE) {
        print "<div class='error'>";
        print _("The highest grouped action cannot be determined.");
        print "</div>";
    } else {
        //Check if school year specified
        $gibbonCourseClassID = $_GET["gibbonCourseClassID"];
        if ($gibbonCourseClassID == "") {
            print "<div class='error'>";
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:markbook_edit_targets.php

示例10: getModuleName

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
if (isActionAccessible($guid, $connection2, "/modules/User Admin/family_manage_edit_editChild.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/User Admin/family_manage.php'>" . _('Manage Families') . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/User Admin/family_manage_edit.php&gibbonFamilyID=" . $_GET["gibbonFamilyID"] . "'>" . _('Edit Family') . "</a> > </div><div class='trailEnd'>" . _('Edit Child') . "</div>";
    print "</div>";
    if (isset($_GET["updateReturn"])) {
        $updateReturn = $_GET["updateReturn"];
    } else {
        $updateReturn = "";
    }
    $updateReturnMessage = "";
开发者ID:actcattest001,项目名称:core,代码行数:30,代码来源:family_manage_edit_editChild.php

示例11: getModuleName

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
if (isActionAccessible($guid, $connection2, "/modules/School Admin/schoolYearTerm_manage_add.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/schoolYearTerm_manage.php'>" . _('Manage Terms') . "</a> > </div><div class='trailEnd'>" . _('Add Term') . "</div>";
    print "</div>";
    if (isset($_GET["addReturn"])) {
        $addReturn = $_GET["addReturn"];
    } else {
        $addReturn = "";
    }
    $addReturnMessage = "";
开发者ID:dpredster,项目名称:core,代码行数:30,代码来源:schoolYearTerm_manage_add.php

示例12: getModuleName

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
if (isActionAccessible($guid, $connection2, "/modules/Timetable Admin/course_manage_class_add.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/course_manage.php&gibbonSchoolYearID=" . $_GET["gibbonSchoolYearID"] . "'>" . _('Manage Courses & Classes') . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/course_manage_edit.php&gibbonCourseID=" . $_GET["gibbonCourseID"] . "&gibbonSchoolYearID=" . $_GET["gibbonSchoolYearID"] . "'>" . _('Edit Course & Classes') . "</a> > </div><div class='trailEnd'>" . _('Add Class') . "</div>";
    print "</div>";
    if (isset($_GET["addReturn"])) {
        $addReturn = $_GET["addReturn"];
    } else {
        $addReturn = "";
    }
    $addReturnMessage = "";
开发者ID:dpredster,项目名称:core,代码行数:30,代码来源:course_manage_class_add.php

示例13: PDO

*/
include "../../functions.php";
include "../../config.php";
//New PDO DB connection
try {
    $connection2 = new PDO("mysql:host={$databaseServer};dbname={$databaseName};charset=utf8", $databaseUsername, $databasePassword);
    $connection2->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $connection2->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);
} catch (PDOException $e) {
    echo $e->getMessage();
}
@session_start();
//Set timezone from session variable
date_default_timezone_set($_SESSION[$guid]["timezone"]);
$URL = $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_POST["address"]) . "/externalAssessmentSettings.php";
if (isActionAccessible($guid, $connection2, "/modules/School Admin/alertLevelSettings.php") == FALSE) {
    //Fail 0
    $URL .= "&updateReturn=fail0";
    header("Location: {$URL}");
} else {
    $gibbonYearGroupID = $_POST["gibbonYearGroupID"];
    $gibbonExternalAssessmentID = $_POST["gibbonExternalAssessmentID"];
    if (isset($_POST["category"])) {
        $category = $_POST["category"];
    }
    $count = 0;
    $primaryExternalAssessmentByYearGroup = array();
    foreach ($gibbonYearGroupID as $year) {
        if (isset($gibbonExternalAssessmentID[$count]) and isset($category[$count]) and $category[$count] != "") {
            $primaryExternalAssessmentByYearGroup[$year] = $gibbonExternalAssessmentID[$count] . "-" . $category[$count];
        } else {
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:externalAssessmentSettingsProcess.php

示例14: getModuleName

it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
@session_start();
//Module includes
include "./modules/" . $_SESSION[$guid]["module"] . "/moduleFunctions.php";
if (isActionAccessible($guid, $connection2, "/modules/Students/report_rollGroupSummary.php") == FALSE) {
    //Acess denied
    print "<div class='error'>";
    print _("You do not have access to this action.");
    print "</div>";
} else {
    //Proceed!
    print "<div class='trail'>";
    print "<div class='trailHead'><a href='" . $_SESSION[$guid]["absoluteURL"] . "'>" . _("Home") . "</a> > <a href='" . $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_GET["q"]) . "/" . getModuleEntry($_GET["q"], $connection2, $guid) . "'>" . _(getModuleName($_GET["q"])) . "</a> > </div><div class='trailEnd'>" . _('Roll Group Summary') . "</div>";
    print "</div>";
    $today = time();
    //Get roll groups in current school year
    try {
        $data = array("gibbonSchoolYearID" => $_SESSION[$guid]["gibbonSchoolYearID"]);
        $sql = "SELECT * FROM gibbonRollGroup WHERE gibbonSchoolYearID=:gibbonSchoolYearID ORDER BY name";
        $result = $connection2->prepare($sql);
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:report_rollGroupSummary.php

示例15: catch

    $connection2->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
    $connection2->setAttribute(PDO::ATTR_DEFAULT_FETCH_MODE, PDO::FETCH_ASSOC);
} catch (PDOException $e) {
    echo $e->getMessage();
}
@session_start();
//Set timezone from session variable
date_default_timezone_set($_SESSION[$guid]["timezone"]);
$name = $_POST["name"];
$nameShort = $_POST["nameShort"];
$timeStart = $_POST["timeStart"];
$timeEnd = $_POST["timeEnd"];
$type = $_POST["type"];
$gibbonTTColumnID = $_POST["gibbonTTColumnID"];
$URL = $_SESSION[$guid]["absoluteURL"] . "/index.php?q=/modules/" . getModuleName($_POST["address"]) . "/ttColumn_edit_row_add.php&gibbonTTColumnID={$gibbonTTColumnID}";
if (isActionAccessible($guid, $connection2, "/modules/Timetable Admin/ttColumn_edit_row_add.php") == FALSE) {
    //Fail 0
    $URL .= "&addReturn=fail0";
    header("Location: {$URL}");
} else {
    //Proceed!
    //Validate Inputs
    if ($gibbonTTColumnID == "" or $name == "" or $nameShort == "" or $timeStart == "" or $timeEnd == "" or $type == "") {
        //Fail 3
        $URL .= "&addReturn=fail3";
        header("Location: {$URL}");
    } else {
        //Check unique inputs for uniquness
        try {
            $data = array("name" => $name, "nameShort" => $nameShort, "gibbonTTColumnID" => $gibbonTTColumnID);
            $sql = "SELECT * FROM gibbonTTColumnRow WHERE ((name=:name) OR (nameShort=:nameShort)) AND gibbonTTColumnID=:gibbonTTColumnID";
开发者ID:actcattest001,项目名称:core,代码行数:31,代码来源:ttColumn_edit_row_addProcess.php


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