게시글 value 값이 안넘어가는 문제 도와주세요 ㅠ
본문
php 개발하시던 분이 퇴사해서 유지보수를 맡게되었는데
php는 전혀몰라서 찾아보는데도 힘드네요 ㅠㅠ
radio 로 후원금액을 선택하는건데 일시후원은 값이 보이는데 정기후원부분이 값이 안나오네요 ㅠ
write.skin
<div style="border:4px solid #b3d6e4;background-color:#F3F3F3;width:630px;padding:13px 20px;margin-bottom:20px">
<strong>후원유형을 선택</strong>
<input type="radio" name="type" value="a" onclick="fnSponType(this.value)" <?if($type=="a"){?>checked<?}?>> 정기후원
<input type="radio" name="type" value="b" onclick="fnSponType(this.value)" <?if($type=="b"){?>checked<?}?>> 일시후원
<input type="radio" name="type" value="c" onclick="fnSponType(this.value)" <?if($type=="c"){?>checked<?}?>> 물품후원
</div>
<script>
function fnSponType(vType) {
document.location = "./write.php?bo_table=<?=$bo_table?>&type=" + vType;
}
</script>
<table id="bo_w" class="frm_tbl" style="border-top:2px solid #000;border-bottom:2px solid #000">
<tbody>
<!-- 공통 Start -->
<tr>
<th scope="row"><label for="wr_subject">후원방법<strong class="sound_only">필수</strong></label></th>
<td style="color:#3687cc;font-weight:bold"><input type="hidden" name="wr_subject" value="<?=$type_subject?>" id="wr_subject" required><?=$type_subject?></td>
</tr>
<tr>
<th scope="row"><label for="wr_name">성명(상호)<strong class="sound_only">필수</strong></label></th>
<td><input type="text" name="wr_name" value="<?=$member[mb_name]?>" id="wr_name" required class="frm_input required" size="20" maxlength="20"></td>
</tr>
<tr>
<th scope="row"><label for="wr_9">성별</label><strong class="sound_only">필수</strong></th>
<td>
<input type="radio" name="wr_9" value="M" id="mb_sex1" <?if($member['mb_sex']=="M"||$write[wr_9]=="M"){?>checked<?}?>><label for="M"> 남</label>
<input type="radio" name="wr_9" value="F" id="mb_sex2" <?if($member['mb_sex']=="F"||$write[wr_9]=="F"){?>checked<?}?>><label for="F"> 여</label>
</td>
</tr>
<?
// 생년월일 구하기
if($member['mb_birth'])
$wr_10 = $member['mb_birth'];
else
$wr_10 = $write['wr_10'];
?>
<tr>
<th scope="row"><label for="wr_10">주민등록번호<br/>(앞 6자리만)<strong class="sound_only">필수</strong></label></th>
<td><input type="text" name="wr_10" value="<?=$wr_11?>" id="wr_11" required class="frm_input required" title="주민등록번호" size="20" maxlength="100"> (기부금영수증 발행시 필요)</td>
</tr>
<tr>
<th scope="row"><label for="wr_link2">연락처<strong class="sound_only">필수</strong></label></th>
<td><input type="text" name="wr_link2" id="wr_link2" value="<?if($w=="u"){?><?=$write[wr_link2]?><?}else{?><?=$member[mb_hp]?><?}?>" required class="frm_input required" size="20" maxlength="20"></td>
</tr>
<tr>
<th scope="row"><label for="wr_email">이메일<strong class="sound_only">필수</strong></label></th>
<td><input type="text" name="wr_email" value="<?=$email?>" id="wr_email" required class="frm_input email" size="50" maxlength="100"></td>
</tr>
<!-- 공통 End -->
<? if($type=="a") { //정기후원 ?>
<?
// 후원정보 수정시
if($w) {
// 기타금액시
if($write[wr_1]!="10000"&&$write[wr_1]!="20000"&&$write[wr_1]!="30000"&&$write[wr_1]!="50000"&$write[wr_1]!="100000")
$wr_1_r6_checked = "checked";
// 우편번호 정보 구하기
$wr_5_1 = substr($write[wr_5],1,3);
$wr_5_2 = substr($write[wr_5],5,3);
$wr_5_temp = explode("^",substr($write[wr_5],10));
$wr_5_3 = $wr_5_temp[0];
$wr_5_4 = $wr_5_temp[1];
}
?>
<tr>
<th scope="row"><label for="wr_1">후원금액</label></th>
<td style="height:70px;line-height:30px;padding:8px 0">
<input type="radio" name="wr_1_r" required id="wr_1_r1" value="10000" <?if($write[wr_1]=="10000"){?>checked<?}?> onclick="fnWr1(this.value)"> 월 10,000
<input type="radio" name="wr_1_r" required id="wr_1_r2" value="20000" <?if($write[wr_1]=="20000"){?>checked<?}?> onclick="fnWr1(this.value)"> 월 20,000
<input type="radio" name="wr_1_r" required id="wr_1_r3" value="30000" <?if($write[wr_1]=="30000"){?>checked<?}?> onclick="fnWr1(this.value)"> 월 30,000
<input type="radio" name="wr_1_r" required id="wr_1_r4" value="50000" <?if($write[wr_1]=="50000"){?>checked<?}?> onclick="fnWr1(this.value)"> 월 50,000
<input type="radio" name="wr_1_r" required id="wr_1_r5" value="100000" <?if($write[wr_1]=="100000"){?>checked<?}?> onclick="fnWr1(this.value)"> 월 100,000
<br />
<input type="radio" name="wr_1_r" required id="wr_1_r6" value="" <?=$wr_1_r6_checked?> onclick="fnWr1(this.value)"> 기타 (5,000원 단위)
<span class="wr_1_area"></span>
<script>
$(function(){
$("input[name='wr_1_r']").click(function(){
if($("#wr_1_r6").is(":checked")){
$(".wr_1_area").html("<p style='display:inline-block;'><input type='text' name='wr_1' id='wr_1' required class='frm_input required' size='20' value='<?=$write[wr_1]?>'> 원</p>");
}else{
$(".wr_1_area").children().remove();
}
});
});
</script>
</td>
</tr>
list.skin
<tbody>
<?php
for ($i=0; $i<count($list); $i++) {
?>
<tr class="<?php if ($list[$i]['is_notice']) echo "bo_notice"; ?><?php if ($board[1]) echo "bo_sideview"; ?>">
<td class="td_num">
<?php
if ($list[$i]['is_notice']) // 공지사항
echo '<strong>공지</strong>';
else if ($wr_id == $list[$i]['wr_id'])
echo "<span class=\"bo_current\">열람중</span>";
else
echo $list[$i]['num'];
?>
</td>
<?php if ($is_checkbox) { ?>
<td class="td_chk">
<label for="chk_wr_id_<?php echo $i ?>" class="sound_only"><?php echo $list[$i]['wr_subject'] ?></label>
<input type="checkbox" name="chk_wr_id[]" value="<?php echo $list[$i]['wr_id'] ?>" id="chk_wr_id_<?php echo $i ?>">
</td>
<?php } ?>
<td style="text-align:center"><a href="<?=$list[$i]['href']?>"><?=$list[$i]['subject']?></a><br><?if($list[$i]['mb_id']) echo "<span style='color:red'>(회원)</span>"; else echo "(비회원)";?></td>
<td style="text-align:center"><?=$list[$i]['wr_name']?><br>(<?if($list[$i]['wr_9']=="M") echo "남"; else echo "여"; ?>)</td>
<td style="text-align:center"><?if($list[$i]['wr_11']==""){echo $list[$i]['wr_10'];}else{echo $list[$i]['wr_11'];}?></td>
<td style="text-align:center"><?=$list[$i]['wr_link2']?><br><a href="<?=$list[$i]['href']?>"><?=$list[$i]['wr_email']?></a></td>
<td style="text-align:center"><? if($list[$i]['wr_subject']=="정기후원"||$list[$i]['wr_subject']=="일시후원") echo number_format($list[$i]['wr_1'])." 원"; else echo "-"; ?></td>
<td style="text-align:center"><?=substr($list[$i]['wr_datetime'],0,10)?></td>
</tr>
답변 1
write.php 소스 긁어 가서 확인해본 봐론 우선 나옵니다.
css 부분이나 js 부분에서 해당 부분을 가린건 아닌지 소스 보기를 통해서 확인해보셔야 할것같습니다.
display:none 또는 hide() 등등