ciao, in questa pagina vi sono a sinistra dei feed rss, cosa è quel numero (0700) che compare in ogni titolo? ne deduco sia qualcosa che dipenda dal codice perchè è presente in tutti i feed, è possibile eliminarlo? il codice è questo:
codice:
google.load("feeds", "1");
function initialize() {
var attributes = ["title", "link", "publishedDate"];
var feed = new google.feeds.Feed("http://www.gazzetta.it/rss/Calcio.xml");
feed.setNumEntries(5);
feed.load(function(result) {
if (!result.error) {
var container = document.getElementById("sinistra2gazzetta");
for (var i = 0; i < result.feed.entries.length; i++) {
var entry = result.feed.entries[i];
var div = document.createElement("div");
var span = document.createElement('span');
var link = document.createElement('a');
link.setAttribute('target', '_blank');
link.setAttribute('href', entry.link);
link.appendChild(document.createTextNode(entry.title));
//Se volete impostare il nome di una classe per lo stile usate:
//div.setAttribute((document.all ? 'className' : 'class'), 'rosso');
//Questo perchè FF e IE utilizzano un metodo diverso per farlo...
div.style.cssText = 'color:#003; margin:10px 5px 5px 5px;; font-size:12px';
span.style.cssText = 'color:#f0f; font-size:11px';
span.appendChild(document.createTextNode(entry.publishedDate));
div.appendChild(span);
div.appendChild(document.createElement('br'));
div.appendChild(link);
div.appendChild(document.createElement('br'));
container.appendChild(div);
}
}
});
}
google.setOnLoadCallback(initialize);
grazie