General Notes: Using goo.gl to Shorten URLs)

Programming Foundations with Python >> Lessons >> Make Classes: Movie Website >> Defining__init__

 

Shorten long URL’s with Google’s URL shortener:

goo.gl

 

This:

import media

toy_story = media.Movie("Toy Story", "story of boy who's toys come to life", "http://upload.wikimedia.org/wikipedia/en/1/13/Toy_Story.jpg", "https://www.youtube.com/watch?v=vwyZH85NQC4")

print(toy_story.storyline)

..could be better with shortened URLs:

import media

toy_story = media.Movie("Toy Story", "story of boy who's toys come to life", "goo.gl/v3of4L", "goo.gl/fQpKqz")

print(toy_story.storyline)
Advertisements

Author: ajoannaproject

Studying Udacity's Full Stack Web Developer program and passing on my improvements, hints, hacks, and updates to other students via ajoannaproject.wordpress.com.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s