Are spaces necessary in CSS?

I was asked to take over a company’s website built using a builder I’m not familiar with.
I need to remove a few buttons, tabs, etc. (The site needs to be rebuilt.) Until we get the green light I’m having to remove items here and there with CSS.

I was able to remove the following button

<a href="#" class="search-btns" data-search="rental">"Rental"</a>

with the following:

a.search-btns[data-search=rental] {
display: none;}

But I trying to remove this tab

<li class="tab"> <a href="#rental" data-tabtitle="Rental Equipment">Rental</a></li>

does not work using this method.

a.tab[data-tabtitle=Rental Equipment] {
display: none;}

I know just enough about CSS to be dangerous. Can someone help with this?

Thanks in advance!

>Solution :

Change css code to:

li.tab a[data-tabtitle="Rental Equipment"] 
{
  display: none;
}

Leave a Reply