메뉴가 정상작동하지 않습니다.
본문
드림위버에서 메뉴바를 만들었습니다.
마우스 오버시 이미지가 바뀌는 메뉴바 인데요
이게 그누보드에 헤드파일로 만들어서 적용시에 문제점이 발생했습니다.
그누에서 기능상 꼭불러와야 하는부분
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
include_once("$g4[path]/head.sub.php");
include_once("$g4[path]/lib/outlogin.lib.php");
include_once("popup_source.php");
?>
이부분들을 헤드파일에서 인클루드 시키면 메뉴가 작동하지 않습니다.
증상은 마우스 오버시 다른이미지로 교체가 안되네요 클릭시 메뉴이동은 정상작동하는것 같습니다.
그리고 이부분을 지워주면 정상작동하구요ㅠㅠ
dtd선언은 드림위버에서 기본으로 작성하는거 같은데 저부분 지워주고 해도 증상은 같네요
어떤문제로 이러한 증상이 알려주는지 어딜어떻게 고쳐야 하는지 알려주시면 감사하겠습니다.
(^.^) (_._)
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
include_once("$g4[path]/head.sub.php");
include_once("$g4[path]/lib/outlogin.lib.php");
include_once("popup_source.php");
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>home</title>
<script type="text/javascript">
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
</script>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.0.min.js"></script>
<script language="javascript" src="js/rolling.js"></script>
<script>
$(document).ready(function() {
$('.rolling_wrap').rolling({
arrowBtn:true,
rollingBtn:true,
main:true,
timer:3000
});
});
</script>
<style>
*{margin:0;padding:0}
ul,li{list-style:none}
.rolling_wrap{width:975px;height:403px}
</style>
</head>
<body><body onload="mm_preloadimages('img/top_r_1.jpg','img/top_r_2.jpg','img/top_r_3.jpg','img/top_r_4.jpg','img/top_r_5.jpg')">
<table width="976" border="0" align="center" cellpadding="0" cellspacing="0">
<tr></tr>
<tr>
<td width="262" height="126"><img src="<?=$g4['path']?>/img/logo10.jpg" width="262" height="126" usemap="#map" border="0" /></td>
<td width="166" height="126"><a href="#" onmouseout="mm_swapimgrestore()" onmouseover="mm_swapimage('image2','','img/top_r_1.jpg',1)"><img src="<?=$g4['path']?>/img/top_1.jpg" width="166" height="126" id="image2" border="0" /></a></td>
<td width="140" height="126"><a href="#" onmouseout="mm_swapimgrestore()" onmouseover="mm_swapimage('image3','','img/top_r_2.jpg',1)"><img src="<?=$g4['path']?>/img/top_2.jpg" width="140" height="126" id="image3" border="0" /></a></td>
<td width="104" height="126"><a href="#" onmouseout="mm_swapimgrestore()" onmouseover="mm_swapimage('image4','','img/top_r_3.jpg',1)"><img src="<?=$g4['path']?>/img/top_3.jpg" width="104" height="126" id="image4" border="0" /></a></td>
<td width="112" height="126"><a href="#" onmouseout="mm_swapimgrestore()" onmouseover="mm_swapimage('image5','','img/top_r_4.jpg',1)"><img src="<?=$g4['path']?>/img/top_4.jpg" width="112" height="126" id="image5" border="0" /></a></td>
<td width="192" height="126"><a href="#" target="_self" onmouseover="mm_swapimage('image6','','img/top_r_5.jpg',1)" onmouseout="mm_swapimgrestore()"><img src="<?=$g4['path']?>/img/top_5.jpg" width="192" height="126" id="image6" border="0" /></a></td>
</tr>
</table>
<map name="map" id="map">
<area shape="rect" coords="3,4,258,123" href="index10.php" target="_self" />
</map>
답변 1
원인일지 모르지만..
일단 <script type="text/javascript" src=""></script> 가 중복으로 선언되었을 것 같은데요..
url을 알려주시는게 더 좋을 듯 하네요..