클릭관련 답변 좀 부탁드립니다
본문
로그아웃 마이페이지가 위에 흰박스에 들어가야하는데 왜 ㄴㅏ오게 되어있나요?
header { display:inline;padding:10px 0 10px;background-color:#191919;text-align:right;}
header ul {
font-family: sans-serif;
font-size: 14px;
line-height: 24px;
padding: 8px 13px 7px;
color: #4d5256;
text-decoration:none;
transition: color 0.7s;
border-bottom: 1px solid gray;
padding: 0px 0;
}
header li {
display: inline;
text-transform: uppercase;
font-size: 13px;
padding: 0 10px;
letter-spacing: 4px;
}
.m02 {
float:left;
width: 100%;
height: 30px;
border:1px solid silver;
box-sizing:border-box;
background-color:white;
text-align:center;
}
.m02 a{display:inline-block;
width: 100%;
height: 30px;
}
.m03 {
float:left;
width: 50%;
height: 30px;
border:1px solid silver;
box-sizing:border-box;
background-color:white;
text-align:center;
}
.m03 a{
display:inline-block;
width: 50%;
height: 30px;
}
.m04 {
float:right;
width: 50%;
height: 30px;
border:1px solid silver;
box-sizing:border-box;
background-color:white;
text-align:center;
}
.m04 a{
display:inline-block;
width: 50%;
height: 30px;
}
<header>
<ul>
<? if(!$member['mb_id']){?>
<div class="m02">
<li><a href="./board/bbs/login.php"/>Login</li>
</div>
<?}else{?>
<div class="m03">
<li><a href="/board/bbs/logout.php">Logout</a></i>
</div>
<? if(strstr($member['mb_id'],'admin')){?>
<li><p><a href="/board/adm/">admin</a></p></li>
<?}else{?>
<div class="m04">
<li><p><a href="Mypage
</div>
<?}?>
<?}?>
</ul>
</header>
답변 3
먼저 질문하신 내용보다는 분석할 자료가 좀 더 있군요.^^
다음과 같이 해보세요.
CSS 의 header ul { 내용생략 } 다음에 아래의 내용을 추가하세요.
header ul {
~ 내용생략 ~
}
header ul:after{content:""; display:block; clear:both;} /* 이부분 추가 */
그리고,
<div class="m04">
<li><p><a href="../board/bbs/board.php?bo_table=mypage">Mypage</a></p></i>
</div>
이 부분에서 아래처럼 <p> 태그를 제거하세요.
<div class="m04">
<li><a href="../board/bbs/board.php?bo_table=mypage">Mypage</a></li>
</div>
다음으로, <li>의 닫는 태그가 </i> 이렇게만 된 곳이 몇군데 있습니다.
기왕이면 이 부분도 </li> 이렇게 수정하세요.
!-->!-->해당 사이트 주소를 알려주세요~
html 부분도 필요할거같습니다.