当前位置: 首页>>代码示例>>PHP>>正文


PHP getdbDate函数代码示例

本文整理汇总了PHP中getdbDate函数的典型用法代码示例。如果您正苦于以下问题:PHP getdbDate函数的具体用法?PHP getdbDate怎么用?PHP getdbDate使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了getdbDate函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: alert

        ?>
<script>
                                                        alert("PLz Select file");
                                            </script>
                                            <?php 
        return false;
    }
    $type = explode(".", $_FILES['filename']['tmp_name']);
    if (strtolower(end($type)) != 'csv') {
        echo "Plz enter csv file";
        return false;
    } else {
        echo $handle = fopen($_FILES['filename']['tmp_name'], "r");
        while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) {
            if (!empty($data[34])) {
                $date = getdbDate($data[34]);
                $date = str_replace("/", "-", $date);
                $date = explode("-", $date);
                echo $year = $date[0];
                echo $month = $date[1];
            }
            $sql1 = "SELECT `emp_id` FROM `mpc_employee_master` WHERE `ticket_no` = {$data['1']}";
            $result = mysql_query($sql1) or die(mysql_error());
            if (mysql_num_rows($result) > 0) {
                $row = mysql_fetch_array($result);
                $empid = $row[0];
                $j = 1;
                for ($c = 3; $c < 34; $c++) {
                    echo $status = $data[$c];
                    echo $date = $year . '-' . $month . '-' . $j;
                    $j++;
开发者ID:ViShNuPrAtap,项目名称:lss,代码行数:31,代码来源:monthly.php

示例2: mysql_query

			emp_id = '$emp_id',
			skills_name = '$skill_name',
			experience = '$experience'";
																				
		$result_family_education = mysql_query($sql_insert_education) or die("Error in query:".$sql_insert_education."<br>".mysql_error()."<br>".mysql_errno());
			*/

if(isset($_POST['emp_offical']))
{
	if($_POST['no_refresh'] == $_SESSION['no_refresh'])
	{	
	  //echo "WARNING: Do not try to refresh the page.";
	}
	else
	{	
	    $date_joining = getdbDate($_POST['date_joining']);
		$plant_name = $_POST['plant_name'];
		$department = $_POST['department'];
		$sub_department = $_POST['sub_department'];
		$grade = $_POST['grade'];
		$authority_name = $_POST['authority_name'];
		$pan_no = $_POST['pan_no'];
		$emp_type = $_POST['emp_type'];
		$emp_category = $_POST['emp_category'];
		$designation = $_POST['designation'];
		$emp_id=$_POST['emp_id'];
		$pf_no=$_POST['pf_no'];
		$pf_rate=$_POST['pf_rate'];
		$date_pf=$_POST['date_pf'];
		$pf_nominee=$_POST['pf_nominee'];
		$pf_relationship=$_POST['pf_relationship'];
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:employee_detail.php

示例3: getdbDate

                  $mode   = 'personal_detail';
              }
          }
          if (isset($_POST['emp_family'])) {

              if ($_POST['no_refresh'] == $_SESSION['no_refresh']) {                  
              } else {
                        $father_name        = $_POST['father_name'];
                        $Dependant_member1  = $_POST['Dependant_member1'];
                        $mother_name        = $_POST['mother_name'];
                        $Dependant_member2  = $_POST['Dependant_member2'];
                        $father_dob         = $_POST['father_dob'];
                        $mother_dob         = getdbDate($_POST['mother_dob']);
                        $wife_name          = $_POST['wife_name'];
                        $Dependant_member3  = $_POST['Dependant_member3'];
                        $wife_dob           = getdbDate($_POST['wife_dob']);
                        if (isset($_POST['child_name'])) {
                        }
                        $child_name   = $_POST['child_name'];
                        $count        = count($child_name);
                        $child_name   = implode(",", $child_name);
                        $child_dob    = $_POST['child_dob'];
                        
                        for ($i = 0; $i < $count; $i++) {
                            $child_dependent[] = $_POST['child_dependent' . $i][0];
                        }

                        $child_dependent = implode(",", $child_dependent);
                        for ($i = 0; $i < $count; $i++) {
                            $child_gender[] = $_POST['child_gender' . $i][0];
                        }
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:User_details.php

示例4: if

      else
      {
          $salary_basic=($total_salary_basic/31)/8;
      }
  $good_work=getGoodWorkBydate($emp_id,getdbDate($month));
  if($good_work!="")
  {
   ?>
 <tr <? if ($sno%2==1) { ?> bgcolor="#F8F8F8" <? } ?> class="tableTxt">
  <td width="5%" align="center"><?=$sno?></td>
  <td width="5%" align="center"><?=$row['ticket_no']?></td>
  <td width="5%" align="left">
  <?=$row['first_name']?> <?=$row['last_name']?><br/>
  </td>
  <td> 
      <?=getdesignationMaster('designation_name','rec_id',getdesignationDetail('designation_id',$emp_id,getdbDate($month)));?>  	
  </td>
      <td>
          <?=$total_salary_basic?></td>
      <td>
          <?=$good_work?>
      </td>
       <td>
          <?	
              $good_work=explode(':',$good_work);
              $good_work_hour=$good_work[0];
              $net_pay=$salary_basic*$good_work[0];
              if($good_work[1]=="30")
              {
                  $net_pay=$net_pay+($salary_basic/2);
              }
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:print_good_work_payment.php

示例5: getdbDate

                                </tr>
                                <tr>
    		                        <td class="text_1">To Date</td>
                                        <td align="left"><input type="text" name="ToDate" id="ToDate" style="width:150px; height:20px;" value="" data-beatpicker="true" /></td>
                                </tr>
                                <tr>
                                	<td>
                                    	<input type="submit"  value="Submit" name="btn_submit" id="btn_submit"/>
                                    </td>
                                </tr>
                            </table>
                        </form>
                        <?php 
if (isset($_POST['btn_submit'])) {
    $FromDate = getdbDate($_POST['FromDate']);
    $ToDate = getdbDate($_POST['ToDate']);
    include "inc/dbconnection.php";
    ?>
<div style="overflow:scroll;height:300px;">
<table border="0" align="center" width="100%" style="overflow-y:scroll;" class="border">
					<tbody><tr class="blackHead">
					   <td align="center" width="6%">Employee Id</td>
					   <td align="center" width="7%">Insert Date</td>
                       <td align="center" width="8%">Employee Name</td>
					   <td align="center" width="21%">AttandanceStatus</td>
					   						<td align="center" width="19%">Shift</td>
						
				 <?php 
    /* $que = mysql_query("SELECT mpc_attendence_master.*,mpc_employee_master.first_name,mpc_employee_master.last_name
    FROM `mpc_attendence_master` inner join `mpc_employee_master` on mpc_employee_master.emp_id = mpc_attendence_master.emp_id
    WHERE `date` between '$FromDate' and '$ToDate'"); */
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:import_attendance.php

示例6: getdesignationMaster

echo $sno_d;
?>
</td>
			<td width="5%" align="center"><?php 
echo $row['ticket_no'];
?>
<input type="hidden" name="cardNo" id="cardNo" value="<?php 
echo $sno_d;
?>
"  /></td>
			<td width="5%" align="left"><? $empName = $row['first_name'].' '.$row['last_name']?><input type="hidden" name="empName" id="empName" value="<?php 
echo $empName;
?>
"  /><br/></td>
			<td><?php 
echo getdesignationMaster('designation_name', 'rec_id', getdesignationDetail('designation_id', $emp_id, getdbDate($date_upto)));
echo $desig;
?>
<input type="hidden" name="designation" id="designation" value="<?php 
echo $desig;
?>
"  /></td>
			<td><?php 
echo $total_salary_basic;
?>
</td>
			<td><?php 
echo $good_work;
?>
<input type="hidden" name="goodWork" id="goodWork" value="<?php 
echo $good_work;
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:canteenCupon.php

示例7: include

<? include ("inc/dbconnection.php");?>
<? include ("inc/function.php");?>
<?
$date=$_POST['txt_date'];
$db_date=getdbDate($date);
$where_string_sub_department="";

if($_POST["department"]!="")
	{	
		$department=$_POST["department"];
		$where_string_department=" rec_id ='$department'";
	}
	else
	{
		$where_string_department=" reference_id='0'";
	}
if($_POST["sub_department"]!="" and $_POST["department"]!="")
{
	$sub_department=$_POST["sub_department"];	
	$where_string_sub_department="and rec_id ='$sub_department'";
}

if((isset($_POST["employee_type"])!=""))
{	
	$select_string=",mpc_designation_employee.*,mpc_designation_master.*";
	$employee_type=$_POST["employee_type"];
	$table_list= ",mpc_designation_employee,mpc_designation_master";
	$where_string="and mpc_designation_employee.emp_id = mpc_department_employee.emp_id and mpc_designation_employee.designation_id=mpc_designation_master.rec_id and mpc_designation_master.emp_category='$employee_type' and mpc_designation_employee.to_date='0000-00-00'";
}
?>
<?
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:employee_list_report_excel.php

示例8: include

<?php
//if (isset($_POST['mon_submit'])) {
include ("inc/dbconnection.php");
include ("inc/function.php");
//eND OF THE PAGE...
$id = "";
$add_div = "";
$hidden_value = "";
$ticket_id = $_REQUEST['id'];
$type = $_REQUEST['type'];
$to = getdbDate($_REQUEST['str']);
$from = getdbDate($_REQUEST['sdate']);
$from_date = str_replace("/", "-", $from);
$to_date = str_replace("/", "-", $to);
$id = getemployeeDetailByTicket('emp_id', $ticket_id);
$shift = $_GET["shift"];

if (isset($_GET['start'])) {
    if ($_GET['start'] == 'All') {
        echo $start = 0;
    } else {
        echo $start = $_GET['start'];
    }
} else {
    $start = 0;
}
$day = substr($_GET["str"], 0, 2);
$month = substr($_GET["str"], 3, 2);
$year = substr($_GET["str"], 6, 4);
$weekly_day = date("l", mktime(0, 0, 0, $month, $day, $year));
$holiday = getHoliday('holiday_name', $date);
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:get_employee_list_monthly.php

示例9: include

<? include ("inc/hr_header.php"); ?>
<?
$date="";
?>
<?
////////////////////// Markin attendence //////////////
if(isset($_POST['btn_attend']))
{

$emp_id=$_POST['emp_id'];
$txt_date=getdbDate($_POST['txt_date']);
$ip = $_SERVER['REMOTE_ADDR'];
$i=1;
	foreach($emp_id as $id)
	{	
	 $id;	
	 $hr=$_POST['fldHour_'.$i];
	 $min=$_POST['fldMin_'.$i];
	 
	 $hr_out=$_POST['out_Hour_'.$i];
	 $min_out=$_POST['out_Min_'.$i];

	 
	 $status=$_POST['attendace'.$id];
	 
	 $good_work=$_POST['good_work_'.$id];
	 $sec="00";
	 
	 
	 
	 $time=$hr.":".$min.":".$sec;
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:mark_attendance_back.php

示例10: getdbDate

$date = "";
?>
<script type="text/javascript" src="javascript/form.js"></script>
<script type="text/javascript" src="javascript/popup.js"></script>
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.4.2/jquery.mobile-1.4.2.min.css">
<script src="http://code.jquery.com/jquery-1.10.2.min.js"></script>
<script src="http://code.jquery.com/mobile/1.4.2/jquery.mobile-1.4.2.min.js"></script>

<?
////////////////////// Markin attendence //////////////
if (isset($_POST['btn_attend'])) {

    $emp_id = $_POST['emp_id'];
    $emp_name = $_POST['emp_name'];
    echo $txt_date = getdbDate($_POST['txt_date']);
    echo $txt_todate = getdbDate($_POST['txt_todate']);


    $ip = $_SERVER['REMOTE_ADDR'];
    $i = 1;
    foreach ($emp_id as $id) {
        $id;
        $hr = $_POST['fldHour_' . $i];
        $min = $_POST['fldMin_' . $i];
        $hr_out = $_POST['out_Hour_' . $i];
        $min_out = $_POST['out_Min_' . $i];
        $status = $_POST['attendace' . $id];
        $good_work = $_POST['good_work_' . $id];
        $sec = "00";
        $time = $hr . ":" . $min . ":" . $sec;
        $time_out = $hr_out . ":" . $min_out . ":" . $sec;
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:monthly.php

示例11: include

<? include ("inc/dbconnection.php");?>
<? include ("inc/function.php");?>
<?
//header("Content-type: application/vnd.ms-excel");
//header("Content-Disposition: attachment; filename=shift_wise_long_leave_report.xls");
?>
<?
$date=$_POST['txt_date'];
$shift=$_POST['shift_detail'];
$data_date=getdbDate($date);
?>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link href="style/hr_style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<table width="100%" cellpadding="0" cellspacing="0">
	<tr>
    	<td>
        	DEPTT/SHIFT WISE LONG LEAVE REPORT OF DATE:<?=$date?>
        </td>
        <td>
        	SHIFT:<?=$shift?>
        </td>
    </tr>
    <tr>
    	<td colspan="2">
        	<table width="100%">
            	<tr>
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:shift_wise_long_leave_report_excel.php

示例12: while

                                                                <td width="5%" align="center"><b>S.No.</b></td>
                                                                <td width="5%" align="center"><b>Department Name.</b></td>
                                                                <td align="center"><b>Gratuity Amount</b></td>
                                                               
                                                              </tr>
																<?php 
        while ($row = mysql_fetch_array($result_prj)) {
            $total_emp_gratuity = 0;
            $dept_net = 0;
            $sql = "SELECT * FROM mpc_department_employee,mpc_official_detail where to_date='0000-00-00' and dept_id='" . $row['rec_id'] . "' and mpc_department_employee.emp_id=mpc_official_detail.emp_id";
            $result = mysql_query($sql) or die("Error in sql : " . $sql . " : " . mysql_errno() . " : " . mysql_error());
            if (mysql_num_rows($result) > 0) {
                while ($row_dept = mysql_fetch_array($result)) {
                    $total_salary_basic = 0;
                    $emp_id = $row_dept['emp_id'];
                    $total_salary_basic = getSalaryDetail("basic", $emp_id, getdbDate($date_upto));
                    $date2 = $row_dept['date_joining'];
                    $date_result = dateDifference($date_upto, $date2);
                    $date_result['years'];
                    $emp_gratuity = round($total_salary_basic / 26 * 15 * $date_result['years'], 2);
                    $total_emp_gratuity = $total_emp_gratuity + $emp_gratuity;
                }
            }
            ?>
                                                               <tr <?php 
            if ($sno % 2 == 1) {
                ?>
 bgcolor="#F8F8F8" <?php 
            }
            ?>
 class="tableTxt">
开发者ID:ViShNuPrAtap,项目名称:lss,代码行数:31,代码来源:print_gratuity_summary.php

示例13: die

                	<td>
                    	SNO
                    </td>
                    <td>
                    	EMPLOYEE ID
                    </td>
                    <td>
                    	NAME
                    </td>
                    <td>
                    	Good Work
                    </td>
                </tr>	
                <?
				
				$sql_emp = "select mpc_good_work_master.*, mpc_employee_master.rec_id as id,mpc_employee_master.ticket_no,mpc_employee_master.first_name,mpc_employee_master.last_name $select_string from ".$mysql_table_prefix."employee_master,mpc_good_work_master $table_list where mpc_employee_master.rec_id = mpc_good_work_master.emp_id and date='".getdbDate($date)."' and shift='".$shift."' and mpc_good_work_master.good_work!='0:0' $where_string order by ticket_no ASC";
				 
				$result_emp = mysql_query($sql_emp) or die("Error in Query :".$sql_emp."<br>".mysql_error().":".mysql_errno());
				if(mysql_num_rows($result_emp)>0)
						{
							$s=1;
						 while($row_emp=mysql_fetch_array($result_emp))
								{
								?>
								<tr>
                                	<td><?=$s?></td>
                                    <td><?=$row_emp['ticket_no']?></td>
                                	<td>
                                    	<?=$row_emp['first_name']?> <?=$row_emp['last_name']?>
                                   	</td>
                                    <td>
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:shift_wise_good_work.php

示例14: include

<? include ("inc/dbconnection.php");?>
<? include ("inc/function.php");?>
<?
if(isset($_GET['submit']))
{
$id="";
$add_div = "";
$hidden_value = "";
$ticket_id = $_GET["id"];
$type = $_GET["type"];
$date = getdbDate($_GET["str"]);

$date = str_replace("/","-",$date);
$id=getemployeeDetailByTicket('emp_id',$ticket_id);

$shift=$_GET["shift"];
?>
<?
if(isset($_GET['start']))
{
	if($_GET['start']=='All')
	{
		$start = 0;
	}
	else
	{
		$start = $_GET['start'];
	}
}
else
{
开发者ID:shailendra999,项目名称:hr_admin,代码行数:31,代码来源:get_employee_listxz.php

示例15: array

        }
    } else {
        if ($mode == "edit") {
            $tablename = "ms_purchase_company_master";
            $tableColumns = array("company_id", "name", "city");
            $tableData = array("'{$PageKeyValue}'", "'{$name}'", "'{$city}'");
            updateDataIntoTable($tablename, $tableColumns, $tableData);
            $sql_del = "delete from ms_purchase_company_product_master where company_id = '{$PageKeyValue}' ";
            $result_del = mysql_query($sql_del) or die("Error in Query: " . $sql_del . "<br/>" . mysql_error() . "<br/>" . mysql_errno());
            if (isset($_POST['product_id'])) {
                $count = count($_POST['product_id']);
            }
            for ($i = 0; $i < $count; $i++) {
                $product_id = $_POST['product_id'][$i];
                $opening_stock = $_POST['opening_stock'][$i];
                $opening_date = getdbDate($_POST['opening_date'][$i]);
                if ($product_id != "") {
                    $sql_2 = "INSERT INTO  ms_purchase_company_product_master SET\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t   company_id = '{$PageKeyValue}',\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t   product_id = '{$product_id}',\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t   opening_stock = '{$opening_stock}',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t   opening_date = '{$opening_date}',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t   InsertDate = now()";
                    mysql_query($sql_2) or die("Error in query" . mysql_errno() . ":" . mysql_error());
                }
            }
            $Message = "{$PageFor} Updated";
        }
    }
    //redirect("$Page?Message=$Message");
}
$ReferenceId = "";
$product_id = "";
if (isset($_GET["Message"])) {
    $Message = $_GET["Message"];
}
开发者ID:ViShNuPrAtap,项目名称:lss,代码行数:31,代码来源:purchase_add_company.php


注:本文中的getdbDate函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。