From 68ff0bcdc651649afbdab5358eb929ddd3eac0b2 Mon Sep 17 00:00:00 2001 From: chenxiaojun <956334972@qq.com> Date: Fri, 13 Dec 2019 20:44:29 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A8=E5=B9=BF=E5=B9=B3=E5=8F=B0>=E6=88=91?= =?UTF-8?q?=E7=9A=84=E6=B8=B8=E6=88=8F--=E6=9B=B4=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Application/Home/View/default/Apply/my_game.html | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Application/Home/View/default/Apply/my_game.html b/Application/Home/View/default/Apply/my_game.html index 094ca87ec..a709f5dd2 100644 --- a/Application/Home/View/default/Apply/my_game.html +++ b/Application/Home/View/default/Apply/my_game.html @@ -879,6 +879,7 @@ var logo = null; var logoSrc = $(linkTag).parents('.game-li').eq(0).find('.img-box').children('img').attr('src'); + console.log(isImg(logoSrc)); if (isImg(logoSrc)) { logo = $(linkTag).parents('.game-li').eq(0).find('.img-box').children('img')[0] } else { @@ -909,10 +910,8 @@ function isImg(src) { var img = new Image(); img.src = src; - img.onload = function () { - if (img.width > 0 || img.height > 0) { - return true; - } + if (img.width > 0 || img.height > 0) { + return true; } return false; }