N

급 질문 입니다... select 메뉴 db 불러오기

· 15년 전 · 1980 · 2
4개의 db를 a1, a2, a3, a4라고 했을때
셀랙트박스로 불러 오는건 겨우 했습니다...
근데 그 값을 저장할수가 없습니다... 방법좀 찾아 주세요...
// 프로세싱 가격 가져오기
$order_opt1 = "$productInfor[a1]";
$order_opt2 = "$productInfor[a2]";
$order_opt3 = "$productInfor[a3]";
$order_opt4 = "$productInfor[a4]";


<input type=hidden name=local_pick value="<?= $reserveInfor[local_pick] ?>">

<select name='rate' class=form_box>
<option selected="selected" value="$productInfor[a1]"> Regular : $<?= $order_opt1 ?>/page </option>
<option value="$productInfor[a2]"> Fast : $<?= $order_opt2 ?>/page </option>
<option value="$productInfor[a3]"> Express : $<?= $order_opt3 ?>/page </option>
<option value="$productInfor[a4]"> Urgent : $<?= $order_opt4 ?>/page </option>
</select>


뭐가 잘못된거죠???????ㅠㅠ<div class='small'>[이 게시물은 관리자님에 의해 2011-10-31 17:16:08 PHP & HTML에서 이동 됨]</div>
|

댓글 2개

우의 코드를 보고는 잘 모르겠네요..
회원정보가 $data에 설정되고 거기서 성별항목이 sex이고 1인 경우 남자,2인 경우 여자일때
<select id="sex" name="sex">
<option value="0">선택</option>
<option value="1" <?php if($data["sex"] == 1) echo "selected";?>>남자</option>
<option value="2" <?php if($data["sex"] == 2) echo "selected";?>>여자</option>
</select>
이렇게 하면 sex가 1인 경우에는 남자로,2인 경우에는 여자로 표시됩니다.
$order_opt1 = "$productInfor[a1]"; ->> $order_opt1 = $productInfor[a1];

또는

<option selected="selected" value="$productInfor[a1]"> Regular : $<?= $productInfor[a1] ?>/page </option>

이런식으로 해보세요.
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
15년 전 조회 945
15년 전 조회 2,202
15년 전 조회 1,055
15년 전 조회 1,869
15년 전 조회 991
15년 전 조회 1,016
15년 전 조회 1,677
15년 전 조회 1,278
15년 전 조회 1,595
15년 전 조회 1,898
15년 전 조회 1,530
15년 전 조회 1,620
15년 전 조회 1,003
15년 전 조회 2,534
15년 전 조회 1,278
15년 전 조회 995
15년 전 조회 1,355
15년 전 조회 1,067
15년 전 조회 2,333
15년 전 조회 1,369
15년 전 조회 1,161
15년 전 조회 1,261
15년 전 조회 1,233
15년 전 조회 1,255
15년 전 조회 1,311
15년 전 조회 819
15년 전 조회 759
15년 전 조회 734
15년 전 조회 1,421
15년 전 조회 1,215
15년 전 조회 1,059
15년 전 조회 1,055
15년 전 조회 1,454
15년 전 조회 3,481
15년 전 조회 1,349
15년 전 조회 2,149
15년 전 조회 1,407
15년 전 조회 1,237
15년 전 조회 2,899
15년 전 조회 1,872
15년 전 조회 2,775
15년 전 조회 2,880
15년 전 조회 1,618
15년 전 조회 1,319
15년 전 조회 1,812
15년 전 조회 1,235
15년 전 조회 1,533
15년 전 조회 1,408
15년 전 조회 1,806
15년 전 조회 1,981
15년 전 조회 1,227
15년 전 조회 1,660
15년 전 조회 1,460
15년 전 조회 1,274
15년 전 조회 1,315
15년 전 조회 1,661
15년 전 조회 1,091
15년 전 조회 1,270
15년 전 조회 2,913
15년 전 조회 1,740
15년 전 조회 1,113
15년 전 조회 1,133
15년 전 조회 1,593
15년 전 조회 1,622
15년 전 조회 1,887
15년 전 조회 1,380
15년 전 조회 1,752
15년 전 조회 1,010
15년 전 조회 1,377
15년 전 조회 1,653
15년 전 조회 3,040
15년 전 조회 1,429
15년 전 조회 1,404
15년 전 조회 1,273
15년 전 조회 1,169
15년 전 조회 1,169
15년 전 조회 3,781
15년 전 조회 3,166
15년 전 조회 2,323
15년 전 조회 2,779
15년 전 조회 1,860
15년 전 조회 1,404
15년 전 조회 1,400
15년 전 조회 2,709
15년 전 조회 1,243
15년 전 조회 2,290
15년 전 조회 1,083
15년 전 조회 2,237
15년 전 조회 1,168
15년 전 조회 2,839
15년 전 조회 1,095
15년 전 조회 1,536
15년 전 조회 1,076
15년 전 조회 3,307
15년 전 조회 1,654
15년 전 조회 1,680
15년 전 조회 1,700
15년 전 조회 1,748
15년 전 조회 1,338
15년 전 조회 2,100