Page 1 of 1

gigabyte.com - content missing

Posted: 2022-01-11, 13:34
by back2themoon
Example: https://www.gigabyte.com/Motherboard/B5 ... v-10/sp#sp

The full specifications text should appear, but it doesn't. Also tested on clean Pale Moon portable 29.4.3.

Re: gigabyte.com - content missing

Posted: 2022-01-11, 14:32
by Moonchild
back2theredboxabove

Re: gigabyte.com - content missing

Posted: 2022-01-11, 15:27
by back2themoon
ReferenceError: event is not defined
sp:1699:1
This site appears to use a scroll-linked positioning effect. This may not work well with asynchronous panning; see https://developer.mozilla.org/docs/Mozi ... kedEffects for further details

------------------------
2022-01-11_171807.png
Error: ReferenceError: event is not defined
Line: 1699



Code: Select all

            if ($(event.currentTarget).data("pid")) {
                window.childProductId = $(event.currentTarget).data("pid");
            } else {
                window.hasLoadMemorySupport = false;
            }

            if (typeof (isNoTriggerAjax) === 'undefined') {
                isNoTriggerAjax = true;
            }

            var thisHashArray = window.hashArray;
            $('.ajax-loading').removeClass('hide');
            clearInterval(window.iframeLoadedFun);
            window.iframeLoadedFun = null;
            var mainItems = $("#model-item").find("li[data-type='" + contentType + "']");
            if (contentType !== "ov/kf") {
                window.hashArray[0] = contentType;
                if (contentType === "support") {
                    try {
                        if (mainItems.length === 1) {
                            var urlPushState = mainItems.find("a").attr("href");
                            var state = {
                                date: new Date(),
                                contentType: contentType
                            };
                            if (!window.UsePopstate) {
                                history.pushState(state, "ModelPageAjaxPushState", urlPushState);
                            } else {
                                window.UsePopstate = false;
                            }
                        } else {
                            window.location.hash = window.hashArray.join('-');
                        }
                    } catch (e) {
                        window.location.hash = window.hashArray.join('-');
                    }
                } else {
                    window.hashArray = [];
                    window.hashArray[0] = contentType;
                    
                    if (needToChange && thisHashArray !== "buy") {
                        try {
                            if (mainItems.length === 1) {
                                var urlPushState = mainItems.find("a").attr("href");
                                var state = {
                                    date: new Date(),
                                    contentType: contentType
                                };
                                if (!window.UsePopstate) {
                                    history.pushState(state, "ModelPageAjaxPushState", urlPushState);
                                } else {
                                    window.UsePopstate = false;
                                }


                            } else {
                                window.location.hash = window.hashArray[0];
                            }
                        } catch (e) {
                            window.location.hash = window.hashArray[0];
                        }
                    } else {
                        var temphash = window.location.hash.split('?');
                        if (temphash.length > 1) {
                            window.location.hash = window.hashArray[0] + "?" + temphash[1];
                        } else {
                            window.location.hash = window.hashArray[0];
                        }
                    }

                }
            }
            window.useContentType = contentType;
            if ($('#model-item>li[data-type="' + window.hashArray[0] + '"]').length <= 0) {
                $('#model-item>li').first().trigger('click');
                if (typeof(cb) === "function") {
                    cb();
                }
                setTimeout(function() { AjaxIsRuning = false; }, 800);
            } else {
                if (window.firstTimeShowContent && isNoTriggerAjax) {
                    var modelContent = $('.model-content');
                    if (typeof(cb) === "function") {
                        AjaxCbFunctionExecute(cb, contentType);
                    } else {
                        AjaxNotCbFunctionExecute(modelContent, "", contentType);
                    }
                    AjaxAfterExecuteFunction(contentType);
                    window.firstTimeShowContent = false;
                    if (window.isCN) {
                        var replaceItem = $(".header-sub-title").add(".section-bottom").add(".section-top");
                        var replaceItemLength = replaceItem.length;
                        for (var i = 0; i < replaceItemLength; i++) {
                            var replaceItemEq = replaceItem.eq(i);
                            replaceItemEq = replaceItemEq.find("*").not("iframe");
                            rePlaceCnAdKeywordByobj(replaceItemEq);
                        }
                    }
                    if (window.location.hash === "#dl") {
                        $(".info-nav").find("li").eq(0).trigger('click');
                    }

                } else {
                    var ajaxUrl_GetModelInfoByAjax = String.format('/Ajax{0}', '/Product/GetModelInfoByAjax');
                    var IsCanUseVue = BrowserIsOkayForVue();
                    
                    var ajaxModel = typeof(modelUrl) === 'undefined'
                        ? 'B550-AORUS-PRO-V2-rev-10'
                        : modelUrl;
                    $.ajax({
                        type: 'POST',
                        url: ajaxUrl_GetModelInfoByAjax,
                        data: { 'modelUrl': ajaxModel, 'contentType': contentType, 'IsCanUseVue': IsCanUseVue, isRelationProductEcExist: 'False' },
                        success: function(data) {
                            setTimeout(function() {
                                    AjaxIsRuning = false;
                                },
                                800);
                            var modelContent = $('.model-content');
                            
                            if (window.isCN) {
                                var checkCk = window.isCNAdCK.indexOf(2);
                                var productId = $('.header-title > div').first().attr('name');
                            }
                            if (typeof(cb) === "function") {
                                modelContent.html(data);
                                if ((window.outerWidth <= 960)) {
                                    $(".mobile-switchChildModel").addClass("hide");
                                }
                                $(".support-section").css("display", "block");
                                
                                if (window.isCN) {
                                    rePlaceCnAdKeywordByobj(modelContent);
                                }
                                AjaxCbFunctionExecute(cb, contentType);
                            } else {
                                AjaxNotCbFunctionExecute(modelContent, data, contentType);
                            }

                            AjaxAfterExecuteFunction(contentType);
                        }
                    });
                }

etc.

Re: gigabyte.com - content missing

Posted: 2022-01-11, 17:18
by Moonchild
Most likely the website is trying to use an ambiguous "global" event instead of the event passed into the event handler.
Simple mistake, simple fix. You'll have to contact the webmaster.