이 스킨에 마우스오버시 이미지체인지 기능을 넣을수 있을까요? > 그누4 질문답변

그누4 질문답변

그누보드4 관련 질문은 QA 로 이전됩니다. QA 그누보드4 바로가기
기존 게시물은 열람만 가능합니다.

이 스킨에 마우스오버시 이미지체인지 기능을 넣을수 있을까요? 정보

이 스킨에 마우스오버시 이미지체인지 기능을 넣을수 있을까요?

본문

오류가 나는곳의 주소를 알려주시면 더 빠르고 정확하게 답변 받을 수 있습니다.

오류 주소 :

안녕하세요! 다름이 아니라.. 스킨자료실에서 받은 커버스토리 최신글의 기능을 짬뽕시키고

싶은데 도저히 어떻게 할지를 모르겠습니다.. 혹시라도 도움주실수 있는분이 계시다면

가르침 부탁좀 드리겠습니다..(__)꾸벅~

현재 사용하는 스킨은 '닭대가리'님의 커버스토리 최신글 스킨입니다.
이 스킨은 아래 블레스님의 최신글 스킨에서 일반 게시판에서도 사용할 수있게끔
수정하신건데요.. 일정 시간이 지났을 때 오버랩 이미지 교체가 이루어지고,
각 번호별로 마우스 오버를 했을 때, 해당 커버스토리로 이미지가 바뀌던게
요 스킨에서는 작동이 되지 않네요..; 어느부분을 손보면 아래 블레스님 최신글처럼
요 스킨에 마우스오버시 이미지 체인지가 가능하도록 할 수 있을런지요..?;;
(질문이 좀 정리가 안됩니다. 죄송합니다^^;)
http://sir.co.kr/bbs/board.php?bo_table=g4_skin&wr_id=61135&sca=&sfl=wr_subject&stx=%C4%BF%B9%F6%BD%BA%C5%E4%B8%AE&sop=and


짬뽕하고 싶은 스킨은 블레스님의 커버스토리 게시판/최신글 스킨입니다.
http://sir.co.kr/bbs/board.php?bo_table=g4_skin&wr_id=58985&sca=&sfl=wr_subject&stx=%C4%BF%B9%F6%BD%BA%C5%E4%B8%AE&sop=and


기능추가 하고싶은 스킨의 소스입니다.
-----------------------------------------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가

$overlap_speed = "6000";
$blink_speed = "1200";

$swf_width = "519"; // 플래시 파일을 업로드시 수동으로 싸이즈 입력 = 넓이
$swf_height = "139"; // 플래시 파일을 업로드시 수동으로 싸이즈 입력 = 높이

?>

<script language="JavaScript">
<!-- 
function doBlink() {
var blink = document.all.tags("BLINK")
for (var i=0; i < blink.length; i++)
blink[i].style.visibility = blink[i].style.visibility == "" ? "hidden" : ""
}
function startBlink() {
if (document.all)
setInterval("doBlink()",<?=$blink_speed?>)
}
window.onload = startBlink;
-->
</script>

<SCRIPT type=text/javascript>
<!--
old_debate='1';
function Comeon(objid){
document.getElementById("debate"+old_debate).style.display="none";
document.getElementById("debate"+old_debate+"#1").style.display="";
document.getElementById("debate"+objid+"#1").style.display="none";
document.getElementById("debate"+objid).style.display="";
document.getElementById("debate_content"+old_debate).style.display="none";
document.getElementById("debate_content"+objid).style.display="";
old_debate=objid;
}
var objid = 1;
var interval_best;

function best_change()
{
 if( objid == <?=$rows?> ) // 오버랩되는 갯수
  objid = 1;
 else
  objid++;

 Comeon(objid);
}
function setInterval_best()
{
 interval_best = setInterval("best_change()",<?=$overlap_speed?>);//속도조절
}
function clearInterval_best()
{
 clearInterval(interval_best);
}
setInterval_best();
//-->
</SCRIPT>
<table width="100%" border="0" cellspacing="1" cellpadding="0" bgcolor="#CCCCCC">
  <tr>
    <td bgcolor="#FFFFFF" valign="top">
      <? for ($i=0; $i<count($list); $i++) {

    $title = get_text($list[$i][wr_subject]);
    $content = cut_str(get_text($list[$i][wr_content]), 75);
    $img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
    if (!file_exists($img) || !$list[$i][file][0][file])
    $img = "$latest_skin_path/img/noimage.gif";
    $href = "$g4[bbs_path]/board.php?bo_table=$bo_table";

//레이어 제어
$j = $i + 1; 
if ($j == "1") {
echo "<DIV id=debate_content$j onmouseover=clearInterval_best() onmouseout=setInterval_best()>"; }
else { echo "<DIV id=debate_content$j onmouseover=clearInterval_best() onmouseout=setInterval_best() style='DISPLAY: none;'>\n"; }
?>
      <table background="<?=$img?>" width="100%" border="0" cellspacing="0" cellpadding="0" height="180">
        <tr>
          <td align="right" valign="bottom">
            <table border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td style="filter:alpha(opacity=60)"><a href='<?=$list[$i][wr_link1]?>' title='<?=$title?>'><b><font color="#0099ff"><?=nl2br(stripslashes($list[$i][wr_content]))?></font></b></a></td>
                <td width="30"></td>
              </tr>
            </table>
          </td>
        </tr>
        <tr>
          <td align="right" height="35">
            <table width="100%" border="0" cellspacing="0" cellpadding="0">
              <tr>
                <td align="right" style="filter:alpha(opacity=60)"><a href='<?=$list[$i][wr_link1]?>' title='<?=$title?>'><b><font color="#0099ff"><?=$list[$i][wr_subject]?></font></b></a></td>
                <td width="30"></td>
              </tr>
            </table>
          </td>
        </tr>
      </table>
      <? echo "</DIV>\n\n";  } ?>
    </td>
  </tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="5">
  <tr>
    <td></td>
  </tr>
</table>
<div id="button1">
  <div id="button2">
    <table width="" border="0" align="right" cellpadding="0" cellspacing="0">
      <tr>
        <? for ($i=0; $i<count($list); $i++) { $k = $i + 1; ?>
        <td><a href="javascript://" onClick="javascript:Comeon('<?=$k?>')"><img src="<?=$latest_skin_path?>/img/<?=$k?>_on.gif" width="33" height="11" hspace="2"  border="0" id="debate<?=$k?>" onMouseOver="clearInterval_best()" onMouseOut="setInterval_best()" <? if($k == "1") { echo ""; } else { echo "style='DISPLAY: none;' "; } ?>>
          <img src="<?=$latest_skin_path?>/img/<?=$k?>.gif" width="33" height="11" hspace="2"  border="0"  id="debate<?=$k?>#1"  <? if($k == "1") { echo "style='DISPLAY: none;'"; } else { echo ""; } ?>></a></td>
        <? } ?>
      </tr>
    </table>
  </div>
</div>

---------------------------------------------------------------------------------------

여기까지 이구요. 아래는원래 기능이 잘 작동하는 블레스님의 최신글 스킨 소스입니다.

---------------------------------------------------------------------------------------
<?
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가

$overlap_speed = "3000";
$blink_speed = "600";

$swf_width = "519"; // 플래시 파일을 업로드시 수동으로 싸이즈 입력 = 넓이
$swf_height = "139"; // 플래시 파일을 업로드시 수동으로 싸이즈 입력 = 높이

?>

<script language="JavaScript">
<!-- 
function doBlink() {
var blink = document.all.tags("BLINK")
for (var i=0; i < blink.length; i++)
blink[i].style.visibility = blink[i].style.visibility == "" ? "hidden" : ""
}
function startBlink() {
if (document.all)
setInterval("doBlink()",<?=$blink_speed?>)
}
window.onload = startBlink;
-->
</script>

<SCRIPT type=text/javascript>
<!--
old_debate='1';
function Comeon(objid){
document.getElementById("debate"+old_debate).style.display="none";
document.getElementById("debate"+old_debate+"#1").style.display="";
document.getElementById("debate"+objid+"#1").style.display="none";
document.getElementById("debate"+objid).style.display="";
document.getElementById("debate_content"+old_debate).style.display="none";
document.getElementById("debate_content"+objid).style.display="";
old_debate=objid;
}
var objid = 1;
var interval_best;

function best_change()
{
 if( objid == <?=$rows?> ) // 오버랩되는 갯수
  objid = 1;
 else
  objid++;

 Comeon(objid);
}
function setInterval_best()
{
 interval_best = setInterval("best_change()",<?=$overlap_speed?>);//속도조절
}
function clearInterval_best()
{
 clearInterval(interval_best);
}
setInterval_best();
//-->
</SCRIPT>

<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="5"><img src="<?=$latest_skin_path?>/img/box_top_left.gif" width="5" height="5"></td>
    <td align="center" background="<?=$latest_skin_path?>/img/box_top_center.gif"><img src="<?=$latest_skin_path?>/img/box_top_center.gif" width="1" height="5"></td>
    <td width="5"><img src="<?=$latest_skin_path?>/img/box_top_right.gif" width="5" height="5"></td>
  </tr> 
  <tr>
    <td background="<?=$latest_skin_path?>/img/box_middle_left.gif"><img src="<?=$latest_skin_path?>/img/box_middle_left.gif" width="5" height="1"></td>
    <td style="padding:0 1 0 1px;">

<? for ($i=0; $i<count($list); $i++) {

$title = get_text($list[$i][wr_subject]);
$content = nl2br($list[$i][wr_content]);

$img = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][0][file]);
$img_bg = "$g4[path]/data/file/$bo_table/".urlencode($list[$i][file][1][file]);


if ($list[$i][wr_link1]) { $link_all = "<a href='$g4[bbs_path]/board.php?bo_table={$list[$i][wr_link1]}' target='{$list[$i][wr_8]}'>"; }
else { $link_all = "<a href='{$list[$i][wr_link2]}' target='{$list[$i][wr_9]}'>"; }


$j = $i + 1; 
if ($j == "1") {
echo "<DIV id=debate_content$j onmouseover=clearInterval_best() onmouseout=setInterval_best()>"; }
else { echo "<DIV id=debate_content$j onmouseover=clearInterval_best() onmouseout=setInterval_best() style='DISPLAY: none;'>\n"; }
 
?>

 <table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td height="0" align="right"><div id="text1" style="position:absolute; z-index:1; width: 0;">
                <div id="text2" style="position:relative; left:-320px; top:20px; z-index:1; width: 0;">
                  <table width="300" border="0" cellpadding="0" cellspacing="0">
                    <tr>
                      <td> <table width="" border="0" align="right" cellpadding="0" cellspacing="0">
                              <td height="40" align="right" style="font-size:<?=$list[$i][wr_2]?>px; font-weight:bold;">
                                      <?=$link_all?>
                                      <span style="color: <?=$list[$i][wr_1]?>; font-size:<?=$list[$i][wr_2]?>px; font-weight:bold; font-family:<?=$list[$i][wr_10]?>; ">
                                      <? if($list[$i][wr_3] == "1") { echo "<blink>"; } ?>
                                      <?=$list[$i][wr_subject]?>
                                      <? if($list[$i][wr_3] == "1") { echo "</blink>"; } ?>
                                      </span></a></td>
                          </tr>
                          <tr>
                            <td align="right"><?=$link_all?><?=$list[$i][wr_content];?></a>
                          </tr>
                          <tr>
                            <td height="30" align="right"><img src="<?=$latest_skin_path?>/img/dot.gif" width="8" height="11" hspace="2" align="absmiddle">
          <?=$link_all?>
                                        <span style="color: <?=$list[$i][wr_5]?>; font-size:<?=$list[$i][wr_6]?>px; font-weight:bold; <? if($list[$i][wr_7] == "1") { echo "text-decoration:underline;"; } ?>">
                                        <?=$list[$i][wr_4]?>
                                        </span></a></td>
                          </tr>
                        </table></td>
                    </tr>
                  </table>
                </div>
      </div></td>
  </tr>
  <tr><td background="<?=$img_bg?>">
  <?  switch(array_pop(explode(".",$img))) { 
case "gif" : echo "{$link_all}<img src='{$img}' border='0'></a>"; break;
case "jpg" : echo "{$link_all}<img src='{$img}' border='0'></a>"; break;
case "png" : echo "{$link_all}<img src='{$img}' border='0'></a>"; break;
case "swf" : echo "<textarea id=swf_cover_img style='display:none;' rows='0' cols='0'>
                            <object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0' width='{$swf_width}' height='{$swf_height}'>
                                            <param name='movie' value='{$img}'>
                                            <param name='quality' value='high'>
                                            <param name='wmode' value='transparent'>
                                            <embed src='{$img}' quality='high' pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='{$swf_width}' height='{$swf_height}'>
</embed></object></textarea><script>iePass('swf_cover_img')</script>"; break;

} ?></td>
  </tr>
</table>
<? echo "</DIV>\n\n";  } ?>
 
<? if (count($list) == 0) { echo "<table width='100%'><tr><td  height='48' align='center' class='no_list'>커버스토리 게시물이 없습니다.</td></tr></table>"; } ?>


<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td align="right"><div id="button1" style="position:absolute; z-index:1; width: 0;">
              <div id="button2" style="position:relative; left:-230px; top:-25px; z-index:1; width: 205;">
                <table width="" border="0" align="right" cellpadding="0" cellspacing="0">
                  <tr>
  <? for ($i=0; $i<count($list); $i++) {
  $k = $i + 1; 
                  ?>
                  <td><a href="javascript://" onmouseover="javascript:Comeon('<?=$k?>')">
                    <img src="<?=$latest_skin_path?>/img/<?=$k?>_on.gif" width="33" height="11" hspace="2"  border="0" id="debate<?=$k?>" onmouseover="clearInterval_best()" onmouseout="setInterval_best()" <? if($k == "1") { echo ""; } else { echo "style='DISPLAY: none;' "; } ?>>
                    <img src="<?=$latest_skin_path?>/img/<?=$k?>.gif" width="33" height="11" hspace="2"  border="0"  id="debate<?=$k?>#1"  <? if($k == "1") { echo "style='DISPLAY: none;'"; } else { echo ""; } ?>></a>
                    </td>
<? } ?>
                  </tr>
                </table>
              </div>
</div></td>
  </tr>
</table>


     
    </td>
    <td background="<?=$latest_skin_path?>/img/box_middle_right.gif"><img src="<?=$latest_skin_path?>/img/box_middle_right.gif" width="5" height="1"></td>
  </tr>
  <tr>
    <td><img src="<?=$latest_skin_path?>/img/box_bottom_left.gif" width="5" height="5"></td>
    <td align="center" background="<?=$latest_skin_path?>/img/box_bottom_center.gif"><img src="<?=$latest_skin_path?>/img/box_bottom_center.gif" width="1" height="5"></td>
    <td><img src="<?=$latest_skin_path?>/img/box_bottom_right.gif" width="5" height="5"></td>
  </tr> 
</table>

---------------------------------------------------------------------------------------

꼭 좀 부탁드리겠습니다. 읽어주셔서 감사합니다 꾸벅~(__)
  • 복사

댓글 전체

© SIRSOFT
현재 페이지 제일 처음으로