
function tradeAdd(){
var required_n=new Array('姓名','电话','地址','内容');
var required=new Array('txtName','txtTel','txtAddress','txtContent');
for(i=0;i<required.length;i++){
if(g(required[i]).value.Trim()==''){
alert(required_n[i]+' 不能为空！');
g(required[i]).focus();
return;}}
var re=Controls_trade_trade_add._tradeAdd(getTextValue('txtName'),getTextValue('txtTel'),getTextValue('txtQQ'),getTextValue('txtAddress'),getTextValue('txtContent'),getRadioValue('rbtType')).value;
if(re=="ok"){
alert('发布成功！');
location.href=location.href;}
else{
alert(re);
return;}}
