Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
data-networks-web
lab-exercises
Commits
243c1a6f
Commit
243c1a6f
authored
Nov 29, 2017
by
Sorrel Harriet
Browse files
updating lab 7 readme
parent
4f9811d9
Changes
2
Hide whitespace changes
Inline
Side-by-side
lab-7/README.md
0 → 100644
View file @
243c1a6f
# Catflucks Application
Here is a new improved version of catflucks.
It has the same functionality as the Lab 6 version, but more effort has
been made to separate concerns (i.e. to separate database interaction, logic and presentation).
**Noteworthy differences:**
+
The app configurables (i.e. installation specific variables) are now defined in config.py.
+
splash.py provides the main entry point to the app
+
A new template rendering function has been added to utils.py
+
The HTML is confined to .html files in the templates folder
*It is still not perfect!*
There is much more we could do to improve portability/reusability...
Perhaps you can introduce further improvements to the
**application design**
in your own implementation?
lab-7/cgi-bin/splash.py
View file @
243c1a6f
#!/usr/bin/env python3
"""
This script is the main entry point to
the catflucks application.
"""
# import modules from Python standard library
from
bson.objectid
import
ObjectId
import
cgi
import
cgitb
cgitb
.
enable
()
# import custom modules
from
config
import
config
import
utils
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment