내 웹 사이트 용 PHP 갤러리를 만들고 있습니다. 일반 HTML 페이지 내부에 iFrame에 표시됩니다.PHP 갤러리가 작동하지 않습니다.
<html>
<head><title></title></head>
<body>
<table><tr>
<?php
define('Photo_dir','img');
define('Columns',2);
$x=0;
$y=0;
$results = scandir(Photo_dir);
foreach ($results as $result)
{
if ($result === '.' or $result === '..') continue;
if (is_dir(Photo_dir.'/'.$result))
{
if($y > 2)
{
echo "</tr><tr>";
$y=0;
$x=&x+1;
}
echo "<td><img src='image.php?photo=".Photo_dir."/".$result."/1.jpg'/></td>";
echo "kod w html";
}
}
?>
</tr>
</table>
</body>
</html>
어떤 이유로 작동하지 않습니다. 브라우저가 보이지 않는 경우 <table>
미리 감사드립니다.
문제를 설명하기위한 예제가 있습니까? 타당성 확인을 위해 본문을 열기 전에 '
@PhilipWhitehouse는 '