
    /**
    * default javascript file
    */

    $('html').addClass('js');

    $(function() {

        /**
        * throw entire script in a variable to avoid clashes with other scripts
        */
        var ANVIL = {
            
            setup : function () {
                // $('a[rel=facebox]').facebox();
                $("td:empty, th:empty").html("&nbsp;");
                ANVIL.wysiwyg_setup();
            } ,

            /**
            * load tinymce for wysiwyg edit functionality
            */
            wysiwyg_setup : function () {
                // location of server. Unfortunately not dynamic, absolute URL necessary
                var SERVER = 'http://localhost/checkout/framework-contract/';

                // Initializes all textareas that have class wysiwyg.
                if (jQuery().tinymce) {
                    $('textarea.wysiwyg').tinymce({
                        script_url : SERVER+'js/tiny_mce/tiny_mce.js' ,
                        mode : "exact" ,
                        theme : "advanced",
                        theme_advanced_toolbar_location : "top" ,
                        // for other buttons, see http://wiki.moxiecode.com/index.php/TinyMCE:Control_reference
                        theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,outdent,indent,|,bullist,|,charmap,|,undo,redo" ,
                        theme_advanced_buttons2 : "" ,
                        theme_advanced_buttons3 : "" ,

                        content_css : SERVER+"css/haskell.css" , // load styles defining look of the editor, also connected with styleselect button above
                        theme_advanced_styles : "Some Class=class1,See wysiwyg.js=class2" , // only list custom styles
                        theme_advanced_blockformats : "h1,h2,h3,h4,h5,h6,blockquote,code"
                    });
                }
            }

        }

        ANVIL.setup();

    });

    $(document).ready(function() {

        $('#nav_on').attr('background','url(../images/nav_on.gif) repeat-x 0 0')

    });








