我正在尝试定位what
和where
以及search
。
这是我的html:
<div class="entry-content">
<p> </p>
<div class="entry-content">
<div class="job_listings" data-location="" data-keywords="" data-show_filters="true" data-show_pagination="false" data-per_page="10" data-orderby="featured" data-order="DESC" data-categories="">
<form class="job_filters">
<div class="search_jobs">
<div class="search_keywords">
<label for="search_keywords">What?</label><br />
<input id="search_keywords" name="search_keywords" type="text" value="" placeholder="Chef, Cleaner, Manager" />
</div>
<div class="search_location">
<label for="search_location">Where?</label><br />
<input id="search_location" name="search_location" type="text" value="" placeholder="London, Berlin, Bristol" />
<input name="filter_job_type[]" type="submit" value="search" />
</div>
</div>
<div class="showing_jobs"></div>
<div></div>
<div>
<a href="https://adsler.co.uk/post-a-job/">Post A Job</a>
</div>
</form>
</div>
</div>
<p><a class="load_more_jobs" style="display: none;" href="#"><strong>Load more listings</strong></a></p>
</div>
尝试了一切,包括。
.entry-content {color: green;}
有趣的是
. entry-content {background-color: green;}
可行,但是
.entry-content {color: green! important;}
什么也没做。
最佳答案
您可以使用以下样式定位entry-content
中的所有标签。除非该样式未被其他样式覆盖,否则此方法有效
.entry-content label{
color:green;
}
对于特定的标签,您可以使用,
.search_keywords label{
color:green;
}
.search_location label{
color:green;
}
更新
对于
chef,manager
等输入字段,您可以使用.search_keywords input{
//Your style here
}
或者由于您具有输入字段的ID,请使用
#search_keywords{
//Style here
}
对于提交按钮
search
,您可以使用以下命令,.search_location input[type=submit]{
//style here
}