Customize data-filter-placeholder

Customize data-filter-placeholder

Can the attribute data-filter-placeholder be customized? I've been wanting to have that change based on a filter that is selected.

So placeholder defaults to "search", but if they select Location from the filter list, I'd like it to change to "Search Location". I tried something like below but, obviously, it's a greasefire. Has anyone ever attempted this?

Thanks,
Shadraq

  1.  $("#filterButton").click(function () {
  2.         $("#searchResults").change(function(){
  3.             $(this).data-filter-placeholder("Search Location");
  4.             });
  5.     });