k

자바 스크립트 질문좀 할께요

function BBTag(tag,s,text,form){
switch(tag)
{
case '[b]':
if (document.forms[form].elements[s].value=="B ")
{
document.forms[form].elements[text].value = document.forms[form].elements[text].value+"[b]";
document.forms[form].elements[s].value="B*";
}
else
{
document.forms[form].elements[text].value = document.forms[form].elements[text].value+"[/b]";
document.forms[form].elements[s].value="B ";
}
break;
}
document.forms[form].elements[text].focus();
}

</script>


<input style="font-weight: bold;" type="button" name="bold" value="B " onclick="javascript: BBTag('[b]','bold','<? echo $name; ?>','<? echo $form; ?>')" />

위에처럼 되어있는데 이걸 이미지로 바꿀려면 어떻게 해야할까요?

<img src="images/text_bold.png">

도저히 모르겠습니다 ;;
|

댓글 1개

<input style="font-weight: bold;" type="image" src="images/text_bold.png" name="bold" value="B " onclick="javascript: BBTag('[b]','bold','<? echo $name; ?>','<? echo $form; ?>')" />
댓글을 작성하시려면 로그인이 필요합니다.

자유게시판

+
제목 글쓴이 날짜 조회
17년 전 조회 2,237
17년 전 조회 1,943
17년 전 조회 1,985
17년 전 조회 1,996
17년 전 조회 2,435
17년 전 조회 2,706
17년 전 조회 2,253
17년 전 조회 2,019
17년 전 조회 2,250
17년 전 조회 2,646
17년 전 조회 1,972
17년 전 조회 2,127
17년 전 조회 2,423
17년 전 조회 1,976
17년 전 조회 2,052
17년 전 조회 1,777
17년 전 조회 1,809
17년 전 조회 1,985
17년 전 조회 1,823
17년 전 조회 1,979
17년 전 조회 2,299
17년 전 조회 2,012
17년 전 조회 2,549
17년 전 조회 1,985
17년 전 조회 1,826
17년 전 조회 2,298
17년 전 조회 2,012
17년 전 조회 1,940
17년 전 조회 1,972
17년 전 조회 2,138