-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 20af6df
Showing
3,216 changed files
with
487,358 additions
and
0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
基于Python的Flask框架的在线电影网站系统  | ||
=========================== | ||
        | ||
### 网站展示 - http://henryhao.cn/ | ||
|Author|:sunglasses:Henryhaohao:sunglasses:| | ||
|---|--- | ||
|Email|:hearts:[email protected]:hearts: | ||
|
||
|
||
**** | ||
## :dolphin:声明 | ||
### 软件均仅用于学习交流,请勿用于任何商业用途!感谢大家! | ||
## :dolphin:介绍 | ||
### 该项目为基于Python的Flask框架搭建的[在线电影网站](http://henryhao.cn/) | ||
- **项目介绍**:网站前端采用HTML5编写,使用Bootstrap前端开发框架,后端使用Python3语言编写,以及Flask的Web框架,将MySQL作为数据库,开发工具使用PyCharm | ||
- **网站功能**:网站前台模块具有浏览视频、搜索视频、筛选视频、登录注册、收藏评论等功能。后台模块具有对视频、用户、管理员等各类管理功能 | ||
- **项目文件**:整个movie_project目录 | ||
- **运行方法**:运行movie_project目录下的manage.py | ||
- **nginx配置文件**:位于movie_project目录下的nginx.conf,用于部署到服务器进行反向代理的相关配置 | ||
## :dolphin:运行环境 | ||
Version: Python3 | ||
## :dolphin:安装依赖库 | ||
``` | ||
pip3 install -r requirements.txt | ||
``` | ||
## :dolphin:项目截图 | ||
> - **首页展示图**<br><br> | ||
 | ||
> - **视频展示页**<br><br> | ||
 | ||
> - **视频播放页**<br><br> | ||
 | ||
> - **后台管理页**<br><br> | ||
 | ||
> - **整体架构设计图**<br><br> | ||
 | ||
> - **项目目录结构图**<br><br> | ||
 | ||
> - **前台功能模块图**<br><br> | ||
 | ||
> - **后台功能模块图**<br><br> | ||
 | ||
> - **本地运行图**<br><br> | ||
 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# !/user/bin/env python | ||
# -*- coding:utf-8 -*- | ||
# time: 2018/3/7--19:49 | ||
from flask import Flask | ||
|
||
app = Flask(__name__) | ||
|
||
|
||
@app.route('/') | ||
def hello_world(): | ||
return 'Hello World!' | ||
|
||
|
||
if __name__ == '__main__': | ||
app.run() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# !/user/bin/env python | ||
# -*- coding:utf-8 -*- | ||
# time: 2018/3/7--19:50 | ||
__author__ = 'Henry' | ||
|
||
from flask import Flask, render_template | ||
from flask_sqlalchemy import SQLAlchemy | ||
import os | ||
|
||
app = Flask(__name__) | ||
# app.config['SQLALCHEMY_DATABASE_URI'] = 'mysql://root:[email protected]:3306/movie' | ||
app.config['SQLALCHEMY_DATABASE_URI'] = 'mysql://[email protected]:3306/movie' | ||
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = True | ||
app.config['UP_DIR'] = os.path.join(os.path.abspath(os.path.dirname(__file__)),'static/uploads/') #定义后台上传的文件的保存路径 | ||
app.config['FC_DIR'] = os.path.join(os.path.abspath(os.path.dirname(__file__)),'static/uploads/users/') #定义前台上传的用户头像文件的保存路径 | ||
|
||
app.debug = False #开发调试模式 | ||
|
||
# app.config['SECRET_KEY'] = 'Henry' | ||
app.secret_key = 'Henry' #密钥:用于csrf加密 | ||
|
||
db = SQLAlchemy(app) | ||
|
||
from app.home import home as home_blueprint | ||
from app.admin import admin as admin_blueprint | ||
|
||
app.register_blueprint(home_blueprint) | ||
app.register_blueprint(admin_blueprint, url_prefix='/admin') | ||
|
||
|
||
# 404页面 | ||
@app.errorhandler(404) | ||
def page_not_found(error): | ||
return render_template('home/404.html'), 404 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# !/user/bin/env python | ||
# -*- coding:utf-8 -*- | ||
# time: 2018/3/7--19:51 | ||
__author__ = 'Henry' | ||
|
||
from flask import Blueprint | ||
|
||
admin = Blueprint('admin',__name__) | ||
|
||
import app.admin.views | ||
|
Oops, something went wrong.