Beispiel #1
0
        'H' => 'H �Դ������Ҵ����͹�Ѻ������ ��ͧ������ѡ�ҷӡ�á����Ե/��ͺ���ª��Ե',
        'I' => 'I �Դ������Ҵ����͹�Ѻ������ ��ͧ������ѡ�Ҷ֧����Ե'
    );

    $date = ad_to_bc(input_get('date'));
    $group = input_get('group');

    $conf = array(
        'host' => 'localhost',
        'port' => 3306,
        'dbname' => 'dbconform',
        'user' => 'root',
        'pass' => '1234'
    );

    $db = Mysql::load($conf);
    $sql = "SELECT a.*, b.`name` 
    FROM `ncr2556` AS a 
    LEFT JOIN `departments` AS b ON b.`code` = a.`until`
    WHERE a.`nonconf_date` LIKE '$date%' 
    AND a.`come_from_id` = '$group' 
    ORDER BY b.`id` ASC";
    $db->select($sql);
    $items = $db->get_items();
	?>
    <style type="text/css">
    td, th{
        padding: 2px;
    }
    </style>
    <div class="col">
Beispiel #2
0
<?php

include 'bootstrap.php';


$action = input('action');


if( $action === false ){

	include 'templates/classic/header.php';

	$db = Mysql::load();
	$sql = "SELECT `row_id`,`name`,`menucode` FROM `inputm` 
	WHERE level = 'user' 
	ORDER BY `name` ASC";
	$db->select($sql);
	$users = $db->get_items();
	?>
	<div class="col">
		<div class="cell">
			<form action="user_durgcontrol.php" method="post">
				<div class="col">
					<div class="cell">
						<select name="user" id="user">
							<option value="">àÅ×Í¡¼Ùéãªé§Ò¹</option>
							<?php
							foreach( $users as $key => $user ){
								?>
								<option value="<?=$user['row_id'];?>"><?=$user['name'];?></option>
								<?php
Beispiel #3
0
 /**
  * @expectedException \PDOException
  */
 public function testConstructThrowsPDOExceptionOnConnection()
 {
     $this->object = new Mysql(array('schema' => 'invalid', 'host' => 'localhost', 'password' => 'invalid', 'user' => 'invalid', 'type' => 'mysql'));
     $meta = $this->object->load('types');
     $this->setExpectedException('\\PDOException');
 }