function deleteVideoByAdmin(url){
var reason=prompt('Enter reason for removing this pic/video');
document.frmViewVideo.src_pg.value="video";
document.frmViewVideo.reason.value=reason;
if(document.frmViewVideo.reason.value==null || document.frmViewVideo.reason.value.length==0){
alert("please enter a reason to delete a video");
return false;
}
document.frmViewVideo.action=url
document.frmViewVideo.submit();
}

function validateandpostcvidomm(isPhotoExists,userlevel,isProfileViewable,isProfileActive,isProfileBanned,isCommnetAvail,url) {
		if(!isPhotoExists){
			alert("You should have a profile photo to post your comment.");
			return;
		}
		if(!userlevel || userlevel < 20){
			alert("Join this group to post your comment.");
			return;
		}
		if(!isProfileViewable){
			alert("Your profile should be veiwable to post your comment.");
			return;
		}
		if(!isProfileActive){
			alert("Your profile should be active to post your comment.");
			return;
		}
		if(isProfileBanned){
			alert("Your profile should not be banned to post your comment.");
			return;
		}

	if(document.postcomments.title.value == ""){
		alert("Please enter any title."); 
		return;
	}
	if(document.postcomments.message.value == ""){
		alert("Please enter your comments."); 
		return;
	}     
	
	document.postcomments.action = url;
	document.postcomments.submit();
	
}
function deleteVideoComment(url) {
var bConfirm = confirm("Are you sure want to delete the comment?")
if (bConfirm){
	document.postcomments.action = url;
	document.postcomments.submit();
}
}

