If a certain external site returns a string like "cost is 10$", is it possible for me to display it as "price:10$" on my own website using only Javascript? The external site could be something like Facebook.com. My website, of course, belongs to me.
Hello everyone. I am making edits to a question where I need to retrieve data FROM an external site. Simply modifying strings is easy, but what I really need is something like this:
var str = GetData("http://facebook.com/blablbal");
str.Replace('blbablab','blabal');
ShowToUser(str);
I hope that makes sense. Excuse me if my English isn't perfect - it's not my native language.
What I mean is retrieving data using XMLHttpRequest or iframe and then manipulating it. Unfortunately, one of the moderators edited my question and changed the title without understanding my actual query.
Here is a concrete example:
http://vkontakte.ru/share.php?act=count&index=[index]&url=http://talismansochi2014.ru/grandfather_frost/go.php returns
VK.Share.count(0, 8718);
I want to extract the number 8718 and display it to the user. And I can only use JS. I cannot make requests from the server and then return a webpage.
Do I need to reformulate my question or provide additional information?