//取flash对象的兼容方法
function thisMovie(movieName)
{
	return swfobject.getObjectById(movieName);
}
function uploadErrorAction() {
	//console.log("上传错误！");	
	alert("上传错误，请重试");
	if(document.getElementById('ps_submit_p'))
		document.getElementById('ps_submit_p').innerHTML = '<a href="javascript:void(0)" onclick="editname()" >发布微博</a>';
	if(document.getElementById('ps_submit_comment_p'))
		document.getElementById('ps_submit_comment_p').innerHTML = '<a href="javascript:void(0)" onclick="commitComment_PersonalSignature()">发布微博</a>';
	
}


//正在浏览文件
function browseAction() {
	//console.log("正在浏览文件");
	//document.getElementById('ps_type').value= 1;
	//document.getElementById('ps_comment_type').value= 1;
}
function uploadAction() {
	if(document.getElementById('ps_type'))
		document.getElementById('ps_type').value= 1;
	if(document.getElementById('ps_comment_type'))
		document.getElementById('ps_comment_type').value= 1;
	if(document.getElementById('ps_submit_p'))
		document.getElementById('ps_submit_p').innerHTML = '<a href="javascript:void(0)" >上传图片中...请稍后</a>';
	if(document.getElementById('ps_submit_comment_p'))
		document.getElementById('ps_submit_comment_p').innerHTML = '<a href="javascript:void(0)" >上传图片中...请稍后</a>'
	
} 

//返回数据方法
function completeDataAction(data) {
	//console.log("返回数据："+data);
	document.getElementById('ps_img_path').value=data.replace(/(^\s*)|(\s*$)/g, "");
	document.getElementById('ps_comment_img_path').value=data.replace(/(^\s*)|(\s*$)/g, "");
	if(document.getElementById('ps_submit_p'))
		document.getElementById('ps_submit_p').innerHTML = '<a href="javascript:void(0)" onclick="editname()" >发布微博</a>';
	if(document.getElementById('ps_submit_comment_p'))
		document.getElementById('ps_submit_comment_p').innerHTML = '<a href="javascript:void(0)" onclick="commitComment_PersonalSignature()">发布微博</a>';
}