
This is home $mypage 안뜹니다
from flask import Flask
app = Flask(__name__)
@app.route('/')
def home():
return 'This is Home!'
@app.route('/mypage')
def mypage():
return 'This is mypage!!!'
if __name__ == '__main__':
app.run('0.0.0.0',port=5000,debug=True)
작성한 코드 및 에러 메세지
오류 발생 시, 작성한 코드 전체와 에러 메시지를 첨부해 주세요.
Tip 1C:\Users\SAMSUNG\Desktop\스파르\projects\prac\venv\Scripts\python.exe C:\Users\SAMSUNG\Desktop\스파르\projects\prac\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://172.30.1.39:5000
Press CTRL+C to quit
* Restarting with stat
* Debugger is active!
* Debugger PIN: 128-229-925
127.0.0.1 - - [07/Oct/2022 15:42:00] "GET / HTTP/1.1" 200 -
127.0.0.1 - - [07/Oct/2022 15:42:00] "GET /favicon.ico HTTP/1.1" 404 -
* Detected change in 'C:\\Users\\SAMSUNG\\Desktop\\스파르\\projects\\prac\\app.py', reloading
* Restarting with stat
* Debugger is active!
* Debugger PIN: 128-229-925
) </> 아이콘을 눌러 코드박스를 만들어 보세요.
Tip 2) Ctrl+A(맥의 경우 Command+A) 단축키로 코드를 한 번에 선택할 수 있어요!
