本文整理汇总了PHP中client::getName方法的典型用法代码示例。如果您正苦于以下问题:PHP client::getName方法的具体用法?PHP client::getName怎么用?PHP client::getName使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类client
的用法示例。
在下文中一共展示了client::getName方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: client
function test_getName()
{
//Arrange
$name = "Tony awesome";
$stylist_id = 1;
$id = 1;
$visits = 3;
$description = "Smells bad";
$test_client = new client($name, $stylist_id, $id, $visits, $description);
//Act
$result = $test_client->getName();
//Assert
$this->assertEquals($name, $result);
}
示例2: client
include "client.php";
session_start();
$user = $_SESSION["id"];
$date = $_SESSION["date"];
$class = $_SESSION["class"];
$var = 0;
if (!isset($_SESSION['schedule']) && empty($_SESSION['schedule'])) {
$_SESSION["schedule"] = $_GET['schedule'];
}
if (!isset($_SESSION['station']) && empty($_SESSION['station'])) {
$_SESSION["station"] = $_GET['name'];
}
$station = $_SESSION['station'];
$schedule = $_SESSION['schedule'];
$client = new client();
$clientName = $client->getName($user);
if ($client->exists($clientName)) {
echo "<table style=\"border:1px solid black; border-collapse:collapse;\" width=\"1350\" height=\"100\"> ";
echo "<th width=\"200\" bgcolor=\"#0000FF\">Customer Details</th>";
$client->details($clientName);
if (isset($_POST['submit'])) {
$_SESSION["seats"] = $_POST['seat'];
$var = $_SESSION["seats"];
echo "Number of tickets : " . $var . "</br>";
$cost = $client->CheckBooking($schedule, $class, $var);
}
if (isset($_POST['sub'])) {
$client->makeBooking($schedule, $class, $_SESSION["seats"], $date, $user);
header('Location: CustomerDet.php');
}
}