document.getElementById("searchbar").addEventListener("submit", function(event) {
const stopWords = ["a", "an", "the", "of", "and", "in", "for", "to"];
let searchQuery = document.getElementById("search-input").value;
// Split the search query into words and filter out stop words
let filteredQuery = searchQuery.split(" ").filter(word => !stopWords.includes(word.toLowerCase())).join(" ");
// Update the input value with the cleaned query
document.getElementById("search-input").value = filteredQuery;
});