﻿function DoSubscribe(item, O, E){
var img = BeginProcess(E);
    if(O.checked){
    ItemPageWs.Item_Subscribe(item,
            function(rslt) {
                if(rslt) {
                   AlertMsg('Subscribed');    EndProcess(img); 
                }         
             } 
        );
    }
    else{
    ItemPageWs.Item_UnSubscribe(item,
            function(rslt) {
                if(rslt) {
                      AlertMsg('UnSubscribed');    EndProcess(img); 
                }         
             } 
        );
    }
}


function DoFavorite(item,O, E){
var img = BeginProcess(E);
    if(O.checked){
    ItemPageWs.AddFavorite(item,
            function(rslt) {
                if(rslt) {
                   AlertMsg('Favorite Added');    EndProcess(img); 
                }         
             } 
        );
    }
    else{
    ItemPageWs.RemoveFavorite(item,
            function(rslt) {
                if(rslt) {
                      AlertMsg('Favorite Removed');    EndProcess(img); 
                }         
             } 
        );
    }
}
//setTimeout('ApplyHotSpot($("<%= tdTags.ClientID %>"), "item")', 100);
 //  window.onpageshow= function(){alert(9);}