<html>
<head>
<title> GRADE DETAILS </title>
</head>
<body>
<?php
$myname=$_GET ['myname'];
$mygrade=$_GET ['mygrade'];
if(($myname=='@' or $myname=='!'))
{
echo "Special character not allowed.";
}
else if($myname==" ")
{
echo "Please enter your name";
}
else
{
switch($mygrade)
{
case "";
echo "you did not enter grade";
break;
case A;
echo "Increment 30% of basic salary";
break;
case B;
echo "Increment 10% of basic salary";
break;
default;
echo"Wrong Grade";
break;
}
}
?>
</body>
</html>
我想在我的if else statement..i嘗試了很多方法來設置多個條件,但仍然沒有工作...我希望有人能幫助我。沒有用我的Switch Case,但問題只在IF ELSE..PLS HELP.Thanks。如何設置多個條件,如果else語句PHP
這是一個純PHP?沒有框架? –
即時通訊使用HTML框架,但我沒有發送HTML代碼在這裏.. –