﻿ 
         //Google Analytics kod
         var _gaq = _gaq || [];
         _gaq.push(['_setAccount', 'UA-8115401-10']);
         _gaq.push(['_trackPageview']);

         (function () {
             var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
             ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
             var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
         })();

 
        (function ($) { // encapsulated $
            $(function () { // Dom Ready Shortcut
                $(document).ready(function () {

                    if ($("#lblHeader").text().length <= 0)
                        $("#divHeader").hide();

                    if ($("#lblMainText").text().length <= 0)
                        $("#mainText").hide();

                    $(".pufffrontPage a").click(function () {

                        if ($(this).attr('title') == "Video") {

                            var VideoId = "#Video" + $(this).attr('id');

                            $(VideoId).dialog({
                                bgiframe: true,
                                autoOpen: false,
                                position: [550, 100],
                                height: 335,
                                width: 510,
                                modal: true,
                                resizable: false,
                                overlay: { opacity: 0.5, background: 'black' }
                            });
                            $(VideoId).dialog('open');
                            return false;
                        }
                    });
                });
            });
        })(jQuery);                 // Passing it as the param 
 
