опять users.get
Добавлено: 07 мар 2013, 20:52
Подскажите что не правильно ?
Код: Выделить всё
<html> <head> <script type="text/javascript" src="http://vkontakte.ru/js/api/xd_connection.js?2"></script> </head> <script type="text/javascript" charset="cp1251" >window.onload = (function() { VK.init(function() { // инициализируем Vk API var parts=document.location.search.substr(1).split("&"); var flashVars={}, curr; for (i=0; i<parts.length; i++) { curr = parts[i].split('='); flashVars[curr[0]] = curr[1]; } var viewer_id = flashVars['viewer_id']; VK.api("users.get", {"uids": viewer_id,"fields":"photo"}, function(data) { $('#ttt').html(data.response[0].photo); }); </script><body> <div id="ttt"></div> </body></html>