PageSourceSearch

https://www.infotop.jp/resources/scripts/buyer/item.js?1790242526

js infotop.jp collected 2026-09-24 09:35:44 UTC 13,851 bytes, 406 lines download raw bytes

1function getRanking(ordertype,cat,ntxt)
2{
3    $.get("/buyer/item/ajax" , { id: ordertype,CATEGORY_ID_I:cat,NAME_TXT:ntxt} ,function(result){$(".panel").html(result);});
4}
5
6function goSearch(word){
7    document.search_form.NAME_TXT.value = word;
8    document.search_form.submit();
9}
10
11// KIKAN_UNNYOU-1488
12function goToRanking(element) {
13	var form = document.createElement("form");
14	form.action = "/buyer/item";
15	form.method = "post";
16	form.style.visibility = "hidden";
17	element.parentElement.appendChild(form);
18	var hidden = document.createElement("input");
19	hidden.name = "block_right_bar";
20	hidden.type = "hidden";
21	hidden.value = 1;
22	form.appendChild(hidden);
23	form.submit();
24}
25//KIKAN_UNNYOU-1488
26
27// KIKAN_UNNYOU-1489
28function goToDendo(element) {
29	var form = document.createElement("form");
30	form.action = "/";
31	form.method = "post";
32	form.style.visibility = "hidden";
33	element.parentElement.appendChild(form);
34	var hidden = document.createElement("input");
35	hidden.name = "goto_dendo";
36	hidden.type = "hidden";
37	hidden.value = 1;
38	form.appendChild(hidden);
39	form.submit();
40}
41//KIKAN_UNNYOU-1489
42
43// KIKAN_UNNYOU-1954
44function searchSort(element) {
45	var form = $('#search_form')
46	if(form.length < 1) return
47	var sortId = element.length > 0 ? $(element).val() : 0
48	location.href = '/search/sort/' + sortId // KIKAN_UNNYOU-3252
49}
50//KIKAN_UNNYOU-1954
51
52// KIKAN_UNNYOU-2320
53window.onload = function() {
54	/* ??????????? */
55	var searchForm = $("#search_form")
56	/* ??????????? */
57	var detailButton = $("#search-detail-button")
58	// ????Ã¥????????????????/?????
59	if(detailButton.length > 0) searchDetailButton(detailButton)
60	/* ?????????¤????????? */
61	var searchFormSort = $("#search-form-sort")
62	// ????Ã¥?????????/?????????
63	if(searchFormSort.length > 0) sortButton(searchFormSort)
64	/* ???????????Î¥??????????? */
65	var searchKeyword = $("#search-keyword")
66	if(searchKeyword.length > 0) {
67		// ??????????????????????
68		searchKeyword.focus()
69		// ??????????????????????????/??????????????????Î¥???????????????
70		searchKeywordFocus(searchKeyword)
71	}
72	/* ??????????????? */
73	var detailFormButton = $("#form-button")
74	if(detailFormButton.length > 0) {
75		detailFormButton.on('click', function() {
76			searchFormSubmit(searchForm, searchFormSort)
77		})
78	}
79	/* ???????Î¥??????????? */
80	var detailKeyword = $('#search_form input[name="NAME_TXT"]')
81	if(detailKeyword.length > 0 && searchKeyword.length > 0) {
82		// ??????????????????Î¥???????????????
83		detailKeyword.val(searchKeyword.val())
84		searchKeyword.on('change', function() {
85			search_clear('search_form',0)
86		    detailKeyword.val($(this).val())
87		})
88	}
89	/* ?????????????????*/
90	var closeButton = $("#close-button")
91	if(closeButton.length > 0) {
92		closeButton.on('mouseover', function() {
93			$(this).css('text-decoration', 'underline')
94		})
95		closeButton.on('mouseout', function() {
96			$(this).css('text-decoration', 'none')
97		})
98		searchDetailButton(closeButton)
99	}
100	/* ??????????????? */
101	var clearButton = $("#clear-button")
102	if(clearButton.length > 0) {
103		clearButton.on('mouseover', function() {
104			$(this).css('text-decoration', 'underline')
105		})
106		clearButton.on('mouseout', function() {
107			$(this).css('text-decoration', 'none')
108		})
109		clearButton.on('click', function() {
110			$("#search-form-category> select").val('')
111			$("#search-form-type> select").val('')
112			$("#NAME_TXT").val('')
113			$("#seller-name").val('')
114			$("#price-range-min").val('')
115			$("#price-range-max").val('')
116			$("#sort-button-order").click() /*KIKAN_UNNYOU-4537 ????????????????????????????????*/
117		})
118	}
119	/* ??????????????????? */
120	var searchBtn = $("#header_search_btn")
121	if(searchBtn.length > 0) {
122		searchBtn.css('cursor', 'pointer')
123		searchBtn.prop('disabled', false)
124	}
125}
126function searchFormSubmit(element1, element2) {
127	if(element1.length > 0 && element2.length > 0) {
128		var sort = $("<input type='hidden' name='search-sort'>")
129		sort.val(element2.data('sortSelect'))
130		sort.appendTo(element1)
131		element1.submit()
132	}
133}
134function searchDetailButton(element) {
135	if(element.length > 0) {
136		element.on('click', function() {
137			var detailForm = $("#search-detail-form")
138			if(detailForm.length > 0 && detailForm.is(':hidden') === false) {
139				detailFormHide(detailForm)
140			}
141			else {
142				detailFormShow(detailForm)
143			}
144		})
145	}
146	return
147}
148function searchKeywordFocus(element) {
149	if(element.length > 0) {
150		element.on('focus', function() {
151			var detailForm = $("#search-detail-form")
152			if(detailForm.length > 0 && detailForm.is(":hidden") === false) detailFormHide(detailForm)
153			var detailKeyword = $("#NAME_TXT")
154			if(detailKeyword.length > 0) $(this).val(detailKeyword.val())
155		})
156	}
157	return
158}
159function detailFormShow(element) {
160	var detailFace = $("#search-detail-face")
161	if(element.length > 0 && detailFace.length > 0) {
162		element.show()
163		detailFace.css('color', '#000000')
164	}
165	var detailKeyword = $("#NAME_TXT")
166	if(detailKeyword.length > 0) detailKeyword.focus()
167	return
168}
169function detailFormHide(element) {
170	var detailFace = $("#search-detail-face")
171	if(element.length > 0 && detailFace.length > 0) {
172		element.hide()
173		detailFace.css('color', '#666666')
174	}
175	var searchKeyword = $("#search-keyword")
176	if(searchKeyword.length > 0 && searchKeyword.is(":focus") === false) searchKeyword.focus()
177	return
178}
179function sortButton(element) {
180	if(element.length < 1) return
181	element.children().map(function() {
182		if(element.data('sortSelect') == $(this).data('sortValue')) $(this).addClass('search-sort-selected')
183		$(this).on('click', function() {
184			$(this).addClass('search-sort-selected')
185			$(this).siblings().removeClass('search-sort-selected')
186			element.data('sortSelect', $(this).data('sortValue'))
187		})
188	})
189	return
190}
191//KIKAN_UNNYOU-2320
192
193// KIKAN_UNNYOU-2320
194function setKeyword(keyword) {
195	search_clear('search_form',0);
196    $("#search_form input[name=NAME_TXT]").val(keyword);
197    $("#search_form input[name=ad_top_header_keyword]").val(1);
198    $("#search_form").submit();
199}
200//KIKAN_UNNYOU-2320
201
202//KIKAN_UNNYOU-2324
203$(document).ready(function() {
204  CategoryExtention._init_top()
205  CategoryExtention._event_top()
206  CategoryExtention._init_page()
207  CategoryExtention._event_page()
208})
209var CategoryExtention = {
210  CATEGORY_ID_DL : '80',
211  CATEGORY_ID_ES : '81',
212  SALE_ID_DL : '1',
213  SALE_ID_ES : '2',
214  Category : '',
215  Type : '',
216  _init_top : function() {
217      var category = $("#search_form select[name=CATEGORY_ID_I]")
218      if(category.length < 1) return
219      this.Category = category
220      var categoryId = category.val()
221      var type = $("#search_form select[name=SALE_ID_I]")
222      if(type.length < 1) return
223      this.Type = type
224      var typeOption = type.children('option')
225      if(typeOption.length < 1) return
226      var hidden = $("#search_form input[name=SALE_ID_I]")
227      if(hidden.length < 1) hidden = $("<input>").attr({'type' : 'hidden', 'name' : 'SALE_ID_I'})
228      this.operate(categoryId, type, typeOption, hidden)
229  },
230  _init_page : function() {
231	  var category = $("#search_item_form select[name=CATEGORY_ID_I]")
232	  if(category.length < 1) return
233	  this.Category = category
234	  var categoryId = category.val()
235	  var type = $("#search_item_form select[name=SALE_ID_I]")
236	  if(type.length < 1) return
237	  this.Type = type
238	  var typeOption = type.children('option')
239	  if(typeOption.length < 1) return
240	  var hidden = $("#search_item_form input[name=SALE_ID_I]")
241	  if(hidden.length < 1) hidden = $("<input>").attr({'type' : 'hidden', 'name' : 'SALE_ID_I'})
242	  this.operate(categoryId, type, typeOption, hidden)
243  },
244  _event_top : function() {
245	  if(this.Category.length < 1 || this.Type.length < 1) return
246      this.Category.on("change", function() {
247    	  CategoryExtention._init_top()
248      })
249  },
250  _event_page : function() {
251	  if(this.Category.length < 1 || this.Type.length < 1) return
252	  this.Category.on("change", function() {
253		  CategoryExtention._init_page()
254	  })
255  },
256  operate : function(categoryId, type, typeOption, hidden) {
257      switch(categoryId) {
258          case this.CATEGORY_ID_DL :
259              this.lock(this.SALE_ID_DL, type, typeOption, hidden)
260              break
261          case this.CATEGORY_ID_ES :
262              this.lock(this.SALE_ID_ES, type, typeOption, hidden)
263              break
264          default :
265              this.unlock(type, typeOption, hidden)
266              break
267      }
268  },
269  lock : function(saleId, type, typeOption, hidden) {
270      typeOption.each(function() {
271          var value = $(this).val()
272          if(value == saleId) {
273              type.val(value)
274              hidden.val(value).appendTo(type.parents('form'))
275              $(this).prop('disabled', false)
276          }
277          else {
278              $(this).prop('disabled', true)
279          }
280      })
281      type.prop('disabled', true)
282  },
283  unlock : function(type, typeOption, hidden) {
284      type.prop('disabled', false)
285      typeOption.each(function() {
286          $(this).prop('disabled', false)
287      })
288      hidden.remove()
289  }
290}
291//KIKAN_UNNYOU-2324
292
293// INFOTOP_DESIGN_RENEWAL-48 【P4】検索結果一覧ページ(先行PC版ポータルリニューアル)
294// 検索窓が2個同じものがあるため、商品区分のjqueryが動く前にもう一つの窓にも同じ値をセットする
295function categoryChange(v){
296	$("select[name=CATEGORY_ID_I]").val(v);
297}
298
299
300// KIKAN_UNNYOU-2625
301$(document).ready(function() {
302    if(TopMainBannerSlide.List.length > 0) return
303    TopMainBannerSlide._init()
304    TopMainBannerSlide._exec()
305})
306var TopMainBannerSlide = {
307    SLIDE_SPEED : 500,
308    DELAY_LOOP : 5000,
309    List : '',
310    _init : function() {
311        var list = $("ul#TopMainBannerList")
312        if(list.length < 1) return
313        var children = list.children('li')
314        if(children.length < 1) return
315        list.height(children.first().height())
316        if(children.length === 1) return
317        this.List = list
318        var width = this.width(children)
319        if(width < 1) return
320        this.set(width)
321    },
322    _exec : function() {
323        if(this.List.length < 1) return
324        setTimeout('TopMainBannerSlide.slide()', this.DELAY_LOOP)
325    },
326    width : function(element) {
327        if(element.length <= 1) return 0
328        var value = 0
329        element.each(function() {
330            value += $(this).width()
331        })
332        return value
333    },
334    set : function(value) {
335        if(value < 1 || this.List.length < 1) return
336        this.List.width(value)
337        return
338    },
339    slide : function() {
340        if(this.List.length < 1) return
341        this.List
342            .animate({'marginLeft' : (-1 * this.List.children().first().width()) + 'px'}, this.SLIDE_SPEED)
343            .queue(function() {
344                $(this).dequeue()
345            })
346            .animate({'marginLeft' : '0px'}, 0)
347            .queue(function() {
348                $(this).append($(this).children().first()).dequeue()
349                setTimeout('TopMainBannerSlide.slide()', TopMainBannerSlide.DELAY_LOOP)
350            })
351    }
352}
353// KIKAN_UNNYOU-2625
354
355//KIKAN_UNNYOU-3618 ???????????????Ρ??????????β???????
356function openPubInfo(url) {
357	var w = 680;
358	var h = 250;
359	window.open(url, 'trade', 'width=' +w +', height=' +h +', left=' + Number((window.screen.width-w)/2) +', top=' 
359+ Number((window.screen.height-h)/2) + ', menubar=no, toolbar=no, scrollbars=no, resizable=no');
360}
361
362
363function search_clear(form_name,keyword_clear_flg){
364    if(keyword_clear_flg){
365      $('#'+form_name+' input:text[name="search-keyword"]').attr('value','');
366    }
367    search_clear_detail(form_name);
368 }
369  
370  /**
371   * �����ξ�說�ꥢ�򲡤����Ȥ�
372   * �����ͤ򥯥ꥢ����
373   * @returns
374   */
375function search_clear_detail(form_name){
376	$('#'+form_name+' select[name="CATEGORY_ID_I"] option').attr('selected',false);
377	$('#'+form_name+' select[name="CATEGORY_ID_I"]').val('');
378	$('#'+form_name+' select[name="SALE_ID_I"] option').attr('selected',false);
379	$('#'+form_name+' select[name="SALE_ID_I"]').attr('disabled',false);
380	$('#'+form_name+' select[name="SALE_ID_I"] option').attr('disabled',false);
381	$('#'+form_name+' select[name="SALE_ID_I"]').val('');
382	$('#'+form_name+' input[name="SALE_ID_I"]').attr('value','');
383	$('#'+form_name+' input[name="NAME_TXT"]').attr('value','');
384	$('#'+form_name+' input[name="seller-name"]').attr('value','');
385	$('#'+form_name+' input[name="price-range-min"]').attr('value','');
386	$('#'+form_name+' input[name="price-range-max"]').attr('value','');
387	// ����Υ���������᤹
388	$('#'+form_name+' input[name="credit_check"]').attr('checked',false);
389	$('#'+form_name+' input[name="credit_check"]').parent().removeClass('is-active');
390	$('#'+form_name+' input[name="credit_split_check"]').attr('checked',false);
391	$('#'+form_name+' input[name="credit_split_check"]').parent().removeClass('is-active');
392	$('#'+form_name+' input[name="revo_check"]').attr('checked',false);
393	$('#'+form_name+' input[name="revo_check"]').parent().removeClass('is-active');
394	$('#'+form_name+' input[name="bank_check"]').attr('checked',false);
395	$('#'+form_name+' input[name="bank_check"]').parent().removeClass('is-active');
396	$('#'+form_name+' input[name="bank_split_check"]').attr('checked',false);
397	$('#'+form_name+' input[name="bank_split_check"]').parent().removeClass('is-active');
398	$('#'+form_name+' input[name="cvs_check"]').attr('checked',false);
399	$('#'+form_name+' input[name="cvs_check"]').parent().removeClass('is-active');
400	$('#'+form_name+' input[name="delivery_check"]').attr('checked',false);
401	$('#'+form_name+' input[name="delivery_check"]').parent().removeClass('is-active');
402	$('#'+form_name+' input[name="emoney_check"]').attr('checked',false);
403	$('#'+form_name+' input[name="emoney_check"]').parent().removeClass('is-active');
404	$('#'+form_name+' input[name="bitcash_check"]').attr('checked',false);
405	$('#'+form_name+' input[name="bitcash_check"]').parent().removeClass('is-active');
406}

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.