!window.jQuery && document.write('<script src="/javascript/jquery.min.js"></script>');

$(document).ready(function()
{
	// Sign in div hide:
	$('div#signin').children('form').children().each(function(){
		$(this).css('display', 'none');
	});
	$('button#signin-show').css('display', 'block');
	$('div#signin').css('width', '97px');
	$('button#signin-show').click(function(){
		$('div#signin').animate({width: '445px'}, 300, function(){
			$('div#signin').children('img').animate({opacity: 'show'}, 300, function(){
				$(this).click(function(){
					$(this).animate({opacity: 'hide'}, 300);
					$('div#signin').children('form').children('input').each(function(){
						$(this).animate({opacity: 'hide'}, 300);
					});
					setTimeout(function(){
						$('div#signin').animate({width: '97px', height: '37px'}, 300);
					}, 300);
					$('button#signin-show').css('display', 'block');
					$('div#signin').children('form').children('button').each(function(){
						$(this).css('display', 'none');
					});
				});
			});
			$('div#signin').children('form').children('input').each(function(){
				$(this).animate({opacity: 'show'}, 300);
			});
			$('div#signin').children('form').children('button').each(function(){
				$(this).css('display', 'block');
			});
			$('button#signin-show').css('display', 'none');
		});
		return false;
	});
});

/*function ConnectMainLinks()
{
	$('a#blog').click(function()
	{
		var add, body;
		if(module == 'blog')
		{
			add = '1/';
			body = $('div#content');
		}
		else
		{
			add = '';
			body = $('div#text');
			if(loadedCSS['blog'] != true)
			{
				$.getScript(baseUrl+'js/blog/index.js');
				$(document.createElement('link')).attr(
					{'type': 'text/css', 'href': baseUrl+'design/blog/index.css', 'rel': 'stylesheet'}
				).appendTo('head');
			}
			module = 'blog';
		}
		$.get($(this).attr('href')+'/page/'+add+'?ajax=1',
			{},
			function(returned_data)
			{
				if(loadedCSS['blogEntries'] != true)
				{
					$.getScript(baseUrl+'js/blog/entries.js');
					var head = document.getElementsByTagName('head')[0];
					$(document.createElement('link')).attr(
						{'type': 'text/css', 'href': baseUrl+'design/blog/entries.css', 'rel': 'stylesheet'}
					).appendTo('head');
					loadedCSS['blogEntries'] = true;
				}
				body.animate(
					{opacity: "hide"},
					400,
					function()
					{
						body.html(returned_data);
						body.animate(
							{opacity: "show"},
							400
						);
						if(typeof BlogConnectEntries == 'function')
						{
							BlogConnectEntries();
						}
					}
				)
			}
		);
		return false;
	});
	$('a#footer-blog').click(function()
	{
		var add, body;
		if(module == 'blog')
		{
			add = '1/';
			body = $('div#content');
		}
		else
		{
			add = '';
			body = $('div#text');
			if(loadedCSS['blog'] != true)
			{
				$.getScript(baseUrl+'js/blog/index.js');
				$(document.createElement('link')).attr(
					{'type': 'text/css', 'href': baseUrl+'design/blog/index.css', 'rel': 'stylesheet'}
				).appendTo('head');
			}
			module = 'blog';
		}
		$.get($(this).attr('href')+'/page/'+add+'?ajax=1',
			{},
			function(returned_data)
			{
				if(loadedCSS['blogEntries'] != true)
				{
					$.getScript(baseUrl+'js/blog/entries.js');
					var head = document.getElementsByTagName('head')[0];
					$(document.createElement('link')).attr(
						{'type': 'text/css', 'href': baseUrl+'design/blog/entries.css', 'rel': 'stylesheet'}
					).appendTo('head');
					loadedCSS['blogEntries'] = true;
				}
				body.animate(
					{opacity: "hide"},
					400,
					function()
					{
						body.html(returned_data);
						body.animate(
							{opacity: "show"},
							400
						);
						if(typeof BlogConnectEntries == 'function')
						{
							BlogConnectEntries();
						}
					}
				)
			}
		);
		return false;
	});
}
*/

