- ?php
- define('CURSCRIPT', 'faq');
- require_once './include/common.inc.php';
- if(!$discuz_uid) {
- showmessage('group_nopermission', NULL, 'NOPERM');
- }
- if($_POST['title']) {
- $hid=empty($_POST['edhid'])?false:intval($_POST['edhid']);
- $headdate=$_POST['headdate'];
- $title=$_POST['title'];
- //die($tablepre);
- if($hid) {
- $query=$db->query("UPDATE cdb_tthy_heat SET title='$title' WHERE hid=$hid");
- }
- else {
- $query = $db->query("REPLACE INTO `cdb_tthy_heat` (hid,userid,headdate,title) values (NULL,$discuz_uid,'$headdate','$title')");
- }
- }
- if($_GET['delid']) {
- $id=intval($_GET['delid']);
- $query=$db->query("DELETE FROM cdb_tthy_heat WHERE hid=$id");
- @unlink('forumdata/heat/'.$id.'.gif');
- }
- $str="";
- $query=$db->query("SELECT * FROM cdb_tthy_heat WHERE userid='$discuz_uid' ORDER BY `cdb_tthy_heat`.`hid` DESC");
- $heatarr=array();
- $curhid="";
- $i=0;
- if(mysql_affected_rows()>0) {
- while($heat = $db->fetch_array($query)) {
- if($i==0) {
- $curhid=$heat['hid'];
- }
- $i++;
- $data=empty($heat['data'])?'null':$heat['data'];
- $heatarr[]='"'.$heat['hid'].'":{"title":"'.$heat['title'].'","headdate":"'.$heat['headdate'].'","data":'.$data.',"islab":"0"}';
- }
- $str='{'.implode(",", $heatarr).'}';
- }
- else {
- $str='false';
- $curhid='false';
- }
- ?>
- <!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> 女性基础体温管理 </title>
- <script type='text/javascript'>if(location==top.location) location = "heat.php";</script>
- <script type='text/javascript'>
- var seeduid='<?php echo $discuz_uid; ?>';
- var myheats =<?php echo $str; ?>;
- var curHeat=myheats[<?php echo $curhid; ?>];
- var curHid='<?php echo $curhid; ?>';
- </script>
- <link rel='stylesheet' href='js/style.css' type='text/css' />
- <script type="text/javascript" src="js/ajax.js"></script>
- <script type="text/javascript" src="js/heat.js"></script>
- <script type="text/javascript">
- function setParent(){
- var chei = (document.body.clientHeight < 500 ) ? 500 : document.body.clientHeight;
- if( !document.all ) chei += 20;
- else if( MzBrowser.version==8 ) chei += 20;
- parent.$("tool").style.height = chei + "px";
- }
- </script>
- </head>
- <body onload="setParent()" style="background-color:#F7DBE7;">
- <div class="wapper">
- <div class="right">
- <div class="titline">
- <div class="titleft">
- <h4><img src="js/icon2.gif"> 女性基础体温管理</h4>
- <div class="menu">
- <div> 我的基础体温表 </div>
- <!--<div class="mr">朋友的基础体温表</div>-->
- </div>
- </div>
- <div id="addbutt" class="addbutt"><button onclick="creatHeat()" style='cursor:pointer'>新建体温表</button></div>
- </div>
- <table class="hlist" cellpadding="0" cellspacing="0" border='0'><tbody id='hlist'></tbody></table>
- <div id="setarea" style="display:none">
- <h4 class="settit"> 体温表设置:<span id="heattit"></span></h4>
- <div class="setline">
- <div class="setL">
- <div>请从日历中选择一天在右侧进行设置!</div>
- <div id="rilis"> </div>
- </div>
- <div class="setR">
- <div>温度:<input size='6' name="heat" id='heat' onkeyup="chkHeat(this)" />℃ 时间:<select name='hour' id='hour'><option value=''></option></select>点<select name='minute' id='minute'><option value=''></option></select>分 </div>
- <div>月经:<input type='radio' value='1' name='dmenses' id='dmenses1' />是 <input type='radio' value='0' name='dmenses' id='dmenses0' />否</div>
- <div>同房:<input type='radio' value='1' name='dsexact' id='dsexact1' />是 <input type='radio' value='0' name='dsexact' id='dsexact0' />否</div>
- <div>排卵试纸显示:<select name='plsz' id='plsz'>
- <option value='0'>未测试</option> <option value='1'>强阳</option> <option value='2'>弱阳</option> <option value='3'>弱弱阳</option><option value='4'>白板</option>
- </select></div>
- <div>早孕试纸显示:<select name='zysz' id='zysz'>
- <option value='0'>未测试</option> <option value='1'>强阳</option> <option value='2'>弱阳</option> <option value='3'>弱弱阳</option><option value='4'>白板</option>
- </select></div>
- <div>备注:<input name='bz' id='bz' size='30' maxlength='50'>(限50字符)</div>
- <div><input type="image" src='js/save.gif' onclick="return saveHeat()" /><input id='edIndex' type='hidden' value='1' /></div>
- </div>
- </div>
- </div>
- <div><a id="dimglink" href='' target="_blank"><img style='display:none' id="dimg" /></a></div>
- <table id="dlisttb" bgcolor='#538ed5' cellpadding="0" cellspacing="1" border="0">
- <caption><strong></strong></caption>
- <tr height='40'><th width='110'>日期</th><th width='70'>温度</th><th width='80'>测量时间</th>
- <th width='50'>是否<br />月经</th><th width='50'>是否<br />同房</th><th width='70'>排卵试纸<br />颜色</th><th width='70'>早孕试纸<br />颜色</th><th width='225'>备注</th></tr>
- <tbody id="datalist"></tbody></table>
- </div>
- </div>
- <script type='text/javascript'>
- for( i=0; i<60; i++ ){
- var newOpt = document.createElement("option");
- newOpt.value = newOpt.innerHTML = i;
- $("minute").appendChild(newOpt);
- if( i < 24 ){
- var clOpt = newOpt.cloneNode(true);
- $("hour").appendChild(clOpt);
- }
- }
- getMyHeat();
- </script>
- </body></html>
复制代码
DZ7.2 升级DX 1.5后。这个插件如何修改才能用。。。。
require_once './include/common.inc.php'; 在DX里没有这个。。要怎么修改
|