Comments (11)
from tad-php.
can any one help me please
from tad-php.
from tad-php.
I have wirking code i will share it with you
…
On Thu, 31 Jan 2019, 1:31 pm haseebhk22 @.*** wrote: can any one help me please — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#70 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w57LZjdYHEUhXpkyf-lMt7cAhZYBiks5vIqnNgaJpZM4abzx1 .
yes please i will be thankful if you share your working code
from tad-php.
require 'vendor/autoload.php'; require 'tad/lib/TADFactory.php'; require 'tad/lib/TAD.php'; require 'tad/lib/TADResponse.php'; require 'tad/lib/TADPHP/Providers/TADSoap.php'; require 'tad/lib/TADPHP/Providers/TADZKLib.php'; require 'tad/lib/TADPHP/Exceptions/ConnectionError.php'; require 'tad/lib/TADPHP/Exceptions/FilterArgumentError.php'; require 'tad/lib/TADPHP/Exceptions/UnrecognizedArgument.php'; require 'tad/lib/TADPHP/Exceptions/UnrecognizedCommand.php'; use TADPHP\TADFactory; use TADPHP\TAD; try { $tad = (new TADFactory(['ip' => '182.180.150.260','com_key'=>0]))->get_instance(); if($tad->is_alive()) { //$tad->disable(); $att_logs = $tad->get_att_log(); $att_logs=$att_logs->filter_by_date(['start' => date('Y-m-d'),'end' => date('Y-m-d')]); if ($att_logs->is_empty_response()) { my_log('Does not have logs recorded'); //continue; } else { $array_att_logs = $att_logs->to_array(); $device_logs = array(); $counter=1; if(!empty($array_att_logs)) foreach($array_att_logs as $key =>$val ) { foreach($val as $log) { $device_logs[]= array( 'institutes_inst_id' => $row['inst_id'], 'employees_machine_user_id' => $log['PIN'], 'date' => date('Y-m-d',strtotime($log['DateTime'])), 'time' => date('H:i:s',strtotime($log['DateTime'])) ); $counter++; } } add_att_logs($device_logs); //$tad->enable(); my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] has ' . $counter . ' records'); } } else { my_log('Device in ' . $row['inst_name'] . ' is off-line'); continue; } } catch(Exception $e) { my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] is offline'); }
…
On Thu, Feb 7, 2019 at 3:07 PM Haseeb khan @.> wrote: I have wirking code i will share it with you … <#m_-7494239903006511939_> On Thu, 31 Jan 2019, 1:31 pm haseebhk22 @. wrote: can any one help me please — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#70 (comment) <#70 (comment)>>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w57LZjdYHEUhXpkyf-lMt7cAhZYBiks5vIqnNgaJpZM4abzx1 . yes please i will be thankful if you share your working code — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#70 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w5zt_dSgUfEiv1Mh-FpaYJpla4HB0ks5vK_rWgaJpZM4abzx1 .
Thanks for sharing code but where is vedor/autoload.php this file is not exist
from tad-php.
from tad-php.
you have to download it from github On Mon, Feb 11, 2019 at 11:33 AM Haseeb khan [email protected] wrote:
…
require 'vendor/autoload.php'; require 'tad/lib/TADFactory.php'; require 'tad/lib/TAD.php'; require 'tad/lib/TADResponse.php'; require 'tad/lib/TADPHP/Providers/TADSoap.php'; require 'tad/lib/TADPHP/Providers/TADZKLib.php'; require 'tad/lib/TADPHP/Exceptions/ConnectionError.php'; require 'tad/lib/TADPHP/Exceptions/FilterArgumentError.php'; require 'tad/lib/TADPHP/Exceptions/UnrecognizedArgument.php'; require 'tad/lib/TADPHP/Exceptions/UnrecognizedCommand.php'; use TADPHP\TADFactory; use TADPHP\TAD; try { $tad = (new TADFactory(['ip' => '182.180.150.260','com_key'=>0]))->get_instance(); if($tad->is_alive()) { //$tad->disable(); $att_logs = $tad->get_att_log(); $att_logs=$att_logs->filter_by_date(['start' => date('Y-m-d'),'end' => date('Y-m-d')]); if ($att_logs->is_empty_response()) { my_log('Does not have logs recorded'); //continue; } else { $array_att_logs = $att_logs->to_array(); $device_logs = array(); $counter=1; if(!empty($array_att_logs)) foreach($array_att_logs as $key =>$val ) { foreach($val as $log) { $device_logs[]= array( 'institutes_inst_id' => $row['inst_id'], 'employees_machine_user_id' => $log['PIN'], 'date' => date('Y-m-d',strtotime($log['DateTime'])), 'time' => date('H:i:s',strtotime($log['DateTime'])) ); $counter++; } } add_att_logs($device_logs); //$tad->enable(); my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] has ' . $counter . ' records'); } } else { my_log('Device in ' . $row['inst_name'] . ' is off-line'); continue; } } catch(Exception $e) { my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] is offline'); } … <#m_8444458323558097279_> On Thu, Feb 7, 2019 at 3:07 PM Haseeb khan @.> wrote: I have wirking code i will share it with you … <#m_-7494239903006511939_> On Thu, 31 Jan 2019, 1:31 pm haseebhk22 @. wrote: can any one help me please — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <#70 <#70> (comment) <#70 (comment) <#70 (comment)>>>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w57LZjdYHEUhXpkyf-lMt7cAhZYBiks5vIqnNgaJpZM4abzx1 . yes please i will be thankful if you share your working code — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#70 (comment) <#70 (comment)>>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w5zt_dSgUfEiv1Mh-FpaYJpla4HB0ks5vK_rWgaJpZM4abzx1 . Thanks for sharing code but where is vedor/autoload.php this file is not exist — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#70 (comment)>, or mute the thread https://github.com/notifications/unsubscribe-auth/AA5w56c8SBq16KrwJfhPd3A8UVEmw1Prks5vMQ7AgaJpZM4abzx1 .
sir i already download from github but in the folder the vendor folder or autoload.php not exist
from tad-php.
Run this on tad folder php composer.phar dump-autoload to create autoload file
from tad-php.
Run this on tad folder php composer.phar dump-autoload to create autoload file
Sir I have done this now in your code that you provide , I change the ip address but result is the same no connection is made :
Here is my code :
`<?php
require 'vendor/autoload.php';
require 'lib/TADFactory.php';
require 'lib/TAD.php';
require 'lib/TADResponse.php';
require 'lib/Providers/TADSoap.php';
require 'lib/Providers/TADZKLib.php';
require 'lib/Exceptions/ConnectionError.php';
require 'lib/Exceptions/FilterArgumentError.php';
require 'lib/Exceptions/UnrecognizedArgument.php';
require 'lib/Exceptions/UnrecognizedCommand.php';
use TADPHP\TADFactory;
use TADPHP\TAD;
try {
$tad = (new TADFactory(['ip' =>
'MY.IP.ADDRESS','com_key'=>0]))->get_instance();
if($tad->is_alive())
{
echo "done";exit();
//$tad->disable();
$att_logs = $tad->get_att_log();
print_r($att_logs);exit();
$att_logs=$att_logs->filter_by_date(['start' => date('Y-m-d'),'end' =>
date('Y-m-d')]);
if ($att_logs->is_empty_response())
{
my_log('Does not have logs recorded');
//continue;
}
else
{
$array_att_logs = $att_logs->to_array();
$device_logs = array();
$counter=1;
if(!empty($array_att_logs))
foreach($array_att_logs as $key =>$val )
{
foreach($val as $log)
{
$device_logs[]= array(
'institutes_inst_id' => $row['inst_id'],
'employees_machine_user_id' => $log['PIN'],
'date' => date('Y-m-d',strtotime($log['DateTime'])),
'time' => date('H:i:s',strtotime($log['DateTime']))
);
$counter++;
}
}
add_att_logs($device_logs);
//$tad->enable();
my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] has ' .
$counter . ' records');
}
}
else
{
echo "not";exit();
my_log('Device in ' . $row['inst_name'] . ' is off-line');
continue;
}
}
catch(Exception $e)
{
my_log('Device in ' . $row['inst_name']. '['.$row['ip_address']. '] is
offline');
}
?>`
from tad-php.
@zkenstein
Sir my attendance machine is running and the Zk software is successfully connected to the machine and I can get all the attendance but when i use TAD class there is always connection problem . Can you help me what is the reason ??
from tad-php.
@zkenstein
When i run your code i got this error :
Fatal error: Call to undefined function my_log() in C:\wamp64\www\tad_php\index.php on line 62
from tad-php.
Related Issues (20)
- How to get the card (badge) capacity, stored and available count?
- Date Range Get Attendance HOT 5
- Imposible conectar con el dispositivo - ZKTECO SF200 HOT 1
- Device soap connection doesn't allow storing of cards above 2147483647
- Connection Error
- Open Interface Through API
- Unable to start connection with device 92.168.*.*** HOT 4
- is there any way to get users count? HOT 1
- Cannot set soap port other than 80
- Fingerprint x100-x cant write template HOT 2
- Imposible iniciar conexión con dispositivo
- multiple set_user_info call issue
- Problem composer HOT 1
- set_user_info
- List of supported and test devices HOT 3
- How can i install TAD php on laravel?? HOT 3
- dump-autoload error
- this work for SC105 ZKteco ? HOT 1
- Update user's attendance time
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from tad-php.