Function.prototype.defaults = function() {
  var _f = this;
  var _a = Array(_f.length-arguments.length).concat(
    Array.prototype.slice.apply(arguments));
  return function()
  {
    return _f.apply(_f, Array.prototype.slice.apply(arguments).concat(
      _a.slice(arguments.length, _a.length)));
  }
}

var sendtofriend = function(form_id) {
	window.open('','Web1','toolbar=no,location=no,status=no,scrollbars=no,width=470,innerWidth=470,height=630,innerheight=630,screenX=0,screenY=0,resizable=yes');
	document.forms[form_id].submit();
	return false;
}.defaults('tafform');
