/* jQuery Json Parser widget application developed by Ari Koinuma, September 2008.  
This script will parse an Json file and spits out a div which contains the listing of entries.  What gets displayed are user-configurable.  

Documentation: http://infoserverwiki.publicradio.org/index.php/JQuery
Dependency: jquery 1.2.6, feed_widget_class.js
*/

//This portion is the blog-specific code. 
//Here are blog-specific URLs.  Be sure to put the blog initials to the variable names in case there are more than one widget embedded on a page. 
var tgbPrgUrl = 'http://marketplace.publicradio.org/';
var tgbPrgLogoUrl = 'http://www.publicradio.org/columns/sustainability/greenwash/feed_widget/mkp_logo.gif';
var tgbCssUrl = 'http://www.publicradio.org/columns/sustainability/greenwash/feed_widget/feed_widget.css'
var tgbFormURL = "http://marketplace.publicradio.org/tools/widgets/greenwash_feed_widget/";
var tgbButtonURL = "http://www.publicradio.org/columns/sustainability/greenwash/feed_widget/tgb_widget_add_button.gif";
var tgbTagLine = "Bloggers examine eco-friendly claims by companies";

//Here's a blog-specific customizations


//Construct the widget object.  But the actual displaying of the widget will be taken care of by the inline code user embeds. 
function tgbExecute() {
	/*Here's the constructor of the widget object: Widget(feed, widgetId, blogLogoUrl, cssUrl, corpLogoCode, formURL, buttonURL, tagLine)  feedId+Widget is the target div ID.  corpLogoCode will be already assigned to a global variable by the class -- so it's going to be either apmLogo or mprLogo.*/
	var widgetName = new Widget(tgbFeed, 'tgbWidget', tgbPrgUrl, tgbPrgLogoUrl, tgbCssUrl, tgbFormURL, tgbButtonURL, tgbTagLine);
	//remove all videos and Flash objects
	widgetName.showFlash = false;
	widgetName.parseEntries();
	return widgetName;
}

//execute
var tgbWidget = tgbExecute();


