如何在Blogger的一个条件标签中使用2个标签

问题描述 投票:0回答:1
<b:if cond='data:blog.searchLabel == "Label"'>
<style type='text/css'>
.foa_bg {
  background-image: url(https://site.io/images/covers/image.jpg);
}
</style>
</b:if>

我很想在一行中包含2或5个标签。

conditional-statements blogger
1个回答
2
投票

您可以使用in运算符

<b:if cond='data:blog.searchLabel in ["Label1","Label2","Label3"]'>
  <style type='text/css'>
    .foa_bg {
       background-image: url(https://site.io/images/covers/image.jpg);
    }
  </style>
</b:if>
© www.soinside.com 2019 - 2024. All rights reserved.