So, I'm using the feeds API to show recent updates from my wordpress based 
blog on a site.  Everything works perfect except smart quotes.  As you may 
know, wordpress (in my opinion annoyingly) converts your quotes to smart 
quotes.  It also does this for the feed.

After the feeds api reads it, it somehow terns this into the html character 
code (but it does it incorrectly; in the code it is ’ -- so the 
user sees ’ in the page).  This is the code doing this (as you can see 
this isn't very complicated):

feed.setNumEntries(5); feed.load(function(result) { if (!result.error) { var 
container = document.getElementById("rssHeap"); for (var i = 0; i < 
result.feed.entries.length; i++) { var entry = result.feed.entries[i]; var 
div = document.createElement("div"); div.className = 'rss'; var title = 
document.createTextNode(entry.title); var ahref = 
document.createElement("a"); ahref.className = 'rss_link'; var summerytext = 
document.createTextNode(entry.contentSnippet); var summery = 
document.createElement("div"); summery.className = 
'rss_summery';summery.appendChild(summerytext);ahref.setAttribute('href', 
entry.link);ahref.appendChild(title);div.appendChild(ahref);div.appendChild(summery)container.appendChild(div);}}});}

-- 
You received this message because you are subscribed to the Google Groups 
"Google AJAX APIs" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-ajax-search-api/-/ITYkIPt7HdYJ.
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