Hi. I’m trying to make a dynamic search for FreeCodeCamp project but I’m getting error 400
, status no client id is specified
with every search input. I have client id, other stuff works just fine.
I want it to search streams which stream searched game and show it’s preview image, but I’m kinda stuck on that.
I will really appreciate any help!
CodePen with my project : https://codepen.io/dknvmlhok/full/eyzgVm
$.getJSON(apiBaseUrl+"search/streams?query="+searchVal
+"?client_id=aj6k9bb6snp76o59babzqeobxbbcgs",function(data3){
//console.log(data3);
//for(let j = 0; j < data3.length; j++){
let previewImgUrl = data3.preview.template;
let resizedPreviewImg = previewImgUrl.replace("{width}x{height}","175x100");
//console.log(resizedPreviewImg);
$(".liveStr-results").append('<img src="'+resizedPreviewImg+'">');
//};
});