switch views or hide block based on content type I have a block view that gets its contents based on a contextual filter. I only want to use this filter if it's a certain node type being displayed ie. the block would use the contextual filter on basic pages but on article and other pages I would like to set the contextual filter to a default value.

One way I thought I might do this is to change the views display based on the node type and then override the settings in the second display. Is this possible? 

I created my second display for the view and I added both blocks to the same region. One of them I set to only display on basic pages. The other one I would like to set to only not display on basic pages. The block system only lets me select which content types to show the block on not which content types to exclude it from. I don't want to keep coming back to this page and having to check more boxes as I add new content types.

Is there any way to exclude a block from being shown on a certain content type?
It's possible with views:

#1 Configure field with images:



#2 Add contextual filter:




#3 Save the contextual settings and then add "No result behavior':



#4 You just need to display a default image in case the other content type than basic page, so you can apply the Unfiltered text, and type the html source of the image:



That's it!