PageSourceSearch

https://vnpt-invoice.com.vn/DesktopModule/UIUtilityControls/UIAdvertisement/Advertisement.js

js vnpt-invoice.com.vn collected 2026-10-08 09:45:26 UTC 2,512 bytes, 57 lines download raw bytes

1(function ($) {
2    $.fn.showAdvertisement = function (options) {
3        var params = { displayType: 'Center' };
4        params = jQuery.extend(params, options);
5        var self = $(this);
6        var titleBar = self.find('.AdvertTitleBar');
7        switch (params.displayType)
8        {
9            case 'Center':
10                var mask = $('<div class="AdvertisementBG"></div>').appendTo($('body')).css({ width: $(document).width(), height: $(document).height() });
11                $(this).css({ left: ($(window).width() - $(this).width()) / 2, top: ($(window).height() - $(this).height()) / 2 });
12                var btnClose = titleBar.find('.Collapse');
13                btnClose.click(function () { mask.remove(); self.remove(); });
14                break;
15            case 'BottomRight':
16                var btnCollapse = titleBar.find('.Collapse');
17                var btnExpand = titleBar.find('.Expand').hide();
18                var divContent = self.find('.AdvertContent');
19                btnCollapse.click(function () {
20                    divContent.hide(500);
21                    btnExpand.show();
22                    btnCollapse.hide();
23                });
24                btnExpand.click(function () {
25                    divContent.show(500);
26                    btnCollapse.show();
27                    btnExpand.hide();
28                }); 
29                break;
30            case 'AutoBottomLeft':
31                function scrollSticky() {
32                    self.attr('style', 'position:absolute; top:' + $(window).scrollTop() + 'px;');
33                }
34                $(window).scroll(function () {
35                    clearTimeout($.data(this, 'scrollTimer'));
36                    $.data(this, 'scrollTimer', setTimeout(function () {
37                        scrollSticky();
38                    }, 10));
39                });
40                break;
41            case 'AutoBottomRight':
42                function scrollSticky() {
43                        self.attr('style', 'position:absolute; top:' + $(window).scrollTop() + 'px;');
44                }
45                $(window).scroll(function()
46                {
47                    clearTimeout($.data(this, 'scrollTimer'));
48                    $.data(this, 'scrollTimer', setTimeout(function () {
49                        scrollSticky();
50                    }, 10));
51                });
52                break;
53            default:
54                break;
55        }
56    }
57})(jQuery);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.