function test_ajax()
{
		$.ajax({
		type: "GET",
		url: 'http://office.02.ro/support/index.php',
		cache: false,
		async: true,

		success: function( html ) {
			alert( "ok" );
		},

		error: function( err ) {
			alert( "error" );
		}
	});
}

function close_dialog()
{
    if( JSEN )
        JSEN.closeAjaxDialog();
}

function dialog_loading( options )
{
    if( JSEN )
    {
        var o = $.extend( { title: 'PLEASE_WAIT', message: 'LOADING...', width: 320, height: 100 }, options );

        JSEN.createLoadingDialog( o );
    }
}

function close_loading( suffix )
{
    if( JSEN )
    {
        JSEN.closeLoadingDialog( suffix );
    }
}

function dialog_login()
{
    if( JSEN )
    {
        JSEN.createAjaxDialog( { url: 'http://www.missworld.com/dialogs/login.html',
                width: 450, height: 270, title: 'Quick login' } );
    } else
        document.location = 'http://www.missworld.com/common/login.html';
}

function dialog_forgot_password()
{
    if( JSEN )
    {
        JSEN.createAjaxDialog( { url: 'http://www.missworld.com/dialogs/forgot.html',
                width: 450, height: 270, title: 'Forgot password' } );
    } else
        document.location = 'http://www.missworld.com/common/forgot.html';
}

function coming_soon()
{
   alert( 'Coming soon.' );
}

function div_obj_toggle( div_name )
{
   if( div_name == '' )
       return;

   if( $("#"+div_name) )
   {
       $("#"+div_name).slideToggle("slow");
   }
}

function div_obj_show( div_name )
{
   if( div_name == '' )
       return;

   if( $("#"+div_name) )
   {
       $("#"+div_name).slideDown("slow");
   }
}

function div_obj_hide( div_name )
{
   if( div_name == '' )
       return;

   if( $("#"+div_name) )
   {
       $("#"+div_name).slideUp("slow");
   }
}

function clear_date_field( field )
{
    var field_obj = document.getElementById( field );

    if( field_obj )
    {
        field_obj.value = '';
    }
}


