Answer the question
In order to leave comments, you need to log in
When loading via $resource rss feed using google rss reader api chrome loads endlessly what to do?
I upload via $resource rssku, there are images in it, for some reason these images also start to be loaded and are loaded endlessly, which blunts the browser. How can I make it load only rss and images not load?
Code part:
feedModule.factory('FeedLoader', function ($resource) {
return $resource('http://ajax.googleapis.com/ajax/services/feed/load', {}, {
fetch: { method: 'JSONP', params: {v: '1.0', callback: 'JSON_CALLBACK', timeout: 1000} }
});
})
Answer the question
In order to leave comments, you need to log in
нашел проблему. я чтобы очистить html от тэгов создавал dom элемент и брал его innerText. Соответственно поэтому грузились картинки. Заменил regexp.
function strip(html)
{
var regex = /(<([^>]+)>)/ig;
html = html.replace(regex, "");
return html.replace(regex, "");
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question