This really only works if you're using the default FeedControl and its  
auto-generated html.  Since you're not, you will need to add the  
target in manually.  More specifically, add the target into the code  
generated for rssoutput, as below:

rssoutput+="<li><a href='"+thefeeds[i].link+"'  
target='"+google.feeds.Feed.LINK_TARGET_BLANK+"'>"+thefeeds[i].title 
+"</a></li>"

Jeremy R. Geerdes
Effective website design & development
Des Moines, IA

For more information or a project quote:
http://jgeerdes.home.mchsi.com
http://jgeerdes.blogspot.com
http://jgeerdes.wordpress.com
[email protected]

Unless otherwise noted, any price quotes contained within this  
communication are given in US dollars.

If you're in the Des Moines, IA, area, check out Debra Heights  
Wesleyan Church!

And check out my blog, Adventures in Web Development, at 
http://jgeerdes.blogspot.com 
  !


On Mar 16, 2009, at 8:26 PM, Nick Dynice wrote:

>
> I cannot figure out where to put this option.  Here is my code:
>
> <div id="feeddiv"></div>
>
>
>
>
> <script type="text/javascript">
>
> var feedcontainer=document.getElementById("feeddiv")
> var feedurl="http://www.gibraltarhardware.com/diy/index.php/comments/
> feed"
> var feedlimit=5
> var rssoutput="<b>Latest Comments from the Community</b><br /><ul>"
>
> function rssfeedsetup(){
> var feedpointer=new google.feeds.Feed(feedurl) //Google Feed API
> method
> feedpointer.setNumEntries(feedlimit) //Google Feed API method
> feedpointer.load(displayfeed) //Google Feed API method
> }
>
> function displayfeed(result){
> if (!result.error){
> var thefeeds=result.feed.entries
> for (var i=0; i<thefeeds.length; i++)
> rssoutput+="<li><a href='" + thefeeds[i].link + "'>" + thefeeds
> [i].title + "</a></li>"
> rssoutput+="</ul>"
> feedcontainer.innerHTML=rssoutput
> }
> else
> alert("Error fetching feeds!")
> }
>
> window.onload=function(){
> rssfeedsetup()
> }
>
> </script>
>
>
> I found this in some example code but no matter where I put it, I
> cannot get the item links to open to a new tab/window.
>
>  var options = {
>    numResults : 16,
>    linkTarget : google.feeds.LINK_TARGET_BLANK
>  }
>  new GFdynamicFeedControl(feed, "feedControl", options);
>
> >


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google AJAX APIs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-AJAX-Search-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to