var photoCoor = {"lat":"0","lng":"0"}; function initialize() { if(google){ var myLatlng = new google.maps.LatLng(photoCoor.lat,photoCoor.lng); var myOptions = { zoom: 2, center: myLatlng, disableDefaultUI: true, mapTypeId: google.maps.MapTypeId.ROADMAP }; var map = new google.maps.Map(document.getElementById("map"), myOptions); var marker = new google.maps.Marker({ position: myLatlng, map: map }); } } photoId = 465564; photoIds = 0; userId = 65114; photoData = {"photo_id":465564,"user_id":65114,"user_login":"peshev","user_name":"Hristo Peshev","photo_name":"hristopeshev.eu","src":"http:\/\/ser-apr.35photo.ru\/photos\/20130114\/465564.jpg","link":"http:\/\/35photo.ru\/photo_465564\/","bg":"4D4D4D","comm_count":34,"photo_see":2567,"photo_fav":1,"photo_rating":167,"var_vote":null,"timeAdd":"14 \u044f\u043d\u0432, 2013","user":{"status":"good"},"buyAllow":0,"photo_type":4,"moder":{"yes":"10","no":"0"},"user_data":{"photo_count":"31"},"photo_desc":"www.hristopeshev.eu
\r\nhttp:\/\/www.facebook.com\/hristopeshev.eu","tags":null,"other_photos":[{"id":"654098","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/130\/654098_320r.jpg"},{"id":"651243","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/130\/651243_320r.jpg"},{"id":"648283","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/129\/648283_320r.jpg"},{"id":"581564","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/116\/581564_320r.jpg"},{"id":"580399","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/116\/580399_320r.jpg"},{"id":"570554","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/114\/570554_320r.jpg"},{"id":"542276","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/108\/542276_320r.jpg"},{"id":"536430","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/107\/536430_320r.jpg"},{"id":"531304","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/106\/531304_320r.jpg"},{"id":"529136","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/105\/529136_320r.jpg"},{"id":"528876","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/105\/528876_320r.jpg"},{"id":"521674","src":"http:\/\/ser-apr.35photo.ru\/photos_col\/r2\/104\/521674_320r.jpg"}],"otherData":"","series":[{"id":"345071","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345071.jpg","like":"28","title":"Flamingo"},{"id":"345072","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345072.jpg","like":"15","title":"Shepherd"},{"id":"345073","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345073.jpg","like":"27","title":"Buffalos at Kerkini Lake"},{"id":"345074","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345074.jpg","like":"30","title":"Pelicans at Kerkini Lake"},{"id":"345075","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345075.jpg","like":"18","title":"Kerkini Lake"},{"id":"345076","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345076.jpg","like":"25","title":"Raven"},{"id":"345077","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345077.jpg","like":"29","title":"Flamingo"},{"id":"345078","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345078.jpg","like":"11","title":"Stela"},{"id":"345079","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345079.jpg","like":"13","title":"Rock Bunting (Emberiza cia)"},{"id":"345080","src":"http:\/\/ser-apr.35photo.ru\/photos_series\/345\/345080.jpg","like":"16","title":"Buffalos at Kerkini Lake"}]}; lastRePost = null; thisPageUrl = "http://peshev.35photo.ru/photo_465564/"; setBgComm = "#444444"; whovotelike = ""; commentTo = "photo_465564"; allowAddComm = false; jQuery(function( $ ){ SetBG('#4D4D4D', '##CCCCCC'); loadComm(); showSimilar(); //resizeAllImages(); ilike.checkAll(); facebookGraph(); showBgBlock(); }); function getPhotoByJson( url ){ showLoadingPhoto( "loading" ); $("#moVotes23").hide(); $.ajax({ type: "GET", dataType: "jsonp", data: {}, url: url, error: function (jqXHR, textStatus, errorThrown) { //console.log("error load Photo"); }, success: function (data) { for (var p in data.data){ if (data.data.propertyIsEnumerable(p)){ //update banner rand = Math.floor(Math.random()*99999999999); clickurl_enc = encodeURI(window.location); $("#a139d7a2").attr( "src", "http://adv.muslib.ru/www/delivery/afr.php?zoneid=4&target=_blank&cb=" + rand + "&ct0=" + clickurl_enc ); //$("#a139d7a2").attr( "src", function ( i, val ) { return val; }); //console.log("banner update: " + $("#a139d7a2").attr( "src" ) ); photoData = data.data[p]; showPhotoByJson(); $("#liveinternetBlock").html( liveinternet() ); //1000x90 $(".ac662eaa").attr( "src", "http://adv.muslib.ru/www/delivery/afr.php?zoneid=5&target=_blank&cb=" + rand + "&ct0=" + clickurl_enc ); return true; }else{ showAlert("Last photo."); return true; } } showAlert("The End. No more photo. Choose other direction"); $( mainPhoto ).hide().fadeIn(100); showLoadingPhoto(); } }); }; function getCommByJson( photoId ){ var url = "http://35photo.ru/show_block.php?type=comments&type2=showAllPhotoComm&photoId=" + photoId; $.ajax({ type: "GET", dataType: "jsonp", data: {}, url: url, error: function (jqXHR, textStatus, errorThrown) { //console.log("error load comm"); }, success: function (data) { //console.log("show comm - ok"); $("#commentsBlock").html( data.data ); loadComm(); } }); }; function showSeriesPohotoPrev(){ //$(".seriesPhotoPrev").remove(); selectPhotoInSeries = 0; $("#zonePhotoInScroll").html(""); $("#zonePhotoInScroll").css("height", "auto" ); //SeriesPhoto if( photoData.series ){ //vertical //$("#zonePhotoInScroll").css("min-height", zonePhotoInScrollH ); //$("#btn_photo_right").hide(); //seriesPoints = $( '