$.loginform=function(){
				var txt = '<h1>Enter in SMS<span>Sender</span></h1><div id="error"></div><label>E-mail:</label><input name="username" id="inusername" value="" type="text" size="30" /><label>Password:</label><input name="password" id="inpassword" value="" type="password" size="30" />';
				$.prompt(txt,{
					submit: function(v,m){
						var user = m.find('#inusername').val();
						var pass = m.find('#inpassword').val();
						if(user!=''&&pass!=''){
							if($.browser.msie){
								location.replace(location.href);
							}
							$.post(
								   'http://sms2.contentberry.com/ajax.php',
								   {action:'singin',email:user,pass:pass},
								   function(data){
										if(data=='true'){
											//alert(user+' '+pass);
											//$.cookie('true_user', user+':'+pass, {path:'/', expires:10});
											location.replace(location.href);
											return true;
										}else{ 
											m.find('#error').text('E-mail or password is incorrect');
											return false;
										}
									}
							);
						}
						else {
							m.find('#error').text('E-mail or password is empty');
							return false;
						};
					},
					focus:1,
					buttons:{Ok:true},
					callback: function(v,m){
						location.replace(location.href);
					}
				});
				return false;
			}
			/*$(document).ready(function(){
				if ($.cookie("true_user")){
					var u = $.cookie("true_user").split(":");
					$.post(
						   'http://sms2.contentberry.com/ajax.php',
						   {action:'check',email:u[0],pass:u[1]},
						   function(data){
								if(data=='true'){
									$.cookie('true_user', u[0]+':'+u[1], {path:'/', expires:10});
									return true;
								}else{ 
									$.cookie('true_user', '', { expires: -1 }); 
									$.loginform();
								}
							}
					);					
				}
				else{
					$.loginform();
				}
				$('a.login').click($.loginform);
			});*/
