diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/__init__.py b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/admin.py b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/admin.py new file mode 100644 index 00000000..4217b9fd --- /dev/null +++ b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/admin.py @@ -0,0 +1,6 @@ +from django.contrib import admin +from .models import Cheep + +# Register your models here. + +admin.site.register(Cheep) \ No newline at end of file diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/apps.py b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/apps.py new file mode 100644 index 00000000..b0149d00 --- /dev/null +++ b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/apps.py @@ -0,0 +1,6 @@ +from django.apps import AppConfig + + +class ChirpyAppConfig(AppConfig): + default_auto_field = 'django.db.models.BigAutoField' + name = 'chirpy_app' diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/migrations/__init__.py b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/migrations/__init__.py new file mode 100644 index 00000000..e69de29b diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/models.py b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/models.py new file mode 100644 index 00000000..8525702c --- /dev/null +++ b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/models.py @@ -0,0 +1,14 @@ +from tkinter import CASCADE +from django.db import models +from django.contrib.auth.models import User +# Create your models here. + +class Cheep(models.Model): + chirp = models.CharField(max_length=120) + date_published = models.DateTimeField(auto_now=True) + user =models.ForeignKey(User, on_delete=models.CASCADE) + deleted = models.BooleanField(default=False) + + def __str__(self): + return f'{self.user}: {self.date_published} -- {self.chirp}' + \ No newline at end of file diff --git a/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/templates/chirpy_app/index.html b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/templates/chirpy_app/index.html new file mode 100644 index 00000000..4874168b --- /dev/null +++ b/Code/johnathan/Django_Chirp_Proj/Chirp/chirpy_app/templates/chirpy_app/index.html @@ -0,0 +1,18 @@ + + +
+ + + +Hello {{name}}
+ About + Contact + + + + \ No newline at end of file diff --git a/Code/johnathan/HTML/Flask/app.py b/Code/johnathan/HTML/Flask/app.py new file mode 100644 index 00000000..2b247eb4 --- /dev/null +++ b/Code/johnathan/HTML/Flask/app.py @@ -0,0 +1,32 @@ +from flask import Flask, render_template + +app = Flask(__name__) + + + +#localhost:5000/ +@app.route('/') +def index (): + name="Bill" + return render_template('index.html', name=name,) + +@app.route('/about') +def about(): + return render_template('about.html') + +@app.route("/contact") +def contact(): + return render_template('contact.html') + +@app.route('/check-grade/Lord Tyrion Lannister, also known by the nicknames the Halfman or the Imp and + the alias Hugor Hill, is a fictional character in the A Song of Ice and Fire series + of epic fantasy novels by American author George R. R. Martin, and its television + adaptation Game of Thrones, where he is portrayed by American actor Peter Dinklage. + Introduced in A Game of Thrones (1996), Tyrion is a prominent point of view character + in the series, having the most viewpoint chapters in the first five published novels. + He is one of a few prominent characters not included in A Feast for Crows (2005) but + returned in A Dance with Dragons (2011), and is confirmed to appear in the forthcoming + sixth novel The Winds of Winter. Tyrion developed from a character concept Martin + had while writing the 1981 novel Windhaven. He is Martin's favorite character in the + series. + + Checkout the Tyrion_Bio for more info. +
+ + + +" That’s what I do. I drink, and I know things. "+ + +