리펙토링 #6 참고

This commit is contained in:
Lectom C Han
2026-02-05 12:38:34 +09:00
parent 46b30af839
commit 7034a3643a
17 changed files with 76 additions and 369 deletions

View File

@@ -17,7 +17,7 @@ if (session_status() === PHP_SESSION_NONE) {
if (empty($_SESSION['login'])) {
echo "<script>
alert('로그인이 필요합니다.');
location.href = '/qa_list.skin';
location.href = '/qa_list';
</script>";
exit;
}
@@ -216,7 +216,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
handle_file_uploads($pdo, $postId);
}
header("Location: /kngil/bbs/qa_detail.php?id={$postId}");
header("Location: /qa_detail?id={$postId}");
exit;
} catch (Exception $e) {
@@ -228,4 +228,4 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
/* ===============================
7. 화면 출력
=============================== */
include $_SERVER['DOCUMENT_ROOT'].'/kngil/skin/qa_write.skin.php';
include $_SERVER['DOCUMENT_ROOT'].'/kngil/skin/qa_write.php';