GithubHelp home page GithubHelp logo

udacity_python's Introduction

Python Movie Website Project Overview

The project submission shows a simple movie trailer website that lists some of my favorite movies, and includes links to their poster images and trailers. This is my submission for the first project in the Udacity full stack web developer nanodegree program.

Recreate this Project

Steps:

  • Download Python (at least 2.7) here: https://www.python.org/download/releases/2.7/
  • Create a file named media.py containing class movie with properties that most movies share (such as title) and functions (actions) that the class will take
    def __init__(self, movie_title, movie_storyline, poster_image, trailer_youtube):
        self.title = movie_title
        self.storyline = movie_storyline
        self.poster_image_url = poster_image
        self.trailer_youtube_url = trailer_youtube
    def show_trailer(self):
        webbrowser.open(self.trailer_youtube_url)
    def show_image(self):
        webbrowser.open(self.poster_image_url
  • Create file named entertainment_center.py with the list of movies containing the properties created in class Movie.. Example:
    song_of_the_sea = media.Movie("Song-of-the-sea",
                        "A boy saves his selkie sister's life by finding her enchanted coat.",
                        "https://cdn.traileraddict.com/content/gkids/song-of-the-sea.jpg",
                        "https://www.youtube.com/watch?v=HgbXWt8kM5Q")
  • Include an array of movies in the entertainment_center.py
    movies = [song_of_the_sea, wall_e, ratatouille, alien, harry_potter, best_in_show]
  • Create a file named fresh_tomatoes.py that takes the list of movies and creates a website displaying their details. This file contains HTML info needed to style the page output relatively nicely.
  • Make sure to import all necessary python modules to all files (example: webbrowser), and save all files in the same folder
  • Also, import media and fresh_tomatoes to the entertainment_center.py file
  • Run entertainment_center.py to open the movie website
  • That's it!
  • NOTE: You can also simply download the files, save them in one folder, and run entertainment_center.py

udacity_python's People

Contributors

torilundfunkhouser avatar

Watchers

 avatar

Forkers

mona3636

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.