より具体的には、私は受け取っています:
*注意: C:\xampp\htdocs\Project1_Tables\index.php の 38 行目の配列から文字列への変換 注意: 39 行目の C:\xampp\htdocs\Project1_Tables\index.php の配列から文字列への変換*
これがコードです
<?php
//SETUP FOR CONNECTION
$host = "localhost";
$user = "root";
$password = "password";
$database = "test";
$con = mysqli_connect($host, $user, $password, $database);
$tableName = "funding";
$sql = "";
//QUERIES NEEDED TO GATHER DATA FOR DROP-DOWN MENU'S (Research Theme and Institution)
$column = "research_theme";
$query = sprintf("SELECT DISTINCT %s FROM ", $column);
$sql = $query.$tableName;
$ddThemeList = mysqli_query($con, $sql);
$column = "institution";
$query = sprintf("SELECT DISTINCT %s FROM ", $column);
$sql = $query.$tableName;
$ddInstitutionList = mysqli_query($con, $sql);
$list1 = mysqli_fetch_array($ddThemeList, MYSQLI_NUM);
$list2 = mysqli_fetch_array($ddInstitutionList, MYSQLI_NUM);
require_once("support.php");
$body="";
$scriptName = $_SERVER["PHP_SELF"];
$topPart = <<<EOBODY
<form action="$scriptName" method="post">
<p>
Theme
<select name="theme">
<?php if(mysqli_num_rows($list1) != 0) { ?>
<?php while ($list1) { ?>
<option value="<?php echo $list1[0]; ?>">
<?php echo $list1[0]; ?>
</option>
<?php } ?>
<?php } ?>
</select>
</p>
</form>
EOBODY;
$body = $topPart.$body;
$page = generatePage($body);
echo $page;
?>