layout.css 에서 아래처럼 if 문을 사용할 수 있을까요?
CMS/프레임워크 | Rhymix 2.0 |
---|---|
개발 언어 | PHP 7.4 |
<!--@if($_home && !$act)-->
#xet-header {
background:transparent !important;
}
<!--@end-->
해 봤는데 안되는거 같아서요.
몇년동안 웹쪽을 건드리지않았더니 깜깜하네요 ㅠ
CMS/프레임워크 | Rhymix 2.0 |
---|---|
개발 언어 | PHP 7.4 |
<!--@if($_home && !$act)-->
#xet-header {
background:transparent !important;
}
<!--@end-->
해 봤는데 안되는거 같아서요.
몇년동안 웹쪽을 건드리지않았더니 깜깜하네요 ㅠ
댓글 4
CSS에서는 템플릿 문법이 해석되지 않습니다.
그러나 #xet-header라는 태그를 선언하는 곳은 템플릿 문법이 통하는 html 파일일 테니, 거기서 어떤 조건에 따라 다른 id나 class를 사용하거나 style="background:transparent" 속성을 추가해 줄 수 있겠지요.
말씀대로 해 보겠습니다
<style>
<!--@if($_home && !$act)-->
#xet-header {
background:transparent !important;
}
<!--@end-->
</style>