馬斯克:SpaceX公司及其「星鏈」項目基本不使用人工智能 - 香港文匯網
→ Оригинал (без защиты от корпорастов) | Изображения из статьи: [1]
熱門搜尋: ")
$(".mobile-search-page .hot-words-block-items").append(" " + result[i] + " ")
}
}
});
$("#"+hotWordsId).on("focus","input",function(){
let hotWordId=$(this).parent().attr("id");
let value = $(this).val();
if(value == ""){
$(".hot-words-block").hide();
$("#"+hotWordId+" .hot-words-block").show();
}
});
$("#"+hotWordsId).on("blur","input",function(){
let hotWordId=$(this).parent().attr("id");
$(".hot-words-block").hide();
$(".completion-words-block").hide();
});
$("#"+hotWordsId).on("keyup","input",function(){
let hotWordId=$(this).parent().attr("id");
let value = $(this).val();
if(value==""){
$(".hot-words-block").hide();
$("#"+hotWordId+" .hot-words-block").show();
$(".completion-words-block").hide();
} else {
let completionWordsUlr="https://search2.wenweipo.com/rest/suggest?size=10&word="+ value;
$.ajax({
type:"get",
url: encodeURI(completionWordsUlr),
}).done(function(result,status,xhr){
if(result && result.length>0){
let len = result.length;
let html="";
for(let i=0; i " + result[i] + " ";
}
$("#"+hotWordsId+" .completion-words-block").html(html);
$(".hot-words-block").hide();
$(".completion-words-block").hide();
$("#"+hotWordId+" .completion-words-block").show();
} else {
}
});
}
});
$("#"+hotWordsId).on("mousedown",".hot-word-item",function(){
let hotWord = $(this).text();
if($(window).width() > 768){
$("input[name='query']").val(hotWord);
$("#"+hotWordsId).submit();
}else{
$("input[name='query']").val(hotWord);
$(".hot-words-block").hide();
$(".completion-words-block").hide();
searchStoryBut(this,2);
}
});
$("#"+hotWordsId).on("mousedown",".completion-word-item",function(){
let hotWord = $(this).text();
$("input[name='query']").val(hotWord);
$("#"+hotWordsId).submit();
});
$(".hotSearch-body").on("mousedown",".hot-word-item",function(){
let hotWord = $(this).text();
if($(window).width() > 768){
$("input[name='query']").val(hotWord);
$("#"+hotWordsId).submit();
}else{
$("input[name='query']").val(hotWord);
$(".hot-words-block").hide();
$(".completion-words-block").hide();
searchStoryBut(this,2);
}
});
}
/*]]>*/