커뮤니티
포인트
쿠폰
내 강의실
국비 신청 내역
증명서
계정
로그아웃
학습 질문
개발 일지
나의 활동
답변 완료
localhost:5000 오류 발생합니다.
undefined주차
북마크
박*연
댓글
3
추천
0
조회수
7
조회수
7
답변 완료


5-4강 진행중에 localhost:5000 확인하려고 하면 계속 오류가 발생합니다.

혹시나 해서 싹다 지우다 코드시니펫 다시 깔고 처음부터 시작해 봐도 똑같은 오류가 계속됩니다.

뭐가 문제인지 제가 확인이 안되서요.

지우고 다시하고 지우고 다시하고... 몇 번째인지 기억도 안납니다. ㅠㅠ



스파르타 즉문즉답

여기 까지는 됩니다.


스파르타 즉문즉답

여기에서 오류가 계속 생깁니다.


<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet"
        integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js"
        integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM"
        crossorigin="anonymous"></script>

    <link href="https://fonts.googleapis.com/css2?family=Gowun+Dodum&display=swap" rel="stylesheet">

    <title>인생 버킷리스트</title>

    <style>
        * {
            font-family: 'Gowun Dodum', sans-serif;
        }
        .mypic {
            width: 100%;
            height: 200px;

            background-image: linear-gradient(0deg, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), url('https://images.unsplash.com/photo-1601024445121-e5b82f020549?ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&ixlib=rb-1.2.1&auto=format&fit=crop&w=1189&q=80');
            background-position: center;
            background-size: cover;

            color: white;

            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
        }
        .mypic > h1 {
            font-size: 30px;
        }
        .mybox {
            width: 95%;
            max-width: 700px;
            padding: 20px;
            box-shadow: 0px 0px 10px 0px lightblue;
            margin: 20px auto;
        }
        .mybucket {
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: space-between;
        }

        .mybucket > input {
            width: 70%;
        }
        .mybox > li {
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: center;

            margin-bottom: 10px;
            min-height: 48px;
        }
        .mybox > li > h2 {
            max-width: 75%;
            font-size: 20px;
            font-weight: 500;
            margin-right: auto;
            margin-bottom: 0px;
        }
        .mybox > li > h2.done {
            text-decoration:line-through
        }
    </style>
    <script>
        $(document).ready(function () {
            show_bucket();
        });
        function show_bucket(){
            $.ajax({
                type: "GET",
                url: "/bucket",
                data: {},
                success: function (response) {
                    alert(response["msg"])
                }
            });
        }
        function save_bucket(){
            let bucket = $('#bucket').vel()

            $.ajax({
                type: "POST",
                url: "/bucket",
                data: {bucket_give:bucket},
                success: function (response) {
                    alert(response["msg"])
                    window.location.reload()
                }
            });
        }
        function done_bucket(num){
            $.ajax({
                type: "POST",
                url: "/bucket/done",
                data: {sameple_give:'데이터전송'},
                success: function (response) {
                    alert(response["msg"])
                }
            });
        }
    </script>
</head>
<body>
    <div class="mypic">
        <h1>나의 버킷리스트</h1>
    </div>
    <div class="mybox">
        <div class="mybucket">
            <input id="bucket" class="form-control" type="text" placeholder="이루고 싶은 것을 입력하세요">
            <button onclick="save_bucket()" type="button" class="btn btn-outline-primary">기록하기</button>
        </div>
    </div>
    <div class="mybox" id="bucket-list">
        <li>
            <h2>✅ 호주에서 스카이다이빙 하기</h2>
            <button onclick="done_bucket(5)" type="button" class="btn btn-outline-primary">완료!</button>
        </li>
        <li>
            <h2 class="done">✅ 호주에서 스카이다이빙 하기</h2>
        </li>
        <li>
            <h2>✅ 호주에서 스카이다이빙 하기</h2>
            <button type="button" class="btn btn-outline-primary">완료!</button>
        </li>
    </div>
</body>
</html>


C:\Users\user\Desktop\sparta\projects\buket\venv\Scripts\python.exe C:\Users\user\Desktop\sparta\projects\buket\app.py 

 * Serving Flask app 'app'

 * Debug mode: on

WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.

 * Running on all addresses (0.0.0.0)

 * Running on http://127.0.0.1:5000

 * Running on http://192.168.219.103:5000

Press CTRL+C to quit

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

127.0.0.1 - - [28/Sep/2022 18:21:10] "GET / HTTP/1.1" 200 -

127.0.0.1 - - [28/Sep/2022 18:21:10] "GET /bucket HTTP/1.1" 200 -

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

 * Detected change in 'C:\\Users\\user\\Desktop\\sparta\\projects\\buket\\app.py', reloading

 * Restarting with stat

 * Debugger is active!

 * Debugger PIN: 275-079-385

127.0.0.1 - - [28/Sep/2022 18:33:09] "GET / HTTP/1.1" 200 -

127.0.0.1 - - [28/Sep/2022 18:33:09] "GET /bucket HTTP/1.1" 200 -

127.0.0.1 - - [28/Sep/2022 19:29:49] "GET / HTTP/1.1" 200 -



취소
 공유
취소
댓글 0
댓글 알림
나의얼굴