/**
 * @author tim.ullrich
 */
		$(document).ready(function(){
			
			$(".dialog").hide();
			
			$("#register_now").click(function(e){
     		// send request
     		$.post("command.php", {command: "register", params: $("#input_username").attr('value')+","+$("#input_password").attr('value')}, function(xml) {

			if ($("errorcode", xml).text() > 0) {
				// format and output result
				$("#Dialog_Register_Error").html($("message", xml).text() +
				"(" +
				$("errorcode", xml).text() +
				")");
			}else{
				$("#main_message_div").html($("message",xml).text());
				tb_remove();
			}
			
     		});
         	// stop normal link click
     		return false;
			});

		});//eof $(document).ready(function()