Giter Club home page Giter Club logo

warcraft-mogs's Introduction

WARCRAFT MOGS

Welcome to Warcraft Mogs README.

I am a huge fan of the online MMORPG World of Warcraft and have been a loyal player since the early beginnings in 2005. World of Warcraft is not only a game to me, but also a means to express my creativity, by creating cool armour sets - also known as transmogs (mog for short). Transmog is one of my favourite aspects of the game, and I can spend many, many hours just picking out the right shade on a pair of boots. There is a lot of time needed to put in to make these transmogs, as you need to collect all pieces you want to complete your wardrobe. I know there are a lot of like-minded people who enjoy the collecting and creativity that comes with it, as well as wanting to share their creations with other people.

While deciding what I wanted to do with my fourth project with Code Institute, my boyfriend Dan suggested I do a blog to showcase my own transmogs. I instantly fell in love with the idea and was really excited to begin with this project.

I hope you enjoy the website as much as enjoyed making it! It's been a roller coaster of emotions, but in the end, I made it through!

amiresponsive

View live site: Warcraft Mogs


CONTENTS


User Experience (UX)

Initial Discussion

Warcraft Mogs is a website developed for transmog enthusiasts in the game World of Warcraft. On this website, users can share their creations and get inspiration from others' work too.

Key information for the site

  • A place to showcase creativity
  • Browse blog posts containing different armour sets
  • Give feedback and participate in the comment section
  • Like posts

User Stories

Client Goals

  • To be able to view the site on a range of device sizes.
  • To inspire creativity
  • To share creations
  • To give feedback

First-Time Visitor Goals

  • I want to see other people's creations
  • I want to share my own creations
  • I want to express my appreciation

Returning Visitor Goals

  • I want to see what other people think of my creations
  • I want to stay up to date with new posts
  • I want to be active on the blog

Frequent Visitor Goals

  • I want to give feedback and discuss ideas with other users
  • I want to build up my portfolio of my own creations

Agile Methodology

The Agile Methodology was used to develop this website. It was implemented through GitHub and the Project/Kanban Board: Warcraft Mogs.

Kanban Board:

With the Kanban board, the project was split into four sections;

  • Todo
  • In Progress
  • Done
  • Backlog (future additions)
Kanban board design:
(Changed colour from Green to Purple on Done, and from Purple to Green for Backlog)

Kanban

User Stories

Iteration 1

  • As a Site Admin, I can create draft posts so that I can finish writing the content at a later time.
  • As a Site Admin, I can approve or disapprove comments so that I can filter out objectionable comments.
  • As a Site Admin, I can create, read, update and delete posts so that I can manage my blog content.
  • As a Site User, I can view a paginated list of posts so that I can select which post I want to view.
  • As a user, I can view all posts in a list so that I can easily find a post to view.

Iteration 2

  • As a Site User, I can click on a post so that I can read the full text.
  • As a Site User, I can like or unlike a post so that I can interact with the content.
  • As a Site User, / Admin I can view the number of likes on each post so that I can see which post is the most popular.
  • As a Site User, and/or Admin I can view comments on an individual post so that I can read the conversation.
  • As a Site User, I can leave comments on a post so that I can be involved in the conversation.

Iteration 3

  • As a site user or admin, I can edit/update my blog post so that I can make a change in the already submitted post.
  • As a site user, I can delete a blog post so that the post is removed from the blog.
  • As a Site User, I can register an account so that I can comment and like.
  • As a site user, I can upload my own post so that I can share my creation.

Design

Colour Scheme

The purple colours and aesthetic has been generated from the header image.

Purple

The purple colours and aesthetic has been generated from the background image.

Green

Typography

All fonts used were already pre-installed with the Bootstrap theme I have chosen for this project;

Imagery

All images are screenshots taken from World of Warcraft content: Copyright ©2004 Blizzard Entertainment, Inc. All rights reserved. World of Warcraft, Warcraft and Blizzard Entertainment are trademarks or registered trademarks of Blizzard Entertainment, Inc. in the U.S. and/or other countries.

The header and background image are screenshots taken from in-game World of Warcraft. It is consistent throughout all pages.

Header

Header

Background

Header

Wireframes

The wireframe below is the general idea and vision I had for the website. It follows a basic structure that is the same throughout all pages of the website, with small modifications.

Wireframes

Features

Home Page

  • The homepage serves as the landing page.
  • Accessed from the navbar and Home button.
  • Designed to give the user a good understanding of the purpose of this website and catch attention.
  • Displays Post entries and relevant information about them, such as:
    • title
    • description
    • author
    • date and time of posting
    • number of likes
    • number of comments
    • armor type (category)

Home

Detail Page

  • Clicking the image of a post in the Home Page will take the user to the Post Detail Page.
  • Clicking the Description of a post in the Home Page will take the user to the Post Detail Page.
  • Display the Content text that was provided with the uploaded post.
  • Displays amount of comments and likes.
  • Displays all comments on that post.
  • Displays a textarea field for signed in users to comment.
  • Comment pagination buttons if there are more than 4 comments.
  • Ability to Like/Unlike a post.

Detail

Edit Page

  • Edit button in the Detail Page redirects to the edit page.
  • Button and Delete Page is only visible to the user that created the post.
  • Any changes made in this page will be reflected in the Post Detail page when the changes are saved.

Edit

Delete Page

  • Delete button in the Detail Page redirects to the delete page.
  • Button and Edit Page is only visible to the user that created the post.
  • Deleting a post will remove it from the database and redirect the user to the Home page.

Delete

Upload Page

  • Can only be accessed from the navbar when logged in.
  • Submit button submits the post and redirects the user to the uploaded post detail page
  • Displays 5 fields:
  • title
  • description (displayed on the home page)
  • armor (category)
  • content (displayed in the post detail page)
  • image upload

Upload

About Page

  • Can be accessed from the navbar to anyone.
  • Back button to take the user back to the Home Page

About

Contact Page

  • Can be accessed from the navbar to anyone.
  • Button submits the form and sends the user to the Contact Success Page.
  • Displays three required fields:
  • name
  • email
  • message

Contact

Contact Success Page

  • The Contact Success Page will be displayed to a user who has successfully filled in the form in the Contact Page.

Contact Success

Register Page

  • Can only be accessed from the navbar when a user is not signed in.
  • Does not appear if you are signed in.
  • If the user already has an account, there is a link provided to redirect the user to the Sign in page.
  • The Register page uses django-allauth to provide all the settings for user authentication.

Register

Sign in Page

  • Can only be accessed from the navbar when a user is not signed in.
  • Does not appear if you are signed in.
  • If the user haven't got an account, there is a link provided to redirect the user to the Register page.
  • The Sign in page uses django-allauth to provide all the settings for user authentication.

Sign in

Sign out Page

  • Can only be accessed from the navbar when logged in.
  • When the user clicks the Sign out button, they will be redirected to a site to verify if they want to log out.
  • The Sign Out page uses django-allauth to provide all the settings for user authentication.

Sign out

404 Page

  • The 404 Page will be displayed when a user tries to enter the url for edit/delete a post when they are not signed in.
  • The 404 Page will be displayed when a user tries to enter the url for edit/delete a post when the user is logged in as a user that is not the same author the post they are trying to edit/delete.

404

General features on each page

All pages feature a navigation bar with access to the following pages: Home, About, Contact, Register and Sign in. If you are already logged in, you can access the pages Upload Post and Sign Out. The footer is also present on all of the pages, with links to my social media accounts and GitHub. The navbar appears in white when you scroll up on the page. The website is responsive due to the bootstrap theme and styling that has been added.

  • The navbar as it appears on all pages when a user have not scrolled down on the page.

Nav

  • The white navbar appears when a user is scrolling up on a page

Nav Scroll

  • The Footer is displaying on all pages and clicking the social media buttons opens a new tab to my social media handles.

Footer

Future Implementations

To expand this website further, I would like to add these future implementations:

  • The ability to enlarge the images in the detailed view
  • Create a user page, and the ability to view other user pages
  • Search field
  • Create drafts
  • Sort and display blog posts by different categories such as newest, oldest, armor, popular (most liked)
  • Add more categories

More features and ideas may be added in the future.

Accessibility

I have tried my best to be mindful of accessibility, and the steps I've taken for this are the following:

  • Alt tags on the header and placement images
  • Aria labels to the social media links
  • Chose a good colour contrast throughout the website
  • Semantic HTML

Technologies Used

Languages Used

  • HTML5
  • CSS
  • Python
  • JavaScript

Frameworks, Libraries & Programs Used

Deployment & Local Development

Deployment

The site was deployed using Heroku, following the steps offered by Code Institute. You can find the instructions in a Google Docs here.

1. Creating the Django Project:

  • Install Django and gunicorn: pip3 install django gunicorn
  • Install supporting database libraries dj_database_url and psycopg2 library: pip install dj_database_url psycopg2
  • Install Cloudinary libraries to manage static files: pip install dj-3-cloudinary-storage
  • Create file for requirements: pip freeze --local > requirements.txt
  • Create project: django-admin startproject project_name
  • Create app: python manage.py startapp app_name
  • Add app to list of installed apps in settings.py file: 'app_name'
  • Migrate changes: python manage.py migrate
  • Test server works locally: python manage.py runserver

2. Create your Heroku App:

  • Navigate to the Heroku website
  • Create a Heroku account by entering your email address and a password (or log in if you have one already).
  • Activate the account through the authentication email sent to your email account
  • Click the new button on the top right corner of the screen and select Create a new app from the dropdown menu.
  • Enter a unique name for the application.
  • Select the appropriate region for the application.
  • Click Create app
  • In the Heroku dashboard click on the Resources tab
  • Scroll down to Add-Ons, search for and select 'Heroku Postgres'
  • In the Settings tab, scroll down to 'Reveal Config Vars' and copy the text in the box beside DATABASE_URL.

3. Set up Environment Variables:

  • In your IDE, create a new env.py file in the top-level directory
  • Add env.py to the .gitignore file
  • In env.py import the os library
  • In env.py add os.environ["DATABASE_URL"] = "Paste in the text link copied above from Heroku DATABASE_URL"
  • In env.py add os.environ["SECRET_KEY"] = "Make up your own random secret key"
  • In Heroku Settings tab Config Vars enter the same secret key created in env.py by entering 'SECRET_KEY' in the box for 'KEY' and your randomly created secret key in the 'value' box.

4. Setting up settings.py:

  • In your Django 'settings.py' file type:
from pathlib import Path
import os
import dj_database_url

if os.path.isfile("env.py"):
    import env
  • Remove the default insecure secret key in settings.py and replace with the link to the secret key variable in Heroku by typing: SECRET_KEY = os.environ.get(SECRET_KEY)
  • Comment out the DATABASES section in settings.py and replace it with:
DATABASES = {
  'default': 
  dj_database_url.parse(os.environ.get("DATABASE_URL"))
  }
  • Create a Cloudinary account and from the 'Dashboard' in Cloudinary copy your url into the env.py file by typing: os.environ["CLOUDINARY_URL"] = "cloudinary://<insert-your-url>"
  • In Heroku add cloudinary url to 'config vars'
  • In Heroku config vars add DISABLE_COLLECTSTATIC with value of '1' (note: this must be removed for final deployment)
  • Add Cloudinary libraries to the installed apps section of settings.py file:
'cloudinary_storage'
'django.contrib.staticfiles''
'cloudinary'
  • Connect Cloudinary to the Django app in settings.py:
STATIC_URL = '/static'
STATICFILES_STORAGE = 'cloudinary_storage.storage.StaticHashedCloudinaryStorage'
STATICFILES_DIRS = [os.path.join(BASE_DIR, 'STATIC')]
STATIC_ROOT = os.path.join(BASE_DIR, 'staticfiles')
MEDIA_URL = '/media/'
DEFAULT_FILE_STORAGE =
'cloudinary_storage.storage.MediaCloudinaryStorage'
* Link file to the templates directory in Heroku 
* Place under the BASE_DIR: TEMPLATES_DIR = os.path.join(BASE_DIR,
'templates')
  • Change the templates directory to TEMPLATES_DIR. Place within the TEMPLATES array: 'DIRS': [TEMPLATES_DIR]
  • Add Heroku Hostname to ALLOWED_HOSTS: ALLOWED_HOSTS = ['rhi-book-nook.herokuapp.com', 'localhost'] *Create Procfile at the top level of the file structure and insert the following: web: gunicorn PROJECT_NAME.wsgi
  • Make an initial commit and push the code to the GitHub Repository. git add . git commit -m "Initial deployment" git push

5. Heroku Deployment:

  • Click the Deploy tab in Heroku
  • In the 'Deployment method' section select 'Github' and click the 'Connect to GitHub' button to confirm.
  • In the 'search' box enter the Github repository name for the project
  • Click search and then click connect to link the Heroku app with the GitHub repository. The box will confirm that Heroku is connected to the repository.

6. Final Deployment:

In the IDE:

  • When development is complete change the debug setting to: DEBUG = False in settings.py
  • In Heroku settings config vars, change the DISABLE_COLLECTSTATIC value to 0
  • Because DEBUG must be switched to True for development and False for production it is recommended that only manual deployment is used in Heroku.
  • To manually deploy click the button 'Deploy Branch'. The default 'main' option in the dropdown menu should be selected in both cases. When the app is deployed a message 'Your app was successfully deployed' will be shown. Click 'view' to see the deployed app in the browser.

Local Development

How to Fork

  1. Login (or sign up) to GitHub.
  2. Go to the repository for this project here
  3. Click the Fork button in the top right corner.

How to Clone

If you wish to clone my project, please see the following steps below:

  • Navigate to GitHub: https://github.com/nicolemne/warcraft-mogs
  • Select the 'Clone' button
  • Copy the URL or download it as a ZIP file
  • Use git clone + the URL in your terminal, or unpack the ZIP containing the project

Testing

Please refer to the TESTING.md file for all testing performed.

Credits

UploadPost view:

I am grateful to my friend Joseph for offering valuable guidance and assistance in resolving issues with my Upload Blog Post feature. He shared many helpful pointers and provided me with relevant links that played a crucial role in finding a solution (the majority of which are listed below - I apologize if I have forgotten to include any links). I greatly appreciate his support and contribution to the success of my project.

I have been inspired by the valuable insights and contributions of my fellow Code Institute peer, Emelie Hansson. Through many talks, she provided useful tips, resources, and knowledge that have influenced my own work. I appreciate her willingness to share and collaborate, as it has been helping me enhancing my project.

Code Used

From the "I Think Therefore I blog" project:

  • Post & Comment Models

From a comment on Stackoverflow:

  • Fixed background image

From Codemy "Create a Simple Blog with Python and Django" video playlist:

  • Set up Categories, Edit & Delete post

Content

I take great pride in stating that I have personally developed all the code in this project, demonstrating my dedication and commitment to its creation. While working on this project, I utilized various resources, including those acknowledged in the Credits and Code Used section, which provided valuable insights and inspiration.

Acknowledgments

I would like to thank and acknowledge the following people, who have shown invaluable support throughout my fourth project:

  • Dan Ford, not only as my boyfriend but also as my biggest supporter. His unwavering encouragement and belief in my abilities have been a constant source of motivation and inspiration. I am truly grateful to have him by my side throughout this journey.
  • Joseph Doble has been instrumental in my project, offering assistance with sourcing relevant information and providing clear explanations of how things work and why. His support has been invaluable.
  • Emelie Hansson, a fellow Code Institute student, who has provided me with tremendous support throughout my journey. Her encouragement and assistance have been greatly appreciated.
  • Tutor Support, their patience and willingness to address my endless questions have been instrumental in my learning and growth.
  • Mitko Bachvarov, my mentor at Code Institute, for the great help and support with my project.
  • Kera Cudmore, for the README and TESTING template.

warcraft-mogs's People

Contributors

nicolemne avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.