var initial = true;
/*
* boolean (returns true if the form contains values for username and password, 
* and false otherwise)
* checkLoginForm() using jQuery ($(...))
* learned from Chris Power's blog example: 
* the function alters the innerHTML of the error div
* and uses jQuery slideUp and slideDown methods for showing
* the error message to the user
*/
function checkRegFormDe()
{
	if($("#username").val() == "")
	{
		$("#error").slideUp("normal", function()
			{
				$("#error").html("<p>Geben Sie ein Pseudonym ein (6 - 20 Zeichen, Buchstaben und Ziffern).</p>").slideDown("slow");
			}
		);
		
		return false;
	}
	
	if($("#password").val() == "")
	{
		$("#error").slideUp("normal", function()
			{
				$("#error").html("<p>Geben Sie ein Passwort ein (6 - 20 Zeichen, Buchstaben und Ziffern).</p>").slideDown("slow");
			}
		);
		
		return false;
	}
	
		
	if($("#weight").val() == "")
	{
		$("#error").slideUp("normal", function()
			{
				$("#error").html("<p>Bitte geben Sie Ihr Gewicht in kg an (z.B. 111.11)!</p>").slideDown("slow");
			}
		);
		
		return false;
	}
	
	if($("#height").val() == "")
	{
		$("#error").slideUp("normal", function()
			{
				$("#error").html("<p>Geben Sie Ihre Größe in cm an (z.B. 180)!</p>").slideDown("slow");
			}
		);
		
		return false;
	}
	
	return true;	
}

