Module to check online resource availability & inf

Created on Feb 4, 2013

This module can be called to check the availability of a website.
You must pass it the following variables:
  'url'         - this is the full url of the site in question (i.e. "http://www.google.com").
  'userAgent'   - this is an optional variable. Either leave it blank or pass it a User_Agent 
                  string (i.e. '' or 'Mozilla/5.0 (Windows NT 6.1; rv:5.0) Gecko/20100101 Firefox/5.02').
                  
This module returns a dictionary with information regarding the site status, redirection, http code, and url.

Below are two samples of the return:
1) {'Redirect': 'None', 'Status': 'Site OK', 'Message': 'OK', 'Code': 200, 'URL': 'http://www.google.com'}
    
2) {'Redirect': 'http://10.0.2.52:15871/cgi-bin/blockpage.cgi?ws-session=2635420846', 'URL': 'http://www.playboy.com', 
     'Message': 'Moved Temporarily', 'Code': 302, 'Status': 'Site Redirected'}
    
This module can be called as follows:
    import checkSiteStatus
    url = "http://www.google.com"
    x = checkSiteStatus.checkWebsite(url)
    siteInfo = x.checkSite(url)
    print siteInfo["Code"]
    
    >>>200
    #if only my enemy was greater than my apathy...
    
    
@author: nephos