Skip to content
This repository has been archived by the owner on Jun 25, 2018. It is now read-only.
/ analyze_this Public archive

A web service that provides data on a given web page

Notifications You must be signed in to change notification settings

humanzz/analyze_this

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Analyze This

Analyze This is a solution to the problem of trying to preview a link from within a browser - like facebook’s “share a link” feature.

oEmbed and oohEmbed try to solve the problem of a how a url should be represented on a page. For example, if it’s a flickr photo url, the thumbnail can be shown, if the url is a youtube video, a player should be embedded and so on. The problem with oEmbed and oohEmbed is that the list of supported websites is limited.

Analyze This on the other hand tends to handle webpages in a generic way by providing data that is common on all web pages. That is: title, description, keywords, and images list.

Given a webpage’s url, the application returns a JSON object representing the webpage’s info. The application uses JSONP so that the caller can provide a callback function.

Web UI

The web UI is more for fun and showing what the application can do

API

The API is accessible at analyzethis.espace-technologies.com/js and all you need to provide it with is url parameter and an optional callback if you need it. For example, a page requesting information about a URL provided in an input#url can use the following code snippet

$(document).ready(function(){
  $('#button').click(function(){
  var url = encodeURIComponent($('#url')[0].value);
  $('<script>').attr('type','text/javascript').attr('src','http://analyzethis.espace-technologies.com/js?callback=analyze_this&url='+url).appendTo('body');
  });
});

which would result in a call to the javascript function analyze_this({..}) passing in a JSON object that has the page’s info.

Analyze This is available at analyzethis.espace-technologies.com

About

A web service that provides data on a given web page

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published