웹디자인 강의 - HTML/CSS
글수 464
설라므네~
<head>
<bgsound id=music loop="1"><!-- // 몇번 들려줄지 숫자를 정해주세요.-->
<script>
function bgsoundcall(str)
{
eval(str);
}
</script>
</head>
<body>
<a OnClick="bgsoundcall('music.src='사운드.wav'');">건들면 소리지를꼬얌~ ㅜ,ㅡ</a>
P.S : onmouseover , onmouseout 우리도 할쭐안다이~ 울도 낑겨줘~~~~~~ OnClick만 싸고돌아 앙~~ ㅠ,ㅜ
>링크 클릭시 사운드 효과입니다.
>온클릭과 온마우스오버 다 가능합니다.
>
>
>
>
>
>
><style type="text/css">
><!--
>A:link {color:444444;text-decoration:none;}
>A:visited {color:444444;text-decoration:none;}
>A:active {color:444444;text-decoration:none;}
>A:hover {color:444444;text-decoration:none;}
>-->
></style>
><script LANGUAGE="JavaScript">
><!--
>var ButtonSound = new Array();
>ButtonSound[0] = "1.wav"; //사운드 파일의 경로
>ButtonSound[1] = "2.wav"; //사운드 파일의 경로
>ButtonSound[2] = "3.wav"; //사운드 파일의 경로
>document.write('<BGSOUND ID="alertsound">')
>IE = (navigator.appVersion.indexOf("MSIE")!=-1 && document.all)? 1:0;
>NS = (navigator.appName=="Netscape" && navigator.plugins["LiveAudio"])? 1:0;
>ver4 = IE||NS? 1:0;
>onload=auPreload;
>
>function auPreload() {
>if (!ver4) return;
>if (NS) auEmb = new Layer(0,window);
>else {
>Str = "<DIV ID='auEmb' STYLE='position:absolute;'></DIV>";
>document.body.insertAdjacentHTML("BeforeEnd",Str);
>}
>var Str = '';
>for (i=0;i<ButtonSound.length;i++)
>Str += "<EMBED SRC='"+ButtonSound[i]+"' AUTOSTART='FALSE' HIDDEN='TRUE'>"
>if (IE) auEmb.innerHTML = Str;
>else {
>auEmb.document.open();
>auEmb.document.write(Str);
>auEmb.document.close();
>}
>auCon = IE? document.all.alertsound:auEmb;
>auCon.control = auCtrl;
>}
>function auCtrl(whSound,play) {
>if (IE) this.src = play? ButtonSound[whSound]:'';
>else eval("this.document.embeds[whSound]." + (play? "play()":"stop()"))
>}
>function musicplay(whSound) { if (window.auCon) auCon.control(whSound,true); }
>function stopSound(whSound) { if (window.auCon) auCon.control(whSound,false); }
>//-->
></script>
>
>
>
>
>
><a href="#" onmouseover="musicplay(0)">아햏햏</a>,
>
><a href="#" onClick="musicplay(1)">스타쉬피스</a>,
>
><a href="#" onClick="musicplay(2)">뚫흙뚫흙</a>,
>
>
>
>
>
>
>
<head>
<bgsound id=music loop="1"><!-- // 몇번 들려줄지 숫자를 정해주세요.-->
<script>
function bgsoundcall(str)
{
eval(str);
}
</script>
</head>
<body>
<a OnClick="bgsoundcall('music.src='사운드.wav'');">건들면 소리지를꼬얌~ ㅜ,ㅡ</a>
P.S : onmouseover , onmouseout 우리도 할쭐안다이~ 울도 낑겨줘~~~~~~ OnClick만 싸고돌아 앙~~ ㅠ,ㅜ
>링크 클릭시 사운드 효과입니다.
>온클릭과 온마우스오버 다 가능합니다.
>
>
>
>
>
>
><style type="text/css">
><!--
>A:link {color:444444;text-decoration:none;}
>A:visited {color:444444;text-decoration:none;}
>A:active {color:444444;text-decoration:none;}
>A:hover {color:444444;text-decoration:none;}
>-->
></style>
><script LANGUAGE="JavaScript">
><!--
>var ButtonSound = new Array();
>ButtonSound[0] = "1.wav"; //사운드 파일의 경로
>ButtonSound[1] = "2.wav"; //사운드 파일의 경로
>ButtonSound[2] = "3.wav"; //사운드 파일의 경로
>document.write('<BGSOUND ID="alertsound">')
>IE = (navigator.appVersion.indexOf("MSIE")!=-1 && document.all)? 1:0;
>NS = (navigator.appName=="Netscape" && navigator.plugins["LiveAudio"])? 1:0;
>ver4 = IE||NS? 1:0;
>onload=auPreload;
>
>function auPreload() {
>if (!ver4) return;
>if (NS) auEmb = new Layer(0,window);
>else {
>Str = "<DIV ID='auEmb' STYLE='position:absolute;'></DIV>";
>document.body.insertAdjacentHTML("BeforeEnd",Str);
>}
>var Str = '';
>for (i=0;i<ButtonSound.length;i++)
>Str += "<EMBED SRC='"+ButtonSound[i]+"' AUTOSTART='FALSE' HIDDEN='TRUE'>"
>if (IE) auEmb.innerHTML = Str;
>else {
>auEmb.document.open();
>auEmb.document.write(Str);
>auEmb.document.close();
>}
>auCon = IE? document.all.alertsound:auEmb;
>auCon.control = auCtrl;
>}
>function auCtrl(whSound,play) {
>if (IE) this.src = play? ButtonSound[whSound]:'';
>else eval("this.document.embeds[whSound]." + (play? "play()":"stop()"))
>}
>function musicplay(whSound) { if (window.auCon) auCon.control(whSound,true); }
>function stopSound(whSound) { if (window.auCon) auCon.control(whSound,false); }
>//-->
></script>
>
>
>
>
>
><a href="#" onmouseover="musicplay(0)">아햏햏</a>,
>
><a href="#" onClick="musicplay(1)">스타쉬피스</a>,
>
><a href="#" onClick="musicplay(2)">뚫흙뚫흙</a>,
>
>
>
>
>
>
>



<a OnClick="bgsoundcall('music.src=\'사운드.wav\'');">건들면 소리지를꼬얌~ ㅜ,ㅡ</a>
이 구문에서.. 사운드 주소를 넣을때.. \ 사운드 어쩌구 \ 이렇게 되어있잖아요
\ 까지 포함해서 없앤후에 주소를 넣나요.. 아니면 '사운드.wav\' 만
없애구 주소를 집어넣나요 ? 주소를 정확히 어느 부분에 넣어야 할지.. -_-;;; 난감