# Code examples

The two most common ways to filter the news feed is with buttons or by a dropdown select. Here are two simple examples using our query parameters:

```
// Buttons
<button class="et_pb_button" onclick="window.location.href='/'" style="font-size: 18px; border: none; color: #FFFFFF; background-color: #fba41b; border-radius: 8px; cursor: pointer; padding-bottom: 6px; padding-top: 6px;">All</button>
<button class="et_pb_button" onclick="window.location.href='?m-tags=regulatory'" style="font-size: 18px; border: none; color: #FFFFFF; background-color: #fba41b; border-radius: 8px; cursor: pointer; padding-bottom: 6px; padding-top: 6px;">Regulatory</button>
<button class="et_pb_button" onclick="window.location.href='?m-tags=-regulatory'" style="font-size: 18px; border: none; color: #FFFFFF; background-color: #fba41b; border-radius: 8px; cursor: pointer; padding-bottom: 6px; padding-top: 6px;">Non-Regulatory</button>
```

```
// Dropdown
<script>
function openUrl(event) {
    window.location.href = event.target.value;
}
</script>

<form style="display: inline-flex; flex-direction: column;" onchange="openUrl(event)">
<label for="category" style="font-size: 18px">Choose category</label>
<select name="kategori" id="kategori" style="margin: 15px 0 0 0; width: 250px; background-color: #f5f8fa; border-radius: 4px; height: 40px;" class="hs-input is-placeholder">
  <option value="/">All</option>
  <option value="?m-tags=regulatory">Regulatory</option>
  <option value="?m-tags=-regulatory">Non-Regulatory</option>
</select>
```
