Javascript & Searchable/Filtered tables | The place for Zendesk users to come together and share
Skip to main content
September 14, 2026
Question

Javascript & Searchable/Filtered tables

Hello, 

I used to use Zendesk a few years ago with a previous company where Zendesk allowed a searchable table/filtered table built within an article.

When i used it previously it allowed java script in the source code but its been just over a year since i last used this platform and alot has changed with it. 

Can someone help? Is there a way to insert a searchable table at article level? rather than relying on users to use CTRL + F. 

Java script code appears to be fine but no luck in implementing it. If someone has figured this out can they share the code they used? 

Thanks

 

3 replies

Samer13
Community Expert
September 16, 2026

Hello Joe,

Yes, this is still possible.

The approach I’d recommend is to keep the table itself inside the article, but move the JavaScript logic into your Help Center theme instead of adding <script> directly to the article.

For example, add a class to the table in the article source:

<table class="searchable-table">
...
</table>

Then add something like this to your theme's script.js:

document.addEventListener('DOMContentLoaded', function () {
document.querySelectorAll('.searchable-table').forEach(function (table) {
const tbody = table.tBodies[0];
if (!tbody) return;

const search = document.createElement('input');
search.type = 'search';
search.placeholder = 'Search table...';
search.className = 'table-search';

table.parentNode.insertBefore(search, table);

search.addEventListener('input', function () {
const query = search.value.toLowerCase();

Array.from(tbody.rows).forEach(function (row) {
row.hidden = !row.textContent.toLowerCase().includes(query);
});
});
});
});

You can then style the search field in style.css if needed.

This way, you don't need to rely on JavaScript embedded directly inside the article. Any table with the searchable-table class will automatically get its own search field.

Just keep in mind that you need access to edit the Help Center theme code for this approach.

Translate
Zendesk Expert | Custom Apps & Integrations | CRM & CX | atlantis dx GmbH
September 22, 2026

Thank you for resolving my query. 

Translate
Samer13
Community Expert
September 22, 2026

Happy to help.

Translate
Zendesk Expert | Custom Apps & Integrations | CRM & CX | atlantis dx GmbH