Register Register Member Login Member Login Member Login Forgot Password ??
PHP , ASP , ASP.NET, VB.NET, C#, Java , jQuery , Android , iOS , Windows Phone
 

Registered : 109,027

HOME > PHP > PHP Forum > รบกวนขอคำแนะนำครับ ต้องการ รันเลขใหม่ทุกครั้งที่เปลี่ยน เลขสัปดาห์ครับ



 

รบกวนขอคำแนะนำครับ ต้องการ รันเลขใหม่ทุกครั้งที่เปลี่ยน เลขสัปดาห์ครับ

 



Topic : 132636



โพสกระทู้ ( 39 )
บทความ ( 0 )



สถานะออฟไลน์




ฟฟ

ตอนนี้ดึงเลขสัปดาห์มาแสดงได้แล้ว อยากให้เลขตรงช่อง No.Week มันนับจาก 1 แล้วเพิ่มไปเรื่อยๆจากการ submit ในสัปดาห์ แล้วพอขึ้นสัปดาห์ใหม่ก็ให้มันมาเริ่มนับที่ 1 ใหม่ครับ ยกตัวอย่าง
Week 48 No.Week 1,2,3,......
Week 49 No.Week 1

ขอบคุณครับ



Code (PHP)
<?php //session_start();

include("connect/connection.php");
include("f_thaidate.php");
?>
<!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" />

  <meta name="viewport" content="width=device-width, initial-scale=1">
  <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css">
  <script src="https://code.jquery.com/jquery-1.12.4.js"></script>
  <script src="https://code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
  <script>
  $( function() {
    $( "#DateNotify" ).datepicker();
	    $( "#DateSick" ).datepicker();
	    $( "#LabDateSent" ).datepicker();
	    $( "#LabDateResult" ).datepicker();
	} );
  </script>
<!------------------------------เวลา------------------------------------->
  
  <script type="text/javascript" src="timepicker/jquery.timepicker.js"></script>
<link rel="stylesheet" type="text/css" href="timepicker/jquery.timepicker.css" />
	<!---
<script type="text/javascript" src="timepicker/lib/bootstrap-datepicker.js"></script>
<link rel="stylesheet" type="text/css" href="timepicker/lib/bootstrap-datepicker.css" />
<script type="text/javascript" src="timepicker/lib/site.js"></script>
	--->
<link rel="stylesheet" type="text/css" href="timepicker/lib/site.css" />
<script>
                $(function() {
                    $('#TimeNotify').timepicker({ 'timeFormat': 'H:i' });                   
                });
</script>
<!------------------------------------------------------------------->

<script>
function check() {
if 	(document.getElementById("DCIR").checked == true){
    document.getElementById("InvestCriteria").checked = true;
    document.getElementById("ServCriteria").checked = true;
    document.getElementById("CIR").checked = true;
		document.getElementById("shortmsg").disabled = false;

} else {
	document.getElementById("InvestCriteria").checked = false;
    document.getElementById("ServCriteria").checked = false;
    document.getElementById("CIR").checked = false;
		document.getElementById("shortmsg").disabled = true;

	}
}            
            
function check2() {
if 	(document.getElementById("InvestCriteria").checked == true){
    document.getElementById("DCIR").checked = false;
    document.getElementById("ServCriteria").checked = true;
    document.getElementById("CIR").checked = true;
			document.getElementById("shortmsg").disabled = true;

} else {
	document.getElementById("DCIR").checked = false;
    document.getElementById("ServCriteria").checked = false;
    document.getElementById("CIR").checked = false;
			document.getElementById("shortmsg").disabled = true;

	}
}            
    
function check3() {
if 	(document.getElementById("ServCriteria").checked == true){
    document.getElementById("InvestCriteria").checked = false;
    document.getElementById("DCIR").checked = false;
    document.getElementById("CIR").checked = true;
			document.getElementById("shortmsg").disabled = true;

} else {
	document.getElementById("InvestCriteria").checked = false;
    document.getElementById("DCIR").checked = false;
    document.getElementById("CIR").checked = false;
			document.getElementById("shortmsg").disabled = true;

	}
}            
    
</script>
<!---------------------get week---------------------------------------------->
 <script type="text/javascript">

        $(document).ready(function () {

                // 2. เซ็ทวันที่ใส่ Date onject
                var dt = new Date();

                // 3. เรียก function เพื่อหาสัปดาห์ที่เท่าไรของเดือน
                var week_no = dt.getWeekOfYear();

                // แสดงค่าใน textbox 02
                $('#Week').val(week_no);
            });

     

        Date.prototype.getWeekOfYear = function () {
            var onejan = new Date(this.getFullYear(), 0, 1);
            var today = new Date(this.getFullYear(), this.getMonth(), this.getDate());
            var dayOfYear = ((today - onejan + 86400000) / 86400000);
            return Math.ceil(dayOfYear / 7)
        };

</script>

<!----------------------เลือกจังหวัด อำเภอและตำบล-------------------------------> 
<script language=Javascript>
        function Inint_AJAX() {
           try { return new ActiveXObject("Msxml2.XMLHTTP");  } catch(e) {} //IE
           try { return new ActiveXObject("Microsoft.XMLHTTP"); } catch(e) {} //IE
           try { return new XMLHttpRequest();          } catch(e) {} //Native Javascript
           alert("XMLHttpRequest not supported");
           return null;
        };

        function dochange(src, val) {
             var req = Inint_AJAX();
             req.onreadystatechange = function () { 
                  if (req.readyState==4) {
                       if (req.status==200) {
                            document.getElementById(src).innerHTML=req.responseText; //รับค่ากลับมา
                       } 
                  }
             };
             req.open("GET", "localtion.php?data="+src+"&val="+val); //สร้าง connection
             req.setRequestHeader("Content-Type", "application/x-www-form1-urlencoded;charset=utf-8"); // set Header
             req.send(null); //ส่งค่า
        }

        window.onLoad=dochange('province', -1);     
    </script>     
    
    
    
<!------------------------เลือกโรค--------------------------------->
<script src="jquery-1.11.1.min.js" type="text/javascript"></script>
<script type="text/javascript">
  jq111 = jQuery.noConflict( true );

   jq111(document).ready(function() {
   jq111('#disease').change(function() {
   jq111.ajax({
     type: 'POST',
     data: {disease: $(this).val()},
     url: 'select_disease1.php',
     success: function(data) {
     $('#disease2').html(data);
        }
      });
    return false;
    });
  });
</script>
<!--------------------------------------------------------->
     
<title>SAT</title>
</head>
<body Onload="JavaScript:fncCreateElement()"> 
<form id="form1" name="form1" method="post" action="sat_save.php">
  <p>&nbsp;</p>
  <table width="100%" border="0">
    <tr>
      <td><p>&nbsp;</p>
        <table width="60%" border="0" align="center">
          <tr>
            <td colspan="4" align="center" bgcolor="#006699"><strong><img src="image/HDบันทึกรายละเอียดเหตุการณ์ใหม่.jpg" width="100%" height="120" /></strong></td>
          </tr>
          <tr>
            <td width="30%" bgcolor="#006699"><strong>ID</strong></td>
            <td width="70" colspan="3"><strong>
              <input type="text" name="ID" id="ID" size="5" readonly="readonly" value="<?php 	  		$sql="SELECT ID FROM sat";
			$result=mysql_query($sql);
			$rows=mysql_num_rows($result);
			echo $rows+1;

?>"/>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>Week</strong></td>
            <td><strong>
              <input type="text" name="Week" id="Week" size="5" readonly="readonly"/>
            </strong></td>
            <td width="70" bgcolor="#006699"><strong>No.Week </strong></td>
            <td><strong>
              <input type="text" name="NoWeek" id="NoWeek" size="5"/>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>วันที่รับแจ้ง</strong></td>
            <td><strong>
              <input type="text" name="DateNotify" id="DateNotify" />
            </strong></td>
            <td bgcolor="#006699"><strong>เวลา</strong></td>
            <td><strong>
              <input type="text" name="TimeNotify" id="TimeNotify" size='10'/>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>โรค/เหตุการณ์</strong></td>
            <td colspan="3"><strong>
              <textarea name="Event" id="Event" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699">&nbsp;</td>
            <td colspan="3"><strong>
              <select name="disease" id="disease">
                <option>Please select</option>
                <?php
					$Query = mysql_query('SELECT * FROM disease') or die('Error query #12');
					while($Result = mysql_fetch_array($Query))
						{
				?>
                <option value="<?PHP echo $Result["id"];?> "><?PHP echo $Result["id"]." : ".$Result["name"];?></option>
                
                <?PHP
						}
				?>
              </select>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699">&nbsp;</td>
            <td colspan="3"><strong>
              <select name="disease2" id="disease2">
              </select>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ช่องทางรับแจ้ง</strong></td>
            <td colspan="3">
              <strong>
              <label>
                <input type="radio" name="RouteNotify" value="E-mail" id="RouteNotify_0" />
                E-mail</label>
              <br />
              <label>
                <input type="radio" name="RouteNotify" value="Line" id="RouteNotify_1" />
                Line</label>
              <br />
              <label>
                <input type="radio" name="RouteNotify" value="Line" id="RouteNotify_2" />
                โทรศัพท์</label>
              <br />
              <label>
                <input type="radio" name="RouteNotify" value="Line" id="RouteNotify_3" />
                Fax<br />
              </label>
              <label>
                <input type="radio" name="RouteNotify" value="Line" id="RouteNotify_4" />
                อื่นๆ</label>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ชื่อผู้แจ้ง</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="NameNotify" id="NameNotify" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>หน่วยงานที่แจ้ง</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="InstituteNotify" id="InstituteNotify" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>จำนวน
              (ราย)</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="NoCase" id="NoCase" size='5'/>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ชื่อ-สกุลผู้ป่วย</strong></td>
            <td colspan="3"><strong>
              <textarea name="Patient" id="Patient" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>เพศ</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Sex" id="Sex" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>อายุ
              (ปี)</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="AgeY" id="AgeY" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>อายุ
              (เดือน)</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="AgeM" id="AgeM" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>อายุ
              (วัน)</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="AgeD" id="AgeD" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ที่อยู่
              ขณะป่วย</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Address" id="Address" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>จังหวัด</strong></td>
            <td colspan="3"><strong><span id="province">
                    <select>
                      <option value="0">- เลือกจังหวัด -</option>
                    </select>
            </span></strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>อำเภอ</strong></td>
            <td colspan="3"><strong><span id="amphur">
                    <select>
                      <option value='0'>- เลือกอำเภอ -</option>
                    </select>
            </span></strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ตำบล</strong></td>
            <td colspan="3"><strong><span id="district">
                    <select>
                      <option value='0'>- เลือกตำบล -</option>
                    </select>
            </span></strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ถนน</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Road" id="Road" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>หมู่ที่</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Moo" id="Moo" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>เบอร์โทรศัพท์
              ผู้ป่วย/ญาติ</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Tel" id="Tel" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>วันที่เริ่มป่วย</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="DateSick" id="DateSick" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>รายละเอียดเหตุการณ์</strong></td>
            <td colspan="3"><strong>
              <textarea name="Detail" id="Detail" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ปัจจัยเสี่ยง / พฤติกรรมเสี่ยงที่ทำให้เกิดโรค</strong></td>
            <td colspan="3"><strong>
              <textarea name="Risk" id="Risk" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ชื่อสิ่งส่งตรวจและชื่อ Lab</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="Lab" id="Lab" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>วันที่ส่งตัวอย่าง</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="LabDateSent" id="LabDateSent" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ผล Lab</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="LabResult" id="LabResult" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>วันที่
              ทราบผล</strong></td>
            <td colspan="3"><strong>
              <input type="text" name="LabDateResult" id="LabDateResult" />
            </strong></td>
          </tr>
        </table>
        <table width="60%" border="0" align="center">
          <tr>
            <td align="center" bgcolor="#CC9900"><strong><font color="#ooooFF"> เกณฑ์ CIR 
              จังหวัด</font></strong></td>
            <td align="center" bgcolor="#CC6600"><strong><font color="#ooooFF">เกณฑ์เฝ้าระวัง สคร.2</font></strong></td>
            <td align="center" bgcolor="#CC3300"><strong><font color="#ooooFF">เกณฑ์สอบสวน สคร.2</font></strong></td>
            <td align="center" bgcolor="#FF0000"><strong><font color="#ooooFF">เกณฑ์ 
              DCIR</font></strong></td>
          </tr>
          <tr>
            <td align="center" bgcolor="#FFFFCC"><strong>
              <input type="checkbox" name="CIR" id="CIR" />
            </strong></td>
            <td align="center" bgcolor="#FFFFCC"><strong>
              <input type="checkbox" name="ServCriteria" id="ServCriteria" onclick="check3()"/>
            </strong></td>
            <td align="center" bgcolor="#FFFFCC"><strong>
              <input type="checkbox" name="InvestCriteria" id="InvestCriteria" onclick="check2()"/>
            </strong></td>
            <td align="center" bgcolor="#FFFFCC"><strong>
              <input type="checkbox" name="DCIR" id="DCIR" onclick="check()"  />
            </strong></td>
          </tr>
        </table>
        <table width="60%" border="0" align="center">
          <tr>
            <td bgcolor="#006699"><strong>สรุปข้อมูลสั้นๆส่งผู้บริหาร</strong></td>
            <td><strong>
              <input type="text" name="shortmsg" id="shortmsg" disabled="disabled" size="50"/>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>คีย์โปรแกรมตรวจสอบข่าว</strong></td>
            <td><strong>
              <input type="checkbox" name="Eventbase" id="Eventbase" />
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>การเขียน 
            spot report</strong></td>
            <td><strong>
              <input type="checkbox" name="Spot" id="Spot" />
            </strong></td>
          </tr>
          <tr>
            <td width="30%" bgcolor="#006699"><strong>กิจกรรมที่ดำเนินการไปแล้ว</strong></td>
            <td width="70%"><strong>
              <textarea name="Activity" id="Activity" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>สิ่งที่ต้องติดตาม</strong></td>
            <td><strong>
              <textarea name="Follow" id="Follow" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ข้อเสนอแนะเพิ่มเติม</strong></td>
            <td><strong>
              <textarea name="Suggestion" id="Suggestion" cols="45" rows="5"></textarea>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>ผู้บันทึก</strong></td>
            <td><strong>
              <select name="NameSAT" id="NameSAT" >
                <option>กรุณาเลือกผู้บันทึก</option>
                <?php
					$Query = mysql_query('SELECT * FROM satteam') or die('Error query #12');
					while($Result = mysql_fetch_array($Query))
						{
				?>
                <option value="<?PHP echo $Result["id"];?>"><?PHP echo " ".$Result["name"];?></option>
                <?PHP
						}
				?>
              </select>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>Supervisor SAT</strong></td>
            <td><strong>
              <select name="NameSUP" id="NameSUP" >
                <option>กรุณาเลือกผู้บันทึก</option>
                <?php
					$Query = mysql_query('SELECT * FROM supteam') or die('Error query #12');
					while($Result = mysql_fetch_array($Query))
						{
				?>
                <option value="<?PHP echo $Result["id"];?>"><?PHP echo " ".$Result["name"];?></option>
                <?PHP
						}
				?>
              </select>
            </strong></td>
          </tr>
          <tr>
            <td bgcolor="#006699"><strong>คุณต้องการปิด 
              Event หรือไม่?</strong></td>
            <td><strong>
              <label>
                <input type="radio" name="End" value="y" id="End_0" />
                ใช่</label>
              <br />
              <label>
                <input name="End" type="radio" id="End_1" value="n" checked="checked" />
            ไม่ใช่</label>
            </strong></td>
          </tr>
        </table>
        <strong><br />
        </strong>
        <table width="60%" border="0" align="center">
          <tr>
            <td><strong>
              <input type="submit" name="button" id="button" value="Submit" />
              <input type="reset" name="button2" id="button2" value="Reset" /> 
              <input type="button" class="button" value="กลับ" onclick="gohome()" />
            </strong></td>
          </tr>
      </table></td>
    </tr>
  </table>
  <p>&nbsp;</p>
  <p>&nbsp;</p>
</form>
</body>
<script>
function gohome(){

document.location.href='sat_list.php';
}
</script>
</html>




Tag : PHP, MySQL







Move To Hilight (Stock) 
Send To Friend.Bookmark.
Date : 2018-11-26 09:47:54 By : arm_s View : 540 Reply : 5
 

 

No. 1



โพสกระทู้ ( 9,556 )
บทความ ( 2 )



สถานะออฟไลน์


ไม่ทราบ เป็น multi user หรือเปล่าครับ

ถ้าเป็น multi user ไม่ต้องแสดงเลข running number ในขณะ insert เพราะอาจจะได้หมายเลขไม่ตรงกัน อยู่ที่ใครเซฟก่อน
หรือ ระยะเวลาทำงาน ข้ามวันข้ามคืน หรือเปล่า

ใช้วิธีการ กำหนดค่าให้ขณะ insert เข้า database ครับ

ลิ่งค์ข้างล่างตัวอย่างการคิวรี่
https://www.thaicreate.com/community/sql-knowledge-base/view.html






แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2018-11-26 12:21:16 By : Chaidhanan
 


 

No. 2



โพสกระทู้ ( 39 )
บทความ ( 0 )



สถานะออฟไลน์


ตอบความคิดเห็นที่ : 1 เขียนโดย : Chaidhanan เมื่อวันที่ 2018-11-26 12:21:16
รายละเอียดของการตอบ ::
จริงๆ เพื่ออยากให้คนที่คีย์ข้อมุล รู้ว่าเป็น event ที่เท่าไรของสัปดาห์น่ะครับ เป็นห้องที่ไว้รับข้อมุล แล้วก็ให้ใครคนใดคนนึงคีย์ข้อมูลเข้าครับ

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2018-11-26 13:28:36 By : arm_s
 

 

No. 3



โพสกระทู้ ( 9,556 )
บทความ ( 2 )



สถานะออฟไลน์


เอาเป็นบอกว่า รหัสสุดท้ายเป็นเท่าไหร่ แต่อย่าให้เข้าใจว่าเป็น หมายเลขที่จะทำ เพราะจะเข้าใจผิด
เวลามีปัญหาไปค้นหา ผิดรายการ คนเขียนโปรแกรมต้องเพื่อเหตุการณ์ต่างๆ ไว้ด้วย

ก็แค่คิวรี่หา ค่า MAX มาแสดง เท่านั้นครับ

Code (SQL)
select t.week_id, max(coalesce(t.week_no, 0)) as last_num 
form (select $target_week as id) as x
left join tablename as t on t.week_id=x.id



ประวัติการแก้ไข
2018-11-26 13:53:38
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2018-11-26 13:50:58 By : Chaidhanan
 


 

No. 4



โพสกระทู้ ( 39 )
บทความ ( 0 )



สถานะออฟไลน์


ถ้าผมใช้ code นี้

Code (PHP)
        <input type="text" name="NoWeek" id="NoWeek" size="5" value="<?php
					$Query = mysql_query('SELECT count(*) as cn FROM sat WHERE Week="49" ') or die('Error query #12');
					//$nrow = mysql_num_rows($Query);
					$Result = mysql_fetch_array($Query);
					if ($Result['cn']==0){
							echo "1";
						} else {
					      
							echo $Result['cn']+1;
			
						}
			         ?> 



ผมจะดึงค่า week จากตรงนี้มาใช้ได้มั้ยครับ

Code (JavaScript)
<script type="text/javascript">

        $(document).ready(function () {

                // 2. เซ็ทวันที่ใส่ Date onject
                var dt = new Date();

                // 3. เรียก function เพื่อหาสัปดาห์ที่เท่าไรของเดือน
                var week_no = dt.getWeekOfYear();

                // แสดงค่าใน textbox 02
                $('#Week').val(week_no);
            });

     

        Date.prototype.getWeekOfYear = function () {
            var onejan = new Date(this.getFullYear(), 0, 1);
            var today = new Date(this.getFullYear(), this.getMonth(), this.getDate());
            var dayOfYear = ((today - onejan + 86400000) / 86400000);
            return Math.ceil(dayOfYear / 7)
        };

</script>


เหมือนจะมีคนถามแล้ว แต่ผมก็ยัง งงๆ กับตรงนี้อยู่น่ะครับ
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2018-11-26 15:44:40 By : arm_s
 


 

No. 5



โพสกระทู้ ( 5,105 )
บทความ ( 4 )

สมาชิกที่ใส่เสื้อไทยครีเอท Hall of Fame 2012

สถานะออฟไลน์


ลองประยุกต์ช่องทางจากตัวนี้ จะเป็นปีลองตัดให้ได้ช่วงสัปดาห์
https://www.thaicreate.com/community/php-auto-generate-number-alt.html
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2018-11-26 16:44:49 By : apisitp
 

   

ค้นหาข้อมูล


   
 

แสดงความคิดเห็น
Re : รบกวนขอคำแนะนำครับ ต้องการ รันเลขใหม่ทุกครั้งที่เปลี่ยน เลขสัปดาห์ครับ
 
 
รายละเอียด
 
ตัวหนา ตัวเอียง ตัวขีดเส้นใต้ ตัวมีขีดกลาง| ตัวเรืองแสง ตัวมีเงา ตัวอักษรวิ่ง| จัดย่อหน้าอิสระ จัดย่อหน้าชิดซ้าย จัดย่อหน้ากึ่งกลาง จัดย่อหน้าชิดขวา| เส้นขวาง| ขนาดตัวอักษร แบบตัวอักษร
ใส่แฟลช ใส่รูป ใส่ไฮเปอร์ลิ้งค์ ใส่อีเมล์ ใส่ลิ้งค์ FTP| ใส่แถวของตาราง ใส่คอลัมน์ตาราง| ตัวยก ตัวห้อย ตัวพิมพ์ดีด| ใส่โค้ด ใส่การอ้างถึงคำพูด| ใส่ลีสต์
smiley for :lol: smiley for :ken: smiley for :D smiley for :) smiley for ;) smiley for :eek: smiley for :geek: smiley for :roll: smiley for :erm: smiley for :cool: smiley for :blank: smiley for :idea: smiley for :ehh: smiley for :aargh: smiley for :evil:
Insert PHP Code
Insert ASP Code
Insert VB.NET Code Insert C#.NET Code Insert JavaScript Code Insert C#.NET Code
Insert Java Code
Insert Android Code
Insert Objective-C Code
Insert XML Code
Insert SQL Code
Insert Code
เพื่อความเรียบร้อยของข้อความ ควรจัดรูปแบบให้พอดีกับขนาดของหน้าจอ เพื่อง่ายต่อการอ่านและสบายตา และตรวจสอบภาษาไทยให้ถูกต้อง

อัพโหลดแทรกรูปภาพ

Notice

เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ
อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง

   
  เพื่อความปลอดภัยและการตรวจสอบ กระทู้ที่แทรกไฟล์อัพโหลดไฟล์จากที่อื่น อาจจะถูกลบทิ้ง
 
โดย
อีเมล์
บวกค่าให้ถูก
<= ตัวเลขฮินดูอารบิก เช่น 123 (หรือล็อกอินเข้าระบบสมาชิกเพื่อไม่ต้องกรอก)







Exchange: นำเข้าสินค้าจากจีน, Taobao, เฟอร์นิเจอร์, ของพรีเมี่ยม, ร่ม, ปากกา, power bank, แฟลชไดร์ฟ, กระบอกน้ำ

Load balance : Server 04
ThaiCreate.Com Logo
© www.ThaiCreate.Com. 2003-2024 All Rights Reserved.
ไทยครีเอทบริการ จัดทำดูแลแก้ไข Web Application ทุกรูปแบบ (PHP, .Net Application, VB.Net, C#)
[Conditions Privacy Statement] ติดต่อโฆษณา 081-987-6107 อัตราราคา คลิกที่นี่