JSFiddle - React, Tailwind, and code Playground

HTML

<form action=''>
    <select onchange='printCat(this.options[this.selectedIndex].value)'>
        <option value='all'>All</option>
        <option value='search'>Search</option>
        <option value='social_media'>Social Media</option>
    </select>
</form>
<ul id="websites">
    <li>websites added here</li>
</ul>

JavaScript

var x = ['http://website1','http://website2','http://website3'];

//This is the part that handles printing the items under the various categories.
function printCat(cat){
    for (i=0;i<x.length;i++){
        // Pure JS            
        //document.write(x[i]+ "<br/>");
        
        // jQuery
        $('ul#websites').append('<li>' + x[i] + '</li>');
    }
}
// more