0

I want to change the HTML output for exposed filters of given view, on fresh new installation of Drupal 8 (no modules were added to it).

I tried to override views-ui-expose-filter-form.html.twig inside my theme's /templates folder, but it doesn't replace the default implementation. The theme itself works fine; for example, I can override the front page.

The file's description is here: https://api.drupal.org/api/drupal/core%21modules%21views_ui%21templates%21views-ui-expose-filter-form.html.twig/8.2.x.

What am I doing incorrectly? Should I override another template file, or turn something on in the system for it to work, or the filename is wrong?

6
  • Is this the correct filename you should be using?
    – Kevin
    Dec 11 '17 at 1:22
  • I think so, according to the Drupal documentation on API page (correct me if I'm wrong): api.drupal.org/api/drupal/…
    – PolGraphic
    Dec 11 '17 at 2:12
  • @Darvanen How it's a duplicate of post asking on different topic? I don't want to make a hook and I don't want to override default view template, but default expose filter for template (that's huge difference, I know perfectly how to override default view template).
    – PolGraphic
    Dec 11 '17 at 3:25
  • 2
    @PolGraphic, I think you are looking for views-exposed-form.html.twig, this is the output of exposed filters. The other template is from the Views UI, for the form to configure the exposed filter, which you would have to override in the admin theme.
    – 4k4
    Dec 11 '17 at 7:33

This site is temporarily in read only mode and not accepting new answers.

Browse other questions tagged .