if(jQuery)(
    function(jQuery){

        jQuery.extend({
            newMailAjax: {
                id: 'new_mail',
                ready: function(){

                    return true;
                },
                beforeSend: function(){
                    return true;
                },
                success: function(data){

                    //$("#wiadomosci").html(data);
                },
                error: function(){
                    return true;
                }

            }
        })

        jQuery.fn.extend({
            getFriends: function(){

                $("#jquery-container-box").html("<div class='preloader' style='width: 100%; text-align: center;' ><img src='/public/images/ajax-loader.gif' alt=''/></div>")
                $.get("/mail/index/napisz-ajax?",null, function(data){
                    $("#jquery-container-box").hide().html(data).fadeIn();
                });
                return $(this);
            }/*,
            getMail: function(){
            /*$(this).everyTime(5000,'ajaxMail',function(){
                            $.get('/mail/index/newmessage', function(data){
                                $("#wiadomosci").html(data);
                            });

                    });*/
            //}

		
        })
    })(jQuery);/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */


$(document).ready(function() {
    /*$.get('/mail/index/newmessage', function(data){
                                $("#wiadomosci").html(data);
                            });

    $('#messagePanel').getMail();*/
    
    });

