Showing
2 changed files
with
9 additions
and
7 deletions
@@ -142,7 +142,7 @@ function actionGoodsCart() { | @@ -142,7 +142,7 @@ function actionGoodsCart() { | ||
142 | return false; | 142 | return false; |
143 | } | 143 | } |
144 | key = encodeURI(key); | 144 | key = encodeURI(key); |
145 | - $.get(searchDomain + '?callback=?&query=' + key, function(htmlData) { | 145 | + $.get(searchDomain + '?query=' + key, function(htmlData) { |
146 | $('.search-list').html(htmlData.data); | 146 | $('.search-list').html(htmlData.data); |
147 | queryNum = $('.search-list').children('li').length; | 147 | queryNum = $('.search-list').children('li').length; |
148 | listIndex = -1; | 148 | listIndex = -1; |
@@ -156,7 +156,7 @@ function actionGoodsCart() { | @@ -156,7 +156,7 @@ function actionGoodsCart() { | ||
156 | }, function() { | 156 | }, function() { |
157 | $(this).css('background-color', '#fff'); | 157 | $(this).css('background-color', '#fff'); |
158 | }); | 158 | }); |
159 | - }, 'jsonp'); | 159 | + }, 'json'); |
160 | } | 160 | } |
161 | 161 | ||
162 | function getText(obj) { | 162 | function getText(obj) { |
@@ -525,7 +525,7 @@ function createNewArray(obj) { | @@ -525,7 +525,7 @@ function createNewArray(obj) { | ||
525 | var $that = $(this); | 525 | var $that = $(this); |
526 | var $alink = $that.find('a'); | 526 | var $alink = $that.find('a'); |
527 | var _href = $alink.attr('href'); | 527 | var _href = $alink.attr('href'); |
528 | - var hottag = $alink.attr('hot') === 'true' ? true : false; | 528 | + var hottag = $alink.attr('hot') === 'hot' ? true : false; |
529 | var objt = {}; | 529 | var objt = {}; |
530 | 530 | ||
531 | if ($that.hasClass('category-title')) { | 531 | if ($that.hasClass('category-title')) { |
@@ -721,7 +721,6 @@ function actionNav() { | @@ -721,7 +721,6 @@ function actionNav() { | ||
721 | } | 721 | } |
722 | 722 | ||
723 | 723 | ||
724 | - | ||
725 | /** | 724 | /** |
726 | * 查询跳转后保留关键字 | 725 | * 查询跳转后保留关键字 |
727 | * @return {[type]} [description] | 726 | * @return {[type]} [description] |
@@ -1172,7 +1171,7 @@ function actionExeTemplate() { | @@ -1172,7 +1171,7 @@ function actionExeTemplate() { | ||
1172 | * @return {[type]} [description] | 1171 | * @return {[type]} [description] |
1173 | */ | 1172 | */ |
1174 | function actionSearch() { | 1173 | function actionSearch() { |
1175 | - var searchDomain = 'http://search.yohobuy.com/api/suggest'; | 1174 | + var searchDomain = 'http://search.yohobuy.com/product/search/suggest'; |
1176 | 1175 | ||
1177 | $('#query_key').search(searchDomain); | 1176 | $('#query_key').search(searchDomain); |
1178 | } | 1177 | } |
@@ -14,9 +14,11 @@ var $cr = $('#country-code-hide'), | @@ -14,9 +14,11 @@ var $cr = $('#country-code-hide'), | ||
14 | emailReg = /^[.\-_a-zA-Z0-9]+@[\-_a-zA-Z0-9]+\.[a-zA-Z0-9]/, | 14 | emailReg = /^[.\-_a-zA-Z0-9]+@[\-_a-zA-Z0-9]+\.[a-zA-Z0-9]/, |
15 | acAccount = [ | 15 | acAccount = [ |
16 | ['qq.com', '163.com', '126.com', 'sina.com', 'gmail.com', | 16 | ['qq.com', '163.com', '126.com', 'sina.com', 'gmail.com', |
17 | - 'sohu.com', 'hotmail.com', '139.com', '189.com'], //数字顺序 | 17 | + 'sohu.com', 'hotmail.com', '139.com', '189.com' |
18 | + ], //数字顺序 | ||
18 | ['gmail.com', 'qq.com', '163.com', '126.com', 'sina.com', | 19 | ['gmail.com', 'qq.com', '163.com', '126.com', 'sina.com', |
19 | - 'sohu.com', 'hotmail.com', '139.com', '189.com'] //组合顺序 | 20 | + 'sohu.com', 'hotmail.com', '139.com', '189.com' |
21 | + ] //组合顺序 | ||
20 | ], | 22 | ], |
21 | $ccList = $('#country-code-list'), | 23 | $ccList = $('#country-code-list'), |
22 | $cc = $('#country-code'), | 24 | $cc = $('#country-code'), |
@@ -44,6 +46,7 @@ function imgcode() { | @@ -44,6 +46,7 @@ function imgcode() { | ||
44 | var time = new Date(), | 46 | var time = new Date(), |
45 | $captchaImg = $('#captcha-img'), | 47 | $captchaImg = $('#captcha-img'), |
46 | captchaImgSrc = $captchaImg.attr('src').split('?')[0]; | 48 | captchaImgSrc = $captchaImg.attr('src').split('?')[0]; |
49 | + | ||
47 | $('#captcha-img').attr('src', captchaImgSrc + '?t=' + time.getTime()); | 50 | $('#captcha-img').attr('src', captchaImgSrc + '?t=' + time.getTime()); |
48 | 51 | ||
49 | //getSource('yoho_family_web', '换一张', 'homepage_man'); | 52 | //getSource('yoho_family_web', '换一张', 'homepage_man'); |
-
Please register or login to post a comment