freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

php網(wǎng)站設(shè)計(jì)項(xiàng)目教學(xué)實(shí)訓(xùn)指導(dǎo)書(shū)-資料下載頁(yè)

2025-04-16 12:17本頁(yè)面
  

【正文】 where id=39。.$_POST[39。id39。].39。,$conn)。 //執(zhí)行修改語(yǔ)句 if($update){echo scriptalert(39。修改成功!39。)。=39。39。/script。 }else{echo scriptalert(39。修改失??!39。)。=39。39。/script。 } } ?4.刪除圖書(shū)信息在圖書(shū)分頁(yè)瀏覽頁(yè)面中,單擊“刪除”超鏈接后,根據(jù)超鏈接傳遞的ID值,應(yīng)用delete語(yǔ)句完成指定圖書(shū)信息的刪除操作。: ?php header(contenttype:text/html。charset=utf8)。 //設(shè)置文件編碼 include(conn/)。 //包含數(shù)據(jù)庫(kù)連接文件 if(isset($_GET[39。id39。])){ //判斷id是否存在 $delete=mysql_query(delete from tb_book where id=39。.$_GET[39。id39。].39。,$conn)。 //執(zhí)行刪除語(yǔ)句 if($delete){ echo scriptalert(39。刪除成功!39。)。=39。39。/script。 }else{ echo scriptalert(39。刪除失??!39。)。=39。39。/script。 } } ? 圖書(shū)搜索模塊設(shè)計(jì) 圖書(shū)搜索模塊概述在圖書(shū)搜索條件下拉列表中選擇查詢條件,單擊“搜索”按鈕,即可顯示搜索結(jié)果。 圖書(shū)搜索模塊運(yùn)行效果 通過(guò)JavaScript腳本創(chuàng)建級(jí)聯(lián)下拉列表框本模塊通過(guò)JavaScript技術(shù)判斷搜索條件是否為空及根據(jù)用戶選擇的數(shù)據(jù)更改相應(yīng)列表中的數(shù)據(jù)。當(dāng)用戶在第一個(gè)列表中選擇搜索條件后,第二個(gè)列表中的數(shù)據(jù)也將隨之改變,并與第一個(gè)列表中的數(shù)據(jù)相對(duì)應(yīng),關(guān)鍵代碼如下: script function fetch(){ //判斷搜索關(guān)鍵字是否為空 if(==){ alert(請(qǐng)輸入搜索關(guān)鍵字!)。 ()。 return false。 } return true。 } /script script language=javascript function press(opt){ //定義press()方法,控制下拉列表框select2顯示的值 //opt表示現(xiàn)有可選項(xiàng)的數(shù)目 [opt]=new Option(ok=([opt])? [opt].innerText+(): (),ok) =opt。}/scriptscript language=javascriptfunction up(opt){ //定義up()方法控制select2的值//opt表示現(xiàn)有可選項(xiàng)的數(shù)目 if([opt]){ if(==8){ var str=[opt].innerText。 var len=。 [opt].innerText=(0,len1)。 if([opt].innerText== )(2)。 } if(==32){ [opt].innerText+= 。 } }}/script 圖書(shū)搜索模塊實(shí)現(xiàn)過(guò)程。 圖書(shū)搜索模塊設(shè)計(jì)效果具體實(shí)現(xiàn)過(guò)程如下:(1)創(chuàng)建form表單,添加下拉列表框、“搜索”按鈕,將查詢的關(guān)鍵字提交到本頁(yè),其關(guān)鍵代碼如下: table width=758 height=23 border=0 cellpadding=0 cellspacing=0 tr td width=206div align=right class=STYLE2圖書(shū)搜索:/div/td td width=159table form id=list name=list method=post tr td width=125 align=left valign=middle select name=select onchange=javascript:() option value= selected=selected請(qǐng)選擇/option option value=Famous_Id類別/option option value=Famous_Ids語(yǔ)言/option option value=boo_name書(shū)名/option option value=jianjie簡(jiǎn)介/option option value=mulu目錄/option /select/td /tr /form /table/td td width=295table width=254 height=29 border=0 cellspacing=0 cellpadding=0 form id=form1 name=form1 method=post action= onkeypress= press(3) onkeyup=up(3) tr td width=110select name=select2 option selected=selected請(qǐng)選擇/option ?php if(isset($_POST[39。select39。])){ $select=$_POST[39。select39。]。 if($select==Famous_Id){ $sel=mysql_query(select * from tb_sort,$conn)。//查詢圖書(shū)類別 while($arr=mysql_fetch_array($sel)){ ? option value=?php echo $arr[39。sort39。]。??php echo $arr[39。sort39。]。? /option ?php } }else if($select==Famous_Ids){ $sel1=mysql_query(select * from tb_program,$conn)。 //查詢圖書(shū)語(yǔ)言 while($arr1=mysql_fetch_array($sel1)){ ? option value=?php echo $arr1[39。talk39。]。? selected=selected ?php echo $arr1[39。talk39。]。?/option ?php } }else{ ? option value=?php echo $arr1[39。talk39。]。? selected=selected ?php echo $arr1[39。talk39。]。?/option ?php } } ? /select /td td width=144 input type=image name=imageField src=images/ onclick= return fetch()。 //td /tr /form /table/td /tr /table頁(yè)面設(shè)計(jì)完成后,開(kāi)始編寫(xiě)JavaScript腳本,判斷搜索條件下拉列表的相關(guān)代碼(,此處不再贅述)。(2)在本頁(yè)中,根據(jù)form表單提交的關(guān)鍵字執(zhí)行查詢操作,分頁(yè)循環(huán)輸出查詢結(jié)果,關(guān)鍵代碼如下: table width=606 height=90 border=0 cellpadding=0 cellspacing=0 tr td width=305 height=33div align=center書(shū)名/div/td td width=301div align=center發(fā)布日期/div/td /tr ?php if(isset($_POST[39。select239。])){ $key=$_POST[39。select239。]。 $sel1=mysql_query(select * from tb_book where sort=39。.$_POST[39。select239。].39。 or talk=39。.$_POST[39。select239。].39。 or catalog like 39。%$key%39。 or synopsis like 39。%$key%39。 or books like 39。%$key%39。,$conn)。 //執(zhí)行模糊查詢語(yǔ)句 $count=mysql_num_rows($sel1)。 //獲取查詢結(jié)果 if($count0){ while($arr=mysql_fetch_array($sel1)){ //循環(huán)輸出查詢結(jié)果 ? tr td height=27 a href=?id=?php echo $arr[39。id39。]。??php echo $arr[39。books39。]。? /a/td td?php echo $arr[39。date39。]。?/td /tr ?php } }else{ echo scriptalert(39。對(duì)不起,沒(méi)有您要查找的內(nèi)容!39。)。= 39。39。/script。 } } ? ?php if (isset($_GET[39。page39。])){ //判斷分頁(yè)變量是否為空 $page=$_GET[39。page39。]。 //定義分頁(yè)變量,并且賦值 }else{ $page=1。 //如果分頁(yè)變量不存在,則為其賦空值 } if($page){ $page_size=12。 //每頁(yè)顯示記錄數(shù) $page_count=ceil($count/$page_size)。 //總頁(yè)數(shù) $offset=($page1)*$page_size。 //計(jì)算每頁(yè)的起始行數(shù) //定義SQL語(yǔ)句,查詢當(dāng)前頁(yè)顯示的記錄 $query=select * from tb_books where id order by id desc limit $offset, $page_size。 $result=mysql_query($query)。 //執(zhí)行查詢操作 } ? tr td height=30 colspan=2div align=right div align=right共?php echo $count。?條記錄 共?php echo $page_count。?頁(yè) 當(dāng)前第?php echo $page。?頁(yè) ?php if($page!=1){ echo a href=?page=1首頁(yè)/a。 echo a href=?page=.($page1).上一頁(yè)/a。 } if($page$page_count){ echo a href=?page=.($page+1).下一頁(yè)/a。 echo a href=?page=$page_count尾頁(yè)/a。 } ? /div/td /tr /table五、練習(xí)六、源程序清單、測(cè)試數(shù)
點(diǎn)擊復(fù)制文檔內(nèi)容
教學(xué)教案相關(guān)推薦
文庫(kù)吧 www.dybbs8.com
備案圖鄂ICP備17016276號(hào)-1