사이트 내 전체검색
게시물 쓰기에 이모티콘 항목 넣기
로빈아빠
https://cmd.kr/javascript/684 URL이 복사되었습니다.

본문

게시물 쓰기에 이모티콘 항목 넣기

571f84d4_122689011408476
게시판을 만들때 글머리에 이모티콘을 설정할 수 있게 합니다.
응용해보세요
<SCRIPT>
	function setImoticon(imoticon){
		imoticonImg.innerHTML = "<img src=\"./images/" + imoticon + ".gif\" >";
		document.inputform.icon.value = imoticon;
		imoticonDiv.style.visibility = "hidden";
	}

	function viewimoticon(){
		imoticonDiv.style.visibility = "visible";
	}
</SCRIPT>
<TABLE cellSpacing=0 cellPadding=0 width="32" border=0>
<form name=inputform>
<input type=hidden name=icon value='01'>
	<TR>
		<TD style="CURSOR: hand" onclick=viewimoticon(); width=32 background=./images/icon_select.gif><DIV id=imoticonImg name="imotiImg"><IMG src="./images/01.gif"></DIV></TD>
		<TD>
			<DIV id=imoticonDiv style="Z-INDEX: 1000; VISIBILITY: hidden; WIDTH: 220px; POSITION: absolute; HEIGHT: 40px">
				<TABLE cellSpacing=0 cellPadding=0 border=0>
					<TR>
						<TD style="PADDING-LEFT: 2px">
							<TABLE cellSpacing=1 cellPadding=0 bgColor=#dedede border=0>
								<TR bgColor=#ffffff>
									<TD style="CURSOR: hand" onclick="setImoticon('01');"><IMG src="./images/01.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('02');"><IMG src="./images/02.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('03');"><IMG src="./images/03.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('04');"><IMG src="./images/04.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('05');"><IMG src="./images/05.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('06');"><IMG src="./images/06.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('07');"><IMG src="./images/07.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('08');"><IMG src="./images/08.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('09');"><IMG src="./images/09.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('10');"><IMG src="./images/10.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('11');"><IMG src="./images/11.gif"></TD>
                                </TR>
                                <TR bgColor=#ffffff>
									<TD style="CURSOR: hand" onclick="setImoticon('12');"><IMG src="./images/12.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('13');"><IMG src="./images/13.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('14');"><IMG src="./images/14.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('15');"><IMG src="./images/15.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('16');"><IMG src="./images/16.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('17');"><IMG src="./images/17.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('18');"><IMG src="./images/18.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('19');"><IMG src="./images/19.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('20');"><IMG src="./images/20.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('21');"><IMG src="./images/21.gif"></TD>
									<TD style="CURSOR: hand" onclick="setImoticon('22');"><IMG src="./images/22.gif"></TD>
                                </TR>
							</TABLE>
						</TD>
					</TR>
				</TABLE>
			</DIV>
		</TD>
	</TR>
</form>
</TABLE>

댓글목록

납니다님의 댓글

profile_image 납니다 작성일

감사합ㄴ이다

831 (3/17P)

Search

Copyright © Cmd 명령어 18.224.59.107