Org Defined ID,Username,FirstName,LastName,Attempt #,Attempt Start,Attempt End,Section #,Q #,Q Type,Q Title,Q Text,Bonus?,Difficulty,Answer,Answer Match,Score,Out Of,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,1,,,Multiple Choice Questions [20 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""is.html"">IS</a> <br> <a href=""../../index.html"">SMU</a>",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""../is.html"">IS</a> <br> <a href=""../../index.html"">SMU</a>",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""is.html"">IS</a> <br> <a href=""www.smu.edu.sg"">SMU</a>",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""../is.html"">IS</a> <br> <a href=""www.smu.edu.sg"">SMU</a>",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,None of the options ,Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,5,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,2,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,1,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,4,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,3,Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1[0] == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  } ",Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($intake as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1 == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  }  ",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1 == $key2){             $result[$value1] = [$key1, $value2];         }     } } ",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){    foreach ($intake as $key2 => $value2){         if ($key1 == $key2){             $result[$value1[0]] = [$key1, $value2];         }     } } ",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($intake as $key1 => $value1){     foreach ($courses as $key2 => $value2){         if ($value1[0] == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  } ",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Alan, James",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Alan, Ben",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Bob, James",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Bob, Ben",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,None of the above,Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,284,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,6284,Checked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,628,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,178,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,28,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,10 20 31,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 20 31,Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,31 21 31 ,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 20 30,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 21 30,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,2,Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,5,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,4,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,1,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,3,UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,None of the options,Checked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-d-g-i-,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-d-f-h-j- ,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-e-j-,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-e-,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,2060,0",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,720,60",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,6020,17",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,6020,7",Checked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,2017,60",UnChecked,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will show David Lee,Checked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will show David,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,An empty page will be shown,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,An error will occur,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will be empty,UnChecked,0,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,1,,,Summary:,,Multiple Choice Questions [20 marks],,,,,,14,20
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,2,,,Section A [10 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,11,WR,,"[Part A]  Use the following directory structure to answer the question. The folder is113 can be found under the web root folder.   is113      |-- q1          |-- cars.html          |-- display1.php         |-- display2.php   The web page car.html has a single select dropdown list and two independent checkboxes. The value “Audi” is selected by default.     Clicking on the “Display All” submit button will take the user to page display1.php, which will display the result. No hard coding is allowed.Complete the missing codes for car.html.  <!DOCTYPE html> <body>      <form action = ""(A)""  method = ""(B)"" >         <h3> Car Brands: </h3>                  <select name = 'car' size = ""(C)"" >             <option value=""Audi"" selected>Audi</option>             <option value=""BMW"">BMW</option>             <option value=""Chevrolet"">Chevrolet</option>             <option value=""Maserati"">Maserati</option>         </select>         <br><br>          <h3> Types of Services: </h3>         <input type=""checkbox"" name=""car_wash"" value=""yes"" > Car Wash         <input type=""checkbox"" name=""major_service"" value=""yes""> Major Service                <br><br>          <input type=""submit"" value= ""(D)"" >     </form>  </body> </html> ",FALSE,1,(A)display1.php (B)POST (C)multiple (D)Display All,,1.5,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,12,WR,,"[Part B]  Complete display1.php as per the scenarios below.     When the user chooses a car brand and specifies the desired services, the application will present the basic cost and the total hours needed for servicing the car. The total service hours required for the car can be computed by multiplying the multiplier with the hours allocated for each specific service. $charges is an associative array where the brand of the car serves as the key, and the corresponding value is an indexed array containing [<basic cost>, <multiplier for each service type hour>]. The variable $CAR_WASH_TIME represents the hours for a car wash. The variable $MAJOR_SERVICE_TIME represents the hours for a major service.        car.html   display1.php                                      When the user did not select any services, display1.php will display “Choose at least 1 service.”.        car.html   display1.php            ",FALSE,1,"<?php       $charges = [         ""Audi"" => [100, 3],         ""BMW"" => [250, 1.5],         ""Chevrolet"" => [300, 2],         ""Maserati"" => [350, 2.5]     ];       $CAR_WASH_TIME = 3;     $MAJOR_SERVICE_TIME = 5;          $car = $_POST[""car""];       // Write your code below     $car_wash = '';     $major_service = '';     if(isset($_POST['car_wash']))     {          $car_wash = $_POST['car_wash'];     }       if(isset($_POST['major_service']))     {          $major_service = $_POST['major_service'];     }       if(!isset($_POST['car_wash']) && !isset($_POST['major_service']))     {         echo ""Please choose at least 1 service"";     }     else     {         $basic_cost = $charges[$car][0];         $total_hours = 0;         if($car_wash == ""yes"")         {             $total_hours += $CAR_WASH_TIME;         }         if($major_service == ""yes"")         {             $total_hours += $MAJOR_SERVICE_TIME * $charges[$car][1];         }         echo ""<p>The basic cost is ($): $basic_cost<br>The total time required (hr): $total_hours</p>"";     }       ?>",,0,4,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,13,WR,,"[Part C]  Complete display2.php  as per the scenarios below.   Now, clicking the ‘Display All’ submit button in car.html will take the user to page display2.php. The rest of car.html remains unchanged.    The selected car brand will be presented in bold. The number of '*' characters displayed depends on whether the user has chosen a car wash or a major service, utilizing the values from $CAR_WASH_TIME or $MAJOR_SERVICE_TIME. In case the user hasn't specified the type of service, it will be represented as ""?"". The remaining boxes will be displayed with '-'."" No hardcoding is allowed.        car.html   display2.php                                             ",FALSE,1,"<?php     $charges = [         ""Audi"" => [100, 3],         ""BMW"" => [250, 1.5],         ""Chevrolet"" => [300, 2],         ""Maserati"" => [350, 2.5]     ];       $CAR_WASH_TIME = 3;     $MAJOR_SERVICE_TIME = 5;       $car = $_POST[""car""];       echo ""<table border=1>"";     echo ""<tr>             <th> Brand </th>             <th> Car Wash Time </th>             <th> Major Service </th>           </tr>"";       // Write your code below     $car_wash = '';     $major_service = '';     if(isset($_POST['car_wash']))     {          $car_wash = $_POST['car_wash'];     }       if(isset($_POST['major_service']))     {          $major_service = $_POST['major_service'];     }       if(isset($_POST['car_wash']) || isset($_POST['major_service']))     {         foreach($charges as $car_type)         {             if($car_type == $car)             {                 echo ""<tr><th>$car_type</th>"";                 if($car_wash == ""yes"")                 {                      $num_stars_str = ""*"" * $CAR_WASH_TIME;                      echo ""<td>$num_stars_str</td>"";                 }                 else {                       echo ""<td>?</td>"";                 }                   if($major_service == ""yes"")                 {                      $num_stars_str = ""*"" * $MAJOR_SERVICE_TIME;                      echo ""<td>$num_stars_str</td>"";                 }                 else {                       echo ""<td>?</td>"";                 }                 echo ""</tr>"";             }             else             {                 echo ""<tr><td>$car_type</td><td>-</td><td>-</td></tr>"";             }     }              }      ?>",,3,4,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,2,,,Summary:,,Section A [10 marks],,,,,,4.5,10
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,3,,,Section B [10 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,14,WR,,"[Part A]  Use the following directory structure to answer the question. The folder is113 can be found under the web root folder.    is113      |-- q2          |-- Olympics.php          |-- display.php   Complete class Olympics such that it  Has three properties  private property $year private property $country private property $sports       Has a public constructor that  takes in three parameters:  $year is a string $country is a string $sports is an indexed array of strings   initializes properties $year, $country and $sports.       Has four public methods  getYear() is a getter method that returns the year. getCountry() is a getter method that returns the country. getSports() is a getter method that returns the sports checkSport($name_of_sport)  takes an input string $name_of_sport returns $year if the $name_of_sport matches an element in $sports array, else return boolean false.       ",FALSE,1,"<?php       class Olympics{           // Your code goes here         private $year;         private $country;         private $sports;                  public function __construct($year, $country, $sports)         {             $this->year = $year;             $this->country = $country;             $this->sports = $sports;         }           public function getYear()         {             return $this->year;         }         public function getCountry()         {             return $this->country;         }        public function getSports()         {             return $this->sports;         }        public function checkSport($name_of_sport)         {             if (in_array($name_of_sport, $this->sports)             {                 return true;             }             else             {                 return false;             }         }        }   ?>",,0,5,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,15,WR,,[Part B]  Complete display.php such that it displays the following without hardcoding.   Use the data from $olympics_List to display the sport and the number of years the sport is featured as an event in the Olympics. The list of sports need not be sorted.,FALSE,1,"<?php       require_once ""Olympics.php"";          $olympics_List = [ new Olympics(""2016"", ""Rio"", [""Athletics"", ""Fencing"", ""Football""]),                                   new Olympics(""2020"", ""Tokyo"", [""Archery"", ""Rowing""]),                                   new Olympics(""2024"", ""Paris"", [""Archery"", ""Fencing""])];       echo ""<h3> List of Sports </h3>"";          // Your code goes here     $sports_dict = [];     foreach($olympics_List as $olympic_obj)     {         $olympic_obj_sports = $olympic_obj->getSports();         foreach($olympic_obj_sports as $sport)         {             if(!array_key_exists($sport, $sports_dict)             {                 $sports_dict[$sport] = 1;             }             else             {                 $tmp = $sports_dict[$sport];                 $tmp = $tmp + 1;                 $sports_dict[$sport] = $tmp;             }         }     }       echo ""<h1>List of Sports</h1>"";     echo ""<br>"";     echo ""<ul>"";     foreach($sports_dict as $sport_key => $qty)     {         echo ""<li>$sport_key - $qty</li>"";     }     echo ""</ul>"";              ?>",,0,5,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,3,,,Summary:,,Section B [10 marks],,,,,,0,10
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,4,,,Section C [10 marks],,,,"<p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 19px;""><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</span></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><br/><br/></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Refer to the following directory structure to answer the question. The folder is113exam can be found under webroot.</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">is113exam –</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">&#160;&#160;&#160;&#160; |-- q3</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- model</span></p> <p style=""margin: 0cm 0cm 0cm 108pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- common.php</span></p> <p style=""margin: 0cm 0cm 0cm 108pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- ConnectionManager.php<br/>|-- PetSitter.php<br/>|-- PetSitterDAO.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- process_search.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- process_update.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- search.html</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- update.html</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- view_all.php</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">You are part of a team that creates a web application that allows the user to view pet sitters. Your teammates have already completed the following, which you will be able to reuse:</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;<br/><br/></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>PetSitter<br/><br/></b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Private Properties</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">fullname</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Full name of a pet sitter</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">hourlyRate</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Hourly rate (SGD) charged by a pet sitter</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">petType</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Pet type that a pet sitter is capable of handling</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">mobileNumber</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Singapore mobile number without +65 (e.g. 98751234)</span></li> </ul> </li> </ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">__construct(<span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$fullname, $hourlyRate, $petType, $mobileNumber</span>)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Constructor that initializes a PetSitter object&#39;s properties.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getFullname()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property fullname</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getHourlyRate()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property hourlyRate</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getPetType()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property petType</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getMobileNumber()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property mobileNumber</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">setHourlyRate($hourlyRate)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Takes in an input parameter $hourlyRate</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Set the value of property hourlyRate to $hourlyRate</span></li> </ul> </li> </ul> <p style=""margin: 0cm 0cm 0cm 90pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;<br/><br/></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>PetSitterDAO<br/><br/></b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">retrieveAll()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Retrieves all data from the database table petsitter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an Indexed Array of PetSitter objects.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an empty array if there are no pet sitters.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">retrieveByHourlyRatePetType($maximumHourlyRate, $petType)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an Indexed Array of PetSitter objects.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the pet sitters whose:</span> <ul style=""list-style-type: square;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">hourlyRate is less than or equal to the specified input parameter <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$maximumHourlyRate</span> <b><i><u>and</u></i></b></span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">petType is equal to <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$petType</span></span> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Valid values for input parameter $petType:</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#39;Cat&#39;</b> for cats</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#39;Dog&#39;</b> for dogs</span></li> </ul> </li> </ul> </li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an empty array if there are no matching pet sitters.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">updateHourlyRate($petSitterObject)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Takes in a PetSitter object as an input parameter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Using the properties fullname and hourlyRate from <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$petSitterObject</span>, updates the corresponding record in the database table petsitter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns:</span> <ul style=""list-style-type: square;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Boolean TRUE if the update is successful <i><u>or</u></i></span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Boolean FALSE if the update is <u>not</u> successful.</span></li> </ul> </li> </ul> </li> </ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""></ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">The &quot;q3&quot; database has a table called <b>petsitter</b>. The table definition and sample data are shown below:<br/><br/></span></li> </ul> <table cellpadding=""0"" cellspacing=""0"" border=""1"" class=""MsoTableGrid"" style=""margin-left: 8.75pt;border-collapse: collapse;border: none;""> <tbody> <tr> <td valign=""top"" style=""width: 530.75pt;border: solid windowtext 1.0pt;padding: 0cm 5.4pt 0cm 5.4pt;""> <p style=""margin: 0cm;text-align: center;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;"">CREATE <b>petsitter </b>TABLE and Data Population script</span></p> </td> </tr> <tr> <td valign=""top"" style=""width: 530.75pt;border: solid windowtext 1.0pt;border-top: none;padding: 0cm 5.4pt 0cm 5.4pt;""> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">CREATE TABLE petsitter (</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; fullname&#160;&#160;&#160;&#160;&#160; VARCHAR(100) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; hourlyRate&#160;&#160;&#160; INT NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; petType&#160;&#160;&#160;&#160;&#160;&#160; VARCHAR(100) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; mobileNumber&#160; VARCHAR(8) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; primary key (fullname)</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160;</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Bustin Jieber&#39;, 25, &#39;Cat&#39;, &#39;82821111&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Gelena Somez&#39;, 30, &#39;Dog&#39;, &#39;93432222&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Wanye Kest&#39;, 40, &#39;Cat&#39;, &#39;98761234&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Saylor Twift&#39;, 50, &#39;Dog&#39;, &#39;81236789&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Griana Arande&#39;, 60, &#39;Cat&#39;, &#39;98981212&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Ciley Myrus&#39;, 35, &#39;Dog&#39;, &#39;89893434&#39;);</span></p> </td> </tr> </tbody> </table> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><b>&#160;</b></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>ConnectionManager</b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">connect()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Connects to the database &quot;q3&quot;.</span></li> </ul> </li> </ul> <p style=""margin: 0cm 0cm 0cm 90pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;</span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">common.php – refer to the Appendix.</span></li> </ul> <p style=""padding: 0cm;border-top: none;border-right: none;border-left: none;border-image: initial;border-bottom: 1pt solid windowtext;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p>",,,,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,16,FIB,,"[Part A] Page view_all.php displays information of all pet sitters (as retrieved from the database table petsitter). Complete view_all.php such that the list of pet sitters is displayed as shown below: Given the initial content of the ""q3"" database (see the SQL script above), view_all.php will display the following:   If there are NO pet sitters to display, view_all.php must display the following:   ----------------------------Complete (A) and (B) in  view_all.php indicated below.* You will complete (C) in the next question.      <?php      require_once ""model/common.php"";   $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting   if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>         (A)  _______    (B)  _______ ",FALSE,1,Answer for blank # 1,PetSitterDAO,0.25,0.75,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,16,FIB,,"[Part A] Page view_all.php displays information of all pet sitters (as retrieved from the database table petsitter). Complete view_all.php such that the list of pet sitters is displayed as shown below: Given the initial content of the ""q3"" database (see the SQL script above), view_all.php will display the following:   If there are NO pet sitters to display, view_all.php must display the following:   ----------------------------Complete (A) and (B) in  view_all.php indicated below.* You will complete (C) in the next question.      <?php      require_once ""model/common.php"";   $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting   if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>         (A)  _______    (B)  _______ ",FALSE,1,Answer for blank # 2,count($petsitter_array) > 0,0.25,0.75,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,17,WR,,"[Part A] Continuing with the previous question:  ----------------------------Complete (C) in  view_all.php indicated below.     <?php      require_once ""model/common.php"";  $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting  if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>        (C) ",FALSE,1,"echo ""<ol>""; foreach($petsitter_array as $petsitter_object) {     $fullname = $petsiter_obj->getFullname();     $hourlyRate = $petsitter_obj->getHourlyRate();     $petType = $petsitter_obj->getPetType();     $mobileNumber = $petsitter_obj->getMobileNumber();     echo ""<li>$fullname<br>"";     echo ""<ul>"";         echo ""<li>Hourly Rate: $hourlyRate (SGD)</li>"";         echo ""<li>Pet Type: $petType</li>"";         echo ""<li>Mobile Number: $mobileNumber</li>"";     echo ""</ul>"";     echo ""</li>""; } echo ""</ol>"";",,0,2.25,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 1,:maximumHourlyRate,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 2,$maximumHourlyRate,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 3,:petType,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 4,$petType,2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 5,$row['fullname'],2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 6,$row['hourlyRate'],2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 7,$row['petType'],2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 8,$row['mobileNumber'],2,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 1,isset,1.75,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 2,PetSitterDAO,1.75,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 3,count($petsitter_array) > 0,1.75,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 4,$petsitter->getFullname(),1.75,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 5,No pet sitters found,1.75,2,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 1,&&,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 2,PetSitterDAO,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 3,$petsitter->getFullname(),3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 4,$maximum_hourly_rate,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 5,updateHourlyRate,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 6,Unsuccessful,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 7,Successful,3,3,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,4,,,Summary:,,Section C [10 marks],,,,,,7,10
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,5,,,Optional Feedback Questions,,,,<p>The questions in this section are not counted in your grade. Answer them only if you have time after finishing the gradable questions.</p>,,,,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Less than an hour,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr to 1hr 15 minutes,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr 15 minutes to 1hr 30 minutes,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr 30 minutes to 1hr 45 minutes,Checked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Just managed to finish within 2 hours,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Could not complete it!,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,No comments,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Ridiculously easy,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Easy enough,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Just right,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,A bit hard,Checked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Impossibly hard,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,No comments,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,WAMP,Checked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,MAMP,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,Neither,UnChecked,0,0,,
,student.one.2023,STUDENT ONE,_,1,18/04/2024 13:00,18/04/2024 14:59,5,,,Summary:,,Optional Feedback Questions,,,,,,0,0
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,1,,,Multiple Choice Questions [20 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""is.html"">IS</a> <br> <a href=""../../index.html"">SMU</a>",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""../is.html"">IS</a> <br> <a href=""../../index.html"">SMU</a>",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""is.html"">IS</a> <br> <a href=""www.smu.edu.sg"">SMU</a>",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,"<a href=""../is.html"">IS</a> <br> <a href=""www.smu.edu.sg"">SMU</a>",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,1,MC,,The web root folder contains only the following sub folders and files:  smu/scis/index.html smu/scis/cs/cs.html smu/scis/is/is.html  You are editing the file cs.html. Which of the following code snippet will generate the following output?  Note :  IS will hyperlink to is.html and SMU will hyperlink to www.smu.edu.sg.,FALSE,1,None of the options ,Checked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,4,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,1,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,2,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,5,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,2,MC,,"Given the following code:      <?php          $str = ""12345678"";          // code to be inserted here ?>         How many code snippets will display 2468 when inserted at  // code to be inserted here?   foreach ($str as $s){     if ($s % 2 == 0){         echo ""$s"";      } }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 != 1){        echo ""$str[$i]"";      } }    for ($i=0; $i<strlen($str); $i++){    if ($str[$i] % 2 === false){       echo ""$str[$i]"";     }  }   for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == false){         echo ""$str[$i]"";     }  }    for ($i=0; $i<strlen($str); $i++){     if ($str[$i] % 2 == 0){         echo ""$str[$i]"";      }  }   ",FALSE,1,3,Checked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1 == $key2){             $result[$value1] = [$key1, $value2];         }     } } ",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1[0] == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  } ",Checked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($intake as $key1 => $value1){     foreach ($intake as $key2 => $value2){         if ($value1 == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  }  ",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($courses as $key1 => $value1){    foreach ($intake as $key2 => $value2){         if ($key1 == $key2){             $result[$value1[0]] = [$key1, $value2];         }     } } ",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,3,MC,,"Given that index.php contains the code below:   <?php      $courses = [ ""CS"" => [""Computer Science""],                   ""CL"" => [""Computing and Law""],                    ""IS"" => [""Information Systems""],                    ""SE"" => [""Software Engineering""]];     $intake = [ ""Computer Science"" => 150,                  ""Computing and Law"" => 50,                 ""Information Systems"" => 400,                   ""Software Engineering"" => 50];     $result = [];     // code to be inserted here          foreach ($result as $key => $value){        echo ""$key - $value[0], $value[1] <br>"";     } ?>   Which ONE of the code snippets when inserted at // code to be inserted here will display the following output in a web browser? Computer Science - CS, 150Computing and Law - CL, 50Information Systems - IS, 400Software Engineering - SE, 50 ",FALSE,1,"foreach ($intake as $key1 => $value1){     foreach ($courses as $key2 => $value2){         if ($value1[0] == $key2){             $result[$value1[0]] = [$key1, $value2];         }     }  } ",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Alan, James",Checked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Alan, Ben",UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Bob, James",UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,"Bob, Ben",UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,4,MC,,"Given form.php <?php      session_start();      $_SESSION[""user""] = ""Bob"";  ?>   <html>  <body>      <form action=""process.php"" method=""post"">          User <input type=""text"" name=""user"" value=""Alan"" >          <input type=""submit"" > 	     </form>  </body>   </html>   process.php <?php   	session_start(); 	$_SESSION[""user""] = $_POST[""user""];  	header(""Location: display.php?user=James&user[]=Ben"");  	exit;   ?>   display.php <?php         session_start();      echo $_SESSION['user'] . "", "" . $_GET['user'];  ?>  If the user accesses form.php through a web browser and clicks on the submit button, what will be the output displayed? ",FALSE,1,None of the above,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,628,Checked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,28,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,6284,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,284,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,5,MC,,"Given test.php <?php      $u = 1;     $x = [1, 2, 3];     $y = [6, 7, 8];      $z = $y;     $z[$u] = $x[$u];     $y[] = 4;     $x = $z;     $z[0] = 0;      foreach ($x as $i){         echo ""$i"";     }  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,178,UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 20 30,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,10 20 31,Checked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 21 30,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,26 20 31,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,6,MC,,"Given display.php <?php      $x = 10;     $y = 20;      function doA ($x, $y){        $x++;        $x = $x + $y;        return $x;     }      function doB ($x, $y){        global $x;        $y++;        $x = $y + 5;     }      $z = doA($x, $y);     doB($x, $y);      echo ""$x $y $z""; ?>   When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,31 21 31 ,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,1,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,5,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,4,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,3,Checked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,7,MC,,"Given the following form.html <html><body> <form action=""process.php"" method=""post"">    Name : <input type=""text"" name=""name"" /><br/><br/>        Choose your course :         <select name = ""course"">           <option value = ""cs"">Computer Science</option>           <option value = ""cl"">Computing and Law</option>           <option value = ""is"">Information System</option>           <option value = ""se"">Software Engineering</option>         </select>         <br/>         <input type=""submit"" name=""submit_btn"" value=""submit"" /> </form> </body></html>   process.php <?php      if ( /*CONDITION*/ ) {           echo ""true"";      } else {           echo ""false"";      }  ?>   The user accesses form.html through a web browser, without entering/changing any form value, and clicks on the submit button.    How many of the following code snippets can be used to replace /*CONDITION*/ in process.php such that the page will display ""true""?   !isset($_POST[""name""]) count($_POST[""course""]) > 0  isset($_POST[""course""])  empty($_POST[""name""])  isset($_POST[""submit""])  ",FALSE,1,2,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-e-j-,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-d-g-i-,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,None of the options,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-d-f-h-j- ,Checked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,8,MC,,"Given display.php <?php      function process($str) {          for ($i=0; $i<strlen($str)-1; $i++){             $i++;             $str = substr($str, $i);             echo $str[0] . ""-"";         }     }       $str = ""abcdefghij"";      process($str);  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,b-e-,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,2017,60",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,6020,17",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,6020,7",Checked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,2060,0",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,9,MC,,"Given Thing.php <?php      class Thing {         private $value1;          private $value2;            public function __construct($value1, $value2) {              $this->value1 = $value1;             $this->value2 = $value2;          }                   public function getValue1(){              return $this->value1;          }          public function getValue2(){              return $this->value2;          }                   public function compute($x, $y){              if (($x + $y) % 4 == ""0"") {                  return $x + 2;              } else if ($x > 10) {                     return $y - 3;                    } else {                  return intdiv($x, $y);              }          }                   public function generateThing(){              return new Thing($this->value2 * 3,                          $this->compute($this->value2, $this->value1));         }     }           $x = 10;      $y = 20;     $t1 = new Thing($x, $y);      $t2 = $t1->generateThing();      echo  $t1->getValue1() . "","" . $t2->getValue1() . ""<br>"";      echo  $t1->getValue2() . "","" . $t2->getValue2();  ?>  When the above PHP file is accessed in the web browser, what will be displayed?",FALSE,1,"10,720,60",UnChecked,2,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,An error will occur,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,An empty page will be shown,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will show David Lee,Checked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will be empty,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,10,MC,,"Given user.php <?php     $user = """";     if (isset($_GET[""user""])) {         $user = $_GET[""user""];     } ?> <html> <body>     <form action=""user.php"">         Name : <input type=""text"" name=""user"" value=<?php echo $user ?>>         <input type=""submit"">        </form> </body> </html>  When the page is loaded for the first time, it shows the following.  You typed David Lee into the textbox and pressed Submit.  What is the expected output?  ",FALSE,1,The textbox will show David,UnChecked,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,1,,,Summary:,,Multiple Choice Questions [20 marks],,,,,,10,20
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,2,,,Section A [10 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,11,WR,,"[Part A]  Use the following directory structure to answer the question. The folder is113 can be found under the web root folder.   is113      |-- q1          |-- cars.html          |-- display1.php         |-- display2.php   The web page car.html has a single select dropdown list and two independent checkboxes. The value “Audi” is selected by default.     Clicking on the “Display All” submit button will take the user to page display1.php, which will display the result. No hard coding is allowed.Complete the missing codes for car.html.  <!DOCTYPE html> <body>      <form action = ""(A)""  method = ""(B)"" >         <h3> Car Brands: </h3>                  <select name = 'car' size = ""(C)"" >             <option value=""Audi"" selected>Audi</option>             <option value=""BMW"">BMW</option>             <option value=""Chevrolet"">Chevrolet</option>             <option value=""Maserati"">Maserati</option>         </select>         <br><br>          <h3> Types of Services: </h3>         <input type=""checkbox"" name=""car_wash"" value=""yes"" > Car Wash         <input type=""checkbox"" name=""major_service"" value=""yes""> Major Service                <br><br>          <input type=""submit"" value= ""(D)"" >     </form>  </body> </html> ",FALSE,1,(A) display1.php (B) GET (C) 12 (D) Display All,,0,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,12,WR,,"[Part B]  Complete display1.php as per the scenarios below.     When the user chooses a car brand and specifies the desired services, the application will present the basic cost and the total hours needed for servicing the car. The total service hours required for the car can be computed by multiplying the multiplier with the hours allocated for each specific service. $charges is an associative array where the brand of the car serves as the key, and the corresponding value is an indexed array containing [<basic cost>, <multiplier for each service type hour>]. The variable $CAR_WASH_TIME represents the hours for a car wash. The variable $MAJOR_SERVICE_TIME represents the hours for a major service.        car.html   display1.php                                      When the user did not select any services, display1.php will display “Choose at least 1 service.”.        car.html   display1.php            ",FALSE,1,"<?php       $charges = [         ""Audi"" => [100, 3],         ""BMW"" => [250, 1.5],         ""Chevrolet"" => [300, 2],         ""Maserati"" => [350, 2.5]     ];       $CAR_WASH_TIME = 3;     $MAJOR_SERVICE_TIME = 5;          $car = $_POST[""car""];       // Write your code below     if(empty($_GET[""car_wash""]) && empty($_GET[""major_service""])){         echo ""Choose at least 1 service."";     }else{         #initialise time values         $hours = 0;         $wash = 0;         $service = 0;           #initialise cost/multiplier values from array         $costarray = $charges[$car];         $basiccost = $costarray[0];         $costmultiplier = $costarray[1];          #init. time values per service         if (isset($_GET[""car_wash""]){             $wash = $CAR_WASH_TIME * $costarray[1];         }         if(isset($_GET[""major_service""]){             $service = $MAJOR_SERVICE_TIME * $costarray[1];         }           #calc final time value         $hours = $wash + $service;           echo ""The basic cost is (\$): {$basiccost}<br>The total time required (hr): {$hours}""; ?>",,0,4,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,13,WR,,"[Part C]  Complete display2.php  as per the scenarios below.   Now, clicking the ‘Display All’ submit button in car.html will take the user to page display2.php. The rest of car.html remains unchanged.    The selected car brand will be presented in bold. The number of '*' characters displayed depends on whether the user has chosen a car wash or a major service, utilizing the values from $CAR_WASH_TIME or $MAJOR_SERVICE_TIME. In case the user hasn't specified the type of service, it will be represented as ""?"". The remaining boxes will be displayed with '-'."" No hardcoding is allowed.        car.html   display2.php                                             ",FALSE,1,"<?php     $charges = [         ""Audi"" => [100, 3],         ""BMW"" => [250, 1.5],         ""Chevrolet"" => [300, 2],         ""Maserati"" => [350, 2.5]     ];       $CAR_WASH_TIME = 3;     $MAJOR_SERVICE_TIME = 5;       $car = $_POST[""car""];       echo ""<table border=1>"";     echo ""<tr>             <th> Brand </th>             <th> Car Wash Time </th>             <th> Major Service </th>           </tr>"";       // Write your code below     foreach($charges as $key=>$value){         if($key = $car){             echo ""<tr><th>{$key}</th>"";             if(isset($_GET[""car_wash""]){                 echo ""<td>***</td>"";             }else{                 echo""<td>?</td>"";             if(isset($_GET[""major_service""]){                 echo ""<td>*****</td>"";             }else{                 echo""<td>?</td>"";             echo ""</tr>"";         }         else{             echo ""<tr><td>{$key}</td><td>-</td><td>-</td></tr>"";         }       echo ""</table>""; ?>",,3,4,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,2,,,Summary:,,Section A [10 marks],,,,,,3,10
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,3,,,Section B [10 marks],,,,"<p><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</p>",,,,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,14,WR,,"[Part A]  Use the following directory structure to answer the question. The folder is113 can be found under the web root folder.    is113      |-- q2          |-- Olympics.php          |-- display.php   Complete class Olympics such that it  Has three properties  private property $year private property $country private property $sports       Has a public constructor that  takes in three parameters:  $year is a string $country is a string $sports is an indexed array of strings   initializes properties $year, $country and $sports.       Has four public methods  getYear() is a getter method that returns the year. getCountry() is a getter method that returns the country. getSports() is a getter method that returns the sports checkSport($name_of_sport)  takes an input string $name_of_sport returns $year if the $name_of_sport matches an element in $sports array, else return boolean false.       ",FALSE,1,"<?php       class Olympics{           // Your code goes here         private $year;         private $country;         private $sports;           public function constructor($year, $country, $sports){             $this->year = $year;             $this->country = $country;             $this->sports = $sports;         }           public function getYear(){             return $this->year;         }           public function getCountry(){             return $this->country;         }           public function getSports(){             return $this->sports;         }           public function checkSport($name_of_sport){             if(in_array($name_of_sport, $this->sports)){                 return $this->year;             }else{                 return False;             }         }       }   ?>",,0,5,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,15,WR,,[Part B]  Complete display.php such that it displays the following without hardcoding.   Use the data from $olympics_List to display the sport and the number of years the sport is featured as an event in the Olympics. The list of sports need not be sorted.,FALSE,1,"<?php       require_once ""Olympics.php"";          $olympics_List = [ new Olympics(""2016"", ""Rio"", [""Athletics"", ""Fencing"", ""Football""]),                                   new Olympics(""2020"", ""Tokyo"", [""Archery"", ""Rowing""]),                                   new Olympics(""2024"", ""Paris"", [""Archery"", ""Fencing""])];       echo ""<h3> List of Sports </h3>"";          // Your code goes here     foreach($olympics_List as      #foreach olympics list as object          echo ""<ul>"";          #foreach object[2] as sport               #if (!isset(sport))                   #echo <li>sport - count(sport)</li>;               #elseif (isset(sport)), count(sport)++;          echo ""</ul>"";   ?>",,0,5,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,3,,,Summary:,,Section B [10 marks],,,,,,0,10
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,4,,,Section C [10 marks],,,,"<p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 19px;""><span style=""background-color: yellow;"">Note:</span>&#160;Click on the &quot;Quiz Information&quot; link on the left to view the appendices.</span></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><br/><br/></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""></p> <p style=""text-align: justify;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Refer to the following directory structure to answer the question. The folder is113exam can be found under webroot.</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">is113exam –</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">&#160;&#160;&#160;&#160; |-- q3</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- model</span></p> <p style=""margin: 0cm 0cm 0cm 108pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- common.php</span></p> <p style=""margin: 0cm 0cm 0cm 108pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- ConnectionManager.php<br/>|-- PetSitter.php<br/>|-- PetSitterDAO.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- process_search.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- process_update.php</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- search.html</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- update.html</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;text-indent: 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;font-size: 17px;"">|-- view_all.php</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">You are part of a team that creates a web application that allows the user to view pet sitters. Your teammates have already completed the following, which you will be able to reuse:</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;<br/><br/></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>PetSitter<br/><br/></b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Private Properties</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">fullname</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Full name of a pet sitter</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">hourlyRate</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Hourly rate (SGD) charged by a pet sitter</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">petType</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Pet type that a pet sitter is capable of handling</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">mobileNumber</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Singapore mobile number without +65 (e.g. 98751234)</span></li> </ul> </li> </ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;</span></p> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">__construct(<span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$fullname, $hourlyRate, $petType, $mobileNumber</span>)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Constructor that initializes a PetSitter object&#39;s properties.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getFullname()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property fullname</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getHourlyRate()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property hourlyRate</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getPetType()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property petType</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">getMobileNumber()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the value of property mobileNumber</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">setHourlyRate($hourlyRate)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Takes in an input parameter $hourlyRate</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Set the value of property hourlyRate to $hourlyRate</span></li> </ul> </li> </ul> <p style=""margin: 0cm 0cm 0cm 90pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;<br/><br/></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>PetSitterDAO<br/><br/></b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#160; &#160;Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">retrieveAll()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Retrieves all data from the database table petsitter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an Indexed Array of PetSitter objects.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an empty array if there are no pet sitters.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">retrieveByHourlyRatePetType($maximumHourlyRate, $petType)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an Indexed Array of PetSitter objects.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns the pet sitters whose:</span> <ul style=""list-style-type: square;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">hourlyRate is less than or equal to the specified input parameter <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$maximumHourlyRate</span> <b><i><u>and</u></i></b></span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">petType is equal to <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$petType</span></span> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Valid values for input parameter $petType:</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#39;Cat&#39;</b> for cats</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>&#39;Dog&#39;</b> for dogs</span></li> </ul> </li> </ul> </li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns an empty array if there are no matching pet sitters.</span></li> </ul> </li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;courier new&#39;, courier, sans-serif;font-size: 17px;"">updateHourlyRate($petSitterObject)</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Takes in a PetSitter object as an input parameter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Using the properties fullname and hourlyRate from <span style=""font-family: &#39;courier new&#39;, courier, sans-serif;"">$petSitterObject</span>, updates the corresponding record in the database table petsitter.</span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Returns:</span> <ul style=""list-style-type: square;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Boolean TRUE if the update is successful <i><u>or</u></i></span></li> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Boolean FALSE if the update is <u>not</u> successful.</span></li> </ul> </li> </ul> </li> </ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""></ul> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">The &quot;q3&quot; database has a table called <b>petsitter</b>. The table definition and sample data are shown below:<br/><br/></span></li> </ul> <table cellpadding=""0"" cellspacing=""0"" border=""1"" class=""MsoTableGrid"" style=""margin-left: 8.75pt;border-collapse: collapse;border: none;""> <tbody> <tr> <td valign=""top"" style=""width: 530.75pt;border: solid windowtext 1.0pt;padding: 0cm 5.4pt 0cm 5.4pt;""> <p style=""margin: 0cm;text-align: center;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;"">CREATE <b>petsitter </b>TABLE and Data Population script</span></p> </td> </tr> <tr> <td valign=""top"" style=""width: 530.75pt;border: solid windowtext 1.0pt;border-top: none;padding: 0cm 5.4pt 0cm 5.4pt;""> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">CREATE TABLE petsitter (</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; fullname&#160;&#160;&#160;&#160;&#160; VARCHAR(100) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; hourlyRate&#160;&#160;&#160; INT NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; petType&#160;&#160;&#160;&#160;&#160;&#160; VARCHAR(100) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; mobileNumber&#160; VARCHAR(8) NOT NULL,</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160; primary key (fullname)</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">&#160;</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Bustin Jieber&#39;, 25, &#39;Cat&#39;, &#39;82821111&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Gelena Somez&#39;, 30, &#39;Dog&#39;, &#39;93432222&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Wanye Kest&#39;, 40, &#39;Cat&#39;, &#39;98761234&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Saylor Twift&#39;, 50, &#39;Dog&#39;, &#39;81236789&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-size: 10.0pt;font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Griana Arande&#39;, 60, &#39;Cat&#39;, &#39;98981212&#39;);</span></p> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: &#39;Courier New&#39;;"">insert into petsitter values (&#39;Ciley Myrus&#39;, 35, &#39;Dog&#39;, &#39;89893434&#39;);</span></p> </td> </tr> </tbody> </table> <p style=""margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;""><b>&#160;</b></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Class <b>ConnectionManager</b></span></li> </ul> <p style=""margin: 0cm 0cm 0cm 36pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;""><b>Public Methods</b></span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">connect()</span> <ul style=""list-style-type: circle;margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 24px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">Connects to the database &quot;q3&quot;.</span></li> </ul> </li> </ul> <p style=""margin: 0cm 0cm 0cm 90pt;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">&#160;</span></p> <ul style=""margin-bottom: 0cm;margin-top: 0px;""> <li style=""margin: 0cm 0cm 0cm 0px;font-size: 11pt;font-family: Calibri, sans-serif;""><span style=""font-family: Lato, sans-serif;font-size: 17px;"">common.php – refer to the Appendix.</span></li> </ul> <p style=""padding: 0cm;border-top: none;border-right: none;border-left: none;border-image: initial;border-bottom: 1pt solid windowtext;margin: 0cm;font-size: 11pt;font-family: Calibri, sans-serif;"">&#160;</p>",,,,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,16,FIB,,"[Part A] Page view_all.php displays information of all pet sitters (as retrieved from the database table petsitter). Complete view_all.php such that the list of pet sitters is displayed as shown below: Given the initial content of the ""q3"" database (see the SQL script above), view_all.php will display the following:   If there are NO pet sitters to display, view_all.php must display the following:   ----------------------------Complete (A) and (B) in  view_all.php indicated below.* You will complete (C) in the next question.      <?php      require_once ""model/common.php"";   $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting   if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>         (A)  _______    (B)  _______ ",FALSE,1,Answer for blank # 1,PetSitterDAO,0.25,0.75,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,16,FIB,,"[Part A] Page view_all.php displays information of all pet sitters (as retrieved from the database table petsitter). Complete view_all.php such that the list of pet sitters is displayed as shown below: Given the initial content of the ""q3"" database (see the SQL script above), view_all.php will display the following:   If there are NO pet sitters to display, view_all.php must display the following:   ----------------------------Complete (A) and (B) in  view_all.php indicated below.* You will complete (C) in the next question.      <?php      require_once ""model/common.php"";   $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting   if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>         (A)  _______    (B)  _______ ",FALSE,1,Answer for blank # 2,!empty($petsitter_array),0.25,0.75,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,17,WR,,"[Part A] Continuing with the previous question:  ----------------------------Complete (C) in  view_all.php indicated below.     <?php      require_once ""model/common.php"";  $dao = new (A)________________();   $petsitter_array = $dao->retrieveAll();// retrieveAll() returns a sorted array, and// your code does NOT need to do any further sorting  if( (B)____________________________  ) {   // (C) WRITE YOUR CODE BELOW   } else {     echo ""<h1>No Pet Sitters Found</h1>""; } ?>        (C) ",FALSE,1,"echo ""<ol>"";       foreach($petsitter_array as $petsitter){         $name = $petsitter[0];         echo ""<li>{$name}</li>"";              echo ""<ul>"";         $hourly_rate= $petsitter[1];         echo ""<li>Hourly Rate: {$hourly_rate} (SGD)</li>"";           $pet_type = $petsitter[2];         echo ""<li>Pet Type: {$pet_type}</li>"";           $phone_num= $petsitter[3];         echo ""<li>Mobile Number: {$phone_num}</li>"";           echo ""</ul>"";     }   echo ""</ol>""; ",,0,2.25,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 1,:maximumHourlyRate,0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 2,maximumHourlyRate,0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 3,:petType,0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 4,petType,0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 5,$row[0],0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 6,$row[1],0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 7,$row[2],0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,18,FIB,,"[Part B] Complete retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO.       public function retrieveByHourlyRatePetType($maximumHourlyRate, $petType) {    $sql = ""SELECT * FROM petsitter          WHERE petType = :petType          AND hourlyRate <= :maximumHourlyRate"";    $connMgr = new ConnectionManager();  $conn = $connMgr->getConnection();                      $stmt = $conn->prepare( $sql );    $stmt->bindParam('(A)_____________', (B)____________, PDO::PARAM_INT);    $stmt->bindParam('(C)____________', (D)_____________, PDO::PARAM_STR);    $stmt->setFetchMode(PDO::FETCH_ASSOC);  $stmt->execute();  $result = [];  while( $row = $stmt->fetch() )  {                                   $result[] = new PetSitter( (E)________________________,                                   (F)________________________,                                   (G)________________________,                                    (H)________________________ );    }           $stmt = null;  $conn = null;    return $result; }       (A) _______  (B) _______  (C) _______  (D) _______  (E) _______  (F) _______  (G) _______  (H) _______ ",FALSE,1,Answer for blank # 8,$row[3],0.5,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 1,!empty,0.75,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 2,PetSitterDAO,0.75,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 3,isset($petsitter_array),0.75,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 4,$petsitter[0],0.75,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,19,FIB,,"[Part C] Page process_search.php  performs the following:    Retrieves pet type and maximum hourly rate from user's form submission.  If user did NOT select pet type or if maximum hourly rate input is empty, displays the following error message:You must specify both 1) Pet Type AND 2) Maximum Hourly Rate  Calls the method retrieveByHourlyRatePetType($maximumHourlyRate, $petType) in PetSitterDAO. If there are any matches, this method will return an Indexed Array of PetSitter objects.  Displays the returned pet sitters' fullnames as an un-ordered list:                   ------------- Complete process_search.php.   You can use retrieveByHourlyRatePetType($maximumHourlyRate, $petType) method in PetSitterDAO.  Please refer to the search.html HTML code below:      <html> <body>     <h2> Search for Pet Sitters</h2>     <form action=""process_search.php"" method=""GET"">         Pet Type: <br>         <input type='radio' name='pet_type' value=""cat""> Cat <br>         <input type='radio' name='pet_type' value=""dog""> Dog           <br><br>         Maximum Hourly Rate (SGD):         <input type=""text"" name=""maximum_hourly_rate"">           <br><br>         <input type='submit' value='Search'>     </form> </body> </html>        [Test Case 1] Given the following user input in (pet type is not selected, maximum hourly rate input is empty)      search.html    process_search.php                       [Test Case 2] Given the following user input in (pet type is not selected):      search.html    process_search.php                       [Test Case 3] Given the following user input in (maximum hourly rate input is empty):      search.html    process_search.php                      [Test Case 4] Given the following user input in search.html:      search.html    process_search.php                      [Test Case 5] Given the following user input in search.html:      search.html    process_search.php                      ---------------------- Complete process_search.php.      <?php      require_once ""model/common.php"";   echo ""<h3> Search Result </h3>"";   if( (A)________($_GET[""pet_type""]) && $_GET[""maximum_hourly_rate""] ) {     $pet_type = $_GET[""pet_type""];   $maximum_hourly_rate = $_GET[""maximum_hourly_rate""];     $dao = new (B)_________();   $petsitter_array = $dao->retrieveByHourlyRatePetType($maximum_hourly_rate, $pet_type);     if( (C)_____________ ) {         echo ""Pet Sitters: <br>"";       echo ""<ul>"";     foreach( $petsitter_array as $petsitter )     {       echo ""<li>"" . (D)____________ . ""</li>"";     }     echo ""</ul>"";   }    else {     echo ""(E)________________"";   } } else { echo ""You must specify both 1) Pet Type AND 2) Maximum Hourly Rate""; } ?>           (A) _______  (B) _______  (C) _______  (D) _______  (E) _______ ",FALSE,1,Answer for blank # 5,No pet sitters found,0.75,2,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 1,&&,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 2,PetSitterDAO,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 3,$petsitter[0],2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 4,$maximum_hourly_rate,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 5,updateHourlyRate,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 6,Unsuccessful,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,20,FIB,,"[Part D] process_update.php performs the following steps:   It retrieves fullname and new hourly rate from the user's form submission.   NOTE: You may assume that the user will always key an integer value in the New Hourly Rate input field.    If the user did NOT indicate either the fullname or the new hourly rate, it displays the following error message:You must specify both 1) Fullname AND 2) New Hourly Rate It calls the method retrieveAll() in PetSitterDAO. It determines if there is a matching fullname.   NOTE: fullname is case-sensitive (for example, user input ""bobby"" is not same as ""Bobby"" in the database).    If there is a matching fullname,   It updates the PetSitter object with the New Hourly Rate. It calls the method updateHourlyRate() in PetSitterDAO to update the corresponding pet sitter in the database table petsitter. It displays the status of the update. It can be either:   Update is Successful (when the database table is successfully updated) or Update is Unsuccessful (when the database table is not successfully updated)           process_update.php                      In case of successful update     If there is a no matching fullname, it displays status as ""Update is Unsuccessful.""            process_update.php                   Complete process_update.php. Assume that the user will always enter a numeric value in New Hourly Rate. Please refer to the update.html below:      <html><body>     <h3> Update Hourly Rate </h3>     <form action=""process_update.php"" method=""GET"">         Fullname:         <input type='text' name='fullname'>         <br>         and          <br>         (NEW) Hourly Rate in SGD:          <input type='text' name=""hourly_rate"">         <br><br>         <input type='submit' value='Update'>     </form> </body> </html>         [Test Case 1] Given the following user input Fullname = 'Bustin Jieber' and New Hourly Rate = 27      update.html    process_update.php                             [Test Case 2] Given the following user input Fullname = 'Bichael Molton' and New Hourly Rate = 80  (There is no pet sitter by this fullname in the database)      update.html    process_update.php                                          [Test Case 3] Given the following user input Fullname = """" (the field is left blank/empty) and New Hourly Rate = 20      update.html    process_update.php                      [Test Case 4] Given the following user input Fullname = 'Gelena Somez' and New Hourly Rate = """" (the field is left blank/empty)      update.html    process_update.php                        ---------------------- Complete process_update.php.      <?php require_once ""model/common.php"";   // Your code goes here if ( $_GET[""fullname""] != """" (A)_________ $_GET[""hourly_rate""] != """" ) {   $fullname = $_GET[""fullname""]; $maximum_hourly_rate = $_GET[""hourly_rate""];     $dao = new (B)_____________();     $petsitter_array = $dao->retrieveAll();     $found = false;   foreach( $petsitter_array as $petsitter ) {     if( (C)_______________ == $fullname ) {          $found = true;          $petsitter->setHourlyRate((D)_________________);          $status = $dao->(E)___________________($petsitter);     }   }   if( !$found || !$status ) {     echo ""Update is (F)__________________."";   } else {     echo ""Update is (G)___________________."";   } } else { echo ""You must specify both 1) Fullname AND 2) New Hourly Rate""; } ?>             (A) _______    (B) _______    (C) _______    (D) _______    (E) _______    (F) _______    (G) _______ ",FALSE,1,Answer for blank # 7,Successful,2.5,3,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,4,,,Summary:,,Section C [10 marks],,,,,,4,10
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,5,,,Optional Feedback Questions,,,,<p>The questions in this section are not counted in your grade. Answer them only if you have time after finishing the gradable questions.</p>,,,,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Less than an hour,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr to 1hr 15 minutes,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr 15 minutes to 1hr 30 minutes,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,1hr 30 minutes to 1hr 45 minutes,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Just managed to finish within 2 hours,Checked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,Could not complete it!,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,21,MC,,Time Pressure: How long did you take to complete this exam?,TRUE,1,No comments,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Ridiculously easy,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Easy enough,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Just right,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,A bit hard,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,Impossibly hard,Checked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,22,MC,,Level of Difficulty: How hard was this exam?,TRUE,1,No comments,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,WAMP,Checked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,MAMP,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,,23,MC,,Do you use WAMP or MAMP?,TRUE,1,Neither,UnChecked,0,0,,
,student.two.2023,STUDENT TWO,_,1,18/04/2024 13:00,18/04/2024 15:00,5,,,Summary:,,Optional Feedback Questions,,,,,,0,0