게시판 리스트 질문
본문
<?php
session_start();
?>
<!DOCTYPE HTML>
<html>
<head>
<link href="https://fonts.googleapis.com/css?family=Raleway" rel="stylesheet">
<meta charset="utf-8">
<link rel="stylesheet" href="style.css">
<link href="https://fonts.googleapis.com/css?family=Yanone+Kaffeesatz" rel="stylesheet">
</head>
<body>
<form method="POST" action="board_process.php?mode=insert">
<div class="board_insert">
<h3>글쓰기</h3>
<span>제목</span><p><input type="text" name="board_title" class="board_title" ></p>
<span>닉네임</span><p><?php echo $_SESSION['usernickname'];?></p>
<span>본문</span><p><textarea rows="20" cols="110" name="board_body" id="" class="board_body" placeholder="글의 본문을 입력해주세요"></textarea></p>
<span>비밀번호</span><p><input tpye="password" name="board_pwd" class="board_pwd"</p>
<input type="submit" value="글쓰기">
<input type="submit" value="취소" onclick=>
</div>
</form>
</body>
</html>
<?php
session_start();
ini_set('display_errors', 1); #에러를 출력
$conn = mysqli_connect("localhost", "root", "root","DORAHEE");
$board_title=$_POST['board_title'];
$board_body=$_POST['board_body'];
$board_pwd=$_POST['board_pwd'];
$usercheck = "SELECT * FROM member WHERE userid ='".$userid."' and userpassword='".$userpassword."'";
if($_GET['mode']==='insert')
{
$board_insert="INSERT INTO topic (board_title,board_body,board_pwd) VALUES('$board_title','$board_body','$board_pwd')";
mysqli_query($conn,$board_insert);
header("Location: board_list.php");
}
[/code]
<?php
ini_set('display_errors', 1); #에러를 출력
$conn = mysqli_connect("localhost", "root", "root","DORAHEE");
$resultquery = "SELECT * FROM topic";
$list_result = mysqli_query($conn, $resultquery);
print_r($row);
?>
<html>
<head>
</head>
<body>
<ol>
<?php
while($row = mysqli_fetch_array($list_result)) {
echo "<li><a href=\"?id={$row['id']}\">".htmlspecialchars($row['title'])."</a></li>";}
?>
</ol>
</body>
</html>
이런식으로 게시판 리스트를 구현했는대 정작 게시판 내용은 안나오고 id값만 나오네요 어떻게 수정해야하나요?
!-->!-->!-->
답변을 작성하시기 전에 로그인 해주세요.