Hi,

I have created one page view and one block view. Both views have filter criteria. How can I give different class names to the views filters?

Thanks,
D

Comments

webdev100’s picture

In Views.css file, i have this:

.views-exposed-widgets {
  width: 150px;
  }

I simply have two different views. Views names are VA and NJ. I like to give two different width to both views. Not sure how i can do it. Below did not work.

.views-exposed-widgets .NJ{
    width: 150px;
}

.views-exposed-widgets .VA{
    width: 200px;
}
cmsMinds’s picture

Hi,

Method:1

For add HTML tags in your views You have to create template files.

For create Exposed Filter template:
1.Copy the views-exposed-form.tpl.php which is located at /sites/all/modules/views/theme to your own theme folder.
2.renamed the views-exposed-form.tpl.php to views-exposed-form--VIEW-NAME.tpl.php and modify it with whatever u like.
3. Go to the Views admin UI and click the Rescan template files button in Theming information.

OR

Method:2

Using Jquery.

Thanks