//alert("wif_functions loaded");

function wif_create_modal(foo, ourtype){
	//alert("in create modal");
	var content;
	
	content = "<table><tr>";
	content += "<td>" + foo + "</td>";
	content += "</tr></table>";
	
	options = $.extend({title: ourtype, modal: true});
	var dialog = new Boxy(content, options);
	allDialogs.push(dialog);
	return false;
}

function wif_agent_login(){
	var content;
	
	content = '<form method="post" action="index.php">';
	content += '<label>Username</label>';
	content += '<input class="input" style="width: 240px;" name="username" type="text" />';
	content += '<label>Password</label>';
	content += '<input class="input" style="width: 240px;" name="password" type="text" />';
	content += '<input name="form_field" type="hidden" value="wif_agent_login" /><br><br>';
	content += '<input style="display: block;" value="login" type="submit" class="action"/>';
	content += '</form>';

	wif_create_modal(content, "Agent Login");
}
