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


PHP Sql::connectToDatabase方法代码示例

本文整理汇总了PHP中Sql::connectToDatabase方法的典型用法代码示例。如果您正苦于以下问题:PHP Sql::connectToDatabase方法的具体用法?PHP Sql::connectToDatabase怎么用?PHP Sql::connectToDatabase使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Sql的用法示例。


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

示例1: setThresholdPeriod

 public function setThresholdPeriod($thresholdPeriod)
 {
     $this->thresholdPeriodYears = $thresholdPeriod;
     $s = new Sql();
     global $databaseName;
     $connectValue = $s->connectToDatabase($databaseName);
     $row = $s->insertToConfig($connectValue, $thresholdPeriod);
 }
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:8,代码来源:threshold.php

示例2: __construct

 public function __construct($name)
 {
     $s = new Sql();
     $connect = $s->connectToDatabase('recruit');
     $jbID = $s->createJobPosition($connect, $name);
     $this->jpID = $jbID;
     $this->jobPositionName = $name;
 }
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:8,代码来源:jobPosition.php

示例3: getStatus

 public function getStatus()
 {
     $s = new Sql();
     $connect = $s->connectToDatabase('recruit');
     $data = mysqli_query($connect, "SELECT sessionstatus.status FROM sessionstatus,recruitmentsession WHERE recruitmentsession.sessionStatusID=sessionstatus.sessionStatusID AND RSID='{$this->RSID}'");
     $row = $data->fetch_row();
     return $row[0];
 }
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:8,代码来源:RecruitmentSession.php

示例4: __construct

 public function __construct($name, $jb)
 {
     $s = new Sql();
     $connectValue = $s->connectToDatabase($databaseName);
     $this->name = $name;
     $this->dateCreated = date("Y-m-d");
     $this->jobPosition = $jb;
     $RSID = $s->setSessionQuery($connectValue, $name, $this->dateCreated, $jb);
     echo "RecruitmentSession works " . $RSID . "";
     //$recSesID = $RSID;
     // Set session variables
     //$_SESSION["rSessionID"] = $RSID;
 }
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:13,代码来源:RecruitmentSessionold.php

示例5: Sql

			},
			function(data)
			{
				//alert(interviewname);
			}
		);
	});
});

</script>

<?php 
require_once "Sql.php";
require_once "GlobalVariables.php";
$s = new Sql();
$connect = $s->connectToDatabase($databaseName);
global $db, $user, $pass;
try {
    $dbh = new PDO($db, $user, $pass);
    $loadStatus = $dbh->prepare("SELECT sessionStatusID,status FROM sessionStatus");
    if ($loadStatus->execute()) {
        $loadStatus->setFetchMode(PDO::FETCH_ASSOC);
    }
} catch (Exception $error) {
    echo '<p>', $error->getMessage(), '</p>';
}
?>

</head>

<body>
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:31,代码来源:candidateList.php

示例6: count

					txt  += "<br>The path of the selected file: " + x.value; // If the browser does not support the files property, it will return the path of the selected file instead. 
				}
			}
		}
	</script>
<?php 
if (isset($_GET["id"])) {
    $sessionID = $_GET["id"];
}
if (isset($_FILES['fileToUpload'])) {
    $file = $_FILES['fileToUpload'];
    $fileCount = count($file["name"]);
    //Used only for viewing purposes
    $text = "";
    $s = new Sql();
    $connectValue = $s->connectToDatabase($databaseName);
    for ($i = 0; $i < $fileCount; $i++) {
        $cv = $s->createNewCV($connectValue, $i);
        $candidate = null;
        //$sessionID = $_SESSION['rSessionID'];
        //if (isset($_COOKIE['rSessionID'])){
        //$sessionID = $_COOKIE['rSessionID'];
        //}
        //echo $_GET["id"];
        //$sessionID = $_GET["id"];
        //	$sessionID="RS055";
        echo "<ul id=\"feedBack\" class=\"list-group\">";
        if ($cv != null) {
            $candidate = $s->createNewCandidate($connectValue, $cv, $sessionID);
            echo "<li  class=\"list-group-item list-group-item-success\">" . $file["name"][$i] . " upload is successful</li>";
        } else {
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:31,代码来源:uploadCVs.php

示例7: Sql

 function __construct()
 {
     $s = new Sql();
     $this->connectValue = $s->connectToDatabase('recruit');
 }
开发者ID:vbalalla,项目名称:project_CV_and_Recruitment_Management,代码行数:5,代码来源:Search.php


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