<?xml version="1.0" encoding="UTF-8" ?> 
 <Module>

 <ModulePrefs  
    title="2P START!" 
    title_url="http://www.2pstart.com/"
	category="funandgames"
	scrolling="false"
	author="Tim Harding"
	directory_title="2P START!"
	author_email="tim@2pstart.com"
	author_affiliation="2P START!"
	author_location="Thousand Oaks, CA"
	screenshot="http://www.2pstart.com/images/2pstart_scrnsht.png"
	singleton="false"
	thumbnail="http://www.2pstart.com/images/2pstart_thm.png"
	description="2P START! Webcomic, updated weekly!">
	<Require feature="dynamic-height" />
	<Require feature="analytics"/>
</ModulePrefs>	

<UserPref name="num_entries" display_name="Show:" default_value="3" datatype="enum">
<EnumValue display_value="1 entry" value="1"/>
<EnumValue display_value="2 entries" value="2"/>
<EnumValue display_value="3 entries" value="3"/>
<EnumValue display_value="4 entries" value="4"/>
<EnumValue display_value="5 entries" value="5"/>
<EnumValue display_value="6 entries" value="6"/>
<EnumValue display_value="7 entries" value="7"/>
<EnumValue display_value="8 entries" value="8"/>
<EnumValue display_value="9 entries" value="9"/>
</UserPref>


 <Content type="html">
   <![CDATA[ 
   <style> #content_div {font-size: 12px; margin: 5px; background-color: #FFFFFF;}
           .spacer {font-size:70%; color: #777; margin-bottom: 8px; margin-left: 10px;} </style>
 
 <div id=content_div></div>
 <script type="text/javascript">
     // Get userprefs
     var prefs = new _IG_Prefs(__MODULE_ID__);
     var entries = prefs.getInt("num_entries");

     // Use the _IG_FetchFeedAsJSON() function to retrieve core feed data from
     // the specified URL. Then combine the data with HTML markup for display in
     // the gadget.
	 
	 var contentURL='http://www.2pstart.com/wordpress/wp-feed.php';
	 
     _IG_FetchFeedAsJSON(contentURL,
	          function(feed) { 
     
         // Start building HTML string that will be displayed in gadget.
         var html = "";

         // Access the data for a given entry
         if (feed.Entry) {
             for (var i = 0; i < feed.Entry.length; i++) {
                 html += "<div>"
                 + "<a href='" + feed.Entry[i].Link + "' target='_blank'>"
                 + feed.Entry[i].Title
                 + "</a> ";
                 html += "</div>";
				 html += "<div class='spacer'>" + " " + "</div>";
             }
         }
     _gel("content_div").innerHTML = html;

     _IG_AdjustIFrameHeight();

     // The rest of the function parameters, which are optional: the number
     // of entries to return, and whether to return summaries.
     }, entries);
 
 	 _IG_Analytics("UA-1233341-2", "/2pstartgadget");
 	</script>
 ]]> 
 </Content>
 </Module>