function voidQuery($query) { global $connect; global $aacQueries; $aacQueries++; global $accQueriesData; $accQueriesData[] = "[" . elapsedTime() . "] " . $query; mysqli_query($connect, $query) or die(var_dump($query) . "<br>(query - <font color='red'>SQL error</font>) <br>Type: <b>voidQuery</b> (voidQuery is used for update, insert or delete from database)<br><br>" . mysqli_error($connect)); }
<div id="scroll"> <a title="Scroll to the top" class="top" href="#"><img src="layout/images/top.png" alt="top" /></a> </div> <footer> <p>© <?php echo $config['site_title']; ?> . <?php echo 'Server date and clock is: ' . getClock(false, true) . ' Page generated in ' . elapsedTime() . ' seconds. Q: ' . $aacQueries; ?> <a href="http://www.css3templates.co.uk">Design: css3templates.co.uk</a>. Engine: <a href="credits.php">Znote AAC</a></p> </footer>
?> " alt="feed image"> <?php } ?> <!-- feed text --> <?php if (isset($f['feed_text']) && !empty($f['feed_text'])) { ?> <div class='user-block' style="margin-bottom:5px;"> <span class='username2' style="display:inline-block"><a href="#"><?php echo $f['feed_fullname']; ?> </a></span> <span class='description2' style="display:inline-block"><i class="fa fa-clock-o"></i> <?php echo elapsedTime($f['feed_time']); ?> </span> </div><!-- /.user-block --> <p style="padding:10px; background:#F4F4F4"><?php echo $f['feed_text']; ?> </p> <?php } ?> </div> </div> <input type="hidden" name="f_id" value="<?php echo $f['feed_id'];
?> </textarea> <?php if (!empty($this->data->rows)) { // If there are any processed data rows... ?> <div class="right"> <small> Generate <?php echo count($this->data->rows); // Count of data rows ?> queries took <?php echo round(elapsedTime(), 3); // Elapsed time from script start ?> seconds. </small> </div> <?php } ?> <br /> <div class="center"> <div class="btn btn-default" onclick="$('#sql-output').select();">
<?php $now = time(); $then = time() - 7 * 24 * 60 * 60 + 3 * 60 * 60 + 24 * 60 - 24; echo $now . "<br>" . $then . "<br>"; require '../php/btdb-functions.php'; $time = elapsedTime($then, $now); echo $time["days"] . "<br>"; echo date('Y-m-d h:i:s', time());
/** * Returns an array of report data * * @param $data * @return array */ public static function reportFormat($data) { $arr = array(KeyParser::id => $data->id, KeyParser::type => $data->type, KeyParser::type_id => $data->type_id, KeyParser::reason => $data->reason, KeyParser::report_status => $data->report_status, KeyParser::reported_by => $data->reported_by, KeyParser::date_created => elapsedTime($data->date_created), KeyParser::modified_by => $data->modified_by, KeyParser::date_modified => elapsedTime($data->date_modified)); return $arr; }
echo "no"; } } if (isset($_GET['read_stream']) && isset($_GET['id'])) { $stream_id = $_GET['id']; $user_id = $_SESSION['logged']; $data = array(); $sources = array(); $q = mysqli_query($conn, "select * from stream where id={$stream_id}"); if ($q) { $r = mysqli_fetch_assoc($q); $id = $r['id']; $name = $r['name']; $status = $r['status']; $created = $r['created']; $created = elapsedTime($created); $qs = mysqli_query($conn, "select src.id, src.type, src.url from source as src join sourcetostream as sts join stream as s on sts.stream=s.id and sts.source=src.id where s.id={$stream_id}"); if ($qs) { while ($rs = mysqli_fetch_assoc($qs)) { $src_id = $rs['id']; $src_type = $rs['type']; $src_url = $rs['url']; switch ($src_type) { case 0: $src_type = "Facebook"; break; case 1: $src_type = "Twitter"; break; } $src_rec = array("id" => $src_id, "type" => $src_type, "url" => $src_url);
} if (isset($_GET['load_more'])) { $l_id = $_GET['l_id']; $data = array(); $q = mysqli_query($conn, "select *, s.id as sid, u.uname, c.name as cat from shule as s join pic as p join user as u join cat as c on s.author=u.id and s.cover=p.id and s.category=c.id where s.id<{$l_id} and s.status=1 order by s.id desc limit 6"); $qt = mysqli_query($conn, "select id from shule"); $tot_r = mysqli_num_rows($qt); while ($r = mysqli_fetch_assoc($q)) { $id = $r['sid']; $title = $r['title']; $cover = $r['src']; $intro = $r['body']; $published = $r['created']; $author = $r['uname']; $category = $r['cat']; $published = elapsedTime($published); $intro = trunc($intro, 25, $id); $rec = array("id" => $id, "title" => $title, "cover" => $cover, "intro" => $intro, "published" => $published, "author" => $author, "category" => $category, "tot_r" => $tot_r); array_push($data, $rec); } echo json_encode($data); } if (isset($_GET['fetch_ad'])) { $data = array(); $q = mysqli_query($conn, "select *, a.id as aid from ad as a join pic as p on a.pic=p.id where a.status=1 order by a.id desc limit 5"); while ($r = mysqli_fetch_assoc($q)) { $id = $r['aid']; $title = $r['title']; $pic = $r['src']; $descr = $r['descr']; $exl = $r['exl'];
/** * Get infos about this apps * * @return Array */ public function getInfos($start, $limit) { $am = AccountManager::getInstance(); $project = $am->project; $infos = array(); $s = 'SELECT count(*) as total FROM `staticValue` WHERE `project` = "%s" AND `type`="info"'; $params = array($am->project); $r = $this->conn->query($s, $params); $a = $r->fetch_assoc(); $infos['total'] = $a['total']; $s = 'SELECT `field`, `value`, `date` FROM `staticValue` WHERE `project` = "%s" AND `type`="info" ORDER BY `date` DESC LIMIT %d, %d'; $params = array($am->project, (int) $start, (int) $limit); $r = $this->conn->query($s, $params); $i = 0; while ($a = $r->fetch_assoc()) { $infos['value'][$i]['id'] = $i; $infos['value'][$i]['field'] = $a['field']; $infos['value'][$i]['value'] = json_decode($a['value']); $infos['value'][$i]['date'] = $a['date']; $infos['value'][$i]['elapsedTime'] = elapsedTime($a['date'], @date("Y-m-d H:i:s")); $i++; } return $infos; }
<script type="text/javascript" src="/js/jquery.popupWindow.js"></script> </head> <?php require '../../php/btdb-functions.php'; require '../../php/config.php'; $testid = $_GET["testid"]; $con = dbconnect($SERVER, $USER, $PASSWD, $DB_NAME); // get cell profile data // get records $sql = "SELECT * FROM {$CELL_RECORDS_TABLE} WHERE id='{$testid}'"; $result = mysql_query($sql); $data = readData($result); $starttime = timeOfDay($data[0]["start_time"]); $endtime = timeOfDay($data[0]["end_time"]); $time = elapsedTime($data[0]["start_time"], $data[0]["end_time"]); echo "Test No. " . $data[0]["id"]; ?> <table> <tr> <td>Test Name </td><td><?php echo $data[0]["action"]; ?> </td> </tr> <tr> <td>Test Engineer </td><td><?php echo $data[0]["engineer"]; ?> </td>