PageSourceSearch

https://www.pref.yamanashi.jp/shared/system/js/recommend/recommend.js

js pref.yamanashi.jp collected 2026-09-24 08:37:31 UTC 1,292 bytes, 54 lines download raw bytes

1/**
2 * レコメンド表示用js
3 */
4// Process Ajax get data recommend
5var getRecommend = function(page_id, limit)
6{
7	jQuery.ajax({
8		url: '/cgi-bin/recommend/handle_get/get_recommend.php',
9		type: 'get',
10		data : { page_id : page_id, limit : limit },
11		dataType: 'json',
12	}).done(function (data) {
13		if (data.status == 'success' && data.results.indexOf('href') != -1) {
14			jQuery("#tmp_article_cnt").html(data.results);
15		}
16		else {
17			jQuery("#tmp_article").remove();
18		}
19	}).fail(function () {
20		jQuery("#tmp_article").remove();
21	});
22}
23
24// Process Ajax Add data recommend
25var addRecommend = function(page_id)
26{
27	jQuery.ajax({
28		url: '/cgi-bin/recommend/handle_add/add_recommend.php',
29		type: 'get',
30		data : { page_id : page_id },
31		dataType: 'json',
32	}).done(function (data) {
33		if (data.status == 'success') {
34			// Do nothing
35		}
36	}).fail(function () {
37		console.log('error')
38	});
39}
40
41jQuery.noConflict();
42(function($){
43	var NUMBER_OF_RECOMMEND = '5';
44	var ENABLE_RECOMMEND_PAGE = '1';
45	if (ENABLE_RECOMMEND_PAGE != '1') {
46		jQuery("#tmp_article").remove();
47	}
48	else {
49		var meta = $("meta[name=page_id]");
50		var page_id = meta.attr("content");
51		getRecommend(page_id, NUMBER_OF_RECOMMEND);
52		addRecommend(page_id);
53	}
54})(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.