root/trunk/gui/include/functions.ticket_system.php

Revision 1327, 1.5 kB (checked in by rats, 4 months ago)

* Fixed: --scan-knownbad-files and --check-deleted are no longer supported by rkhunter
* Fixed #1471: chkrootkit should be in lenny / hardy
* Updated Chinese (simplified)
* Updated German
* Fixed #1475: typo on installation (ispcp-setup)
* Fixed: default user for rkhunter.log

Line 
1 <?php
2 /**
3  * ispCP ω (OMEGA) a Virtual Hosting Control System
4  *
5  * @copyright     2001-2006 by moleSoftware GmbH
6  * @copyright     2006-2008 by ispCP | http://isp-control.net
7  * @version     SVN: $Id$
8  * @link         http://isp-control.net
9  * @author         ispCP Team
10  *
11  * @license
12  *   This program is free software; you can redistribute it and/or modify it under
13  *   the terms of the MPL General Public License as published by the Free Software
14  *   Foundation; either version 1.1 of the License, or (at your option) any later
15  *   version.
16  *   You should have received a copy of the MPL Mozilla Public License along with
17  *   this program; if not, write to the Open Source Initiative (OSI)
18  *   http://opensource.org | osi@opensource.org
19  */
20
21 /**
22  * Gets the last modifikation date of a ticket.
23  *
24  * @author        ispCP Team
25  * @author        Benedikt Heintel
26  * @copyright     2006-2008 by ispCP | http://isp-control.net
27  * @version        1.0
28  *
29  * @access    public
30  * @param     reference    $sql        reference to sql connection
31  * @param    int            $ticket_id    ticket to get last date for
32  * @return     date                    last date
33  */
34 function ticketGetLastDate(&$sql, $ticket_id) {
35     $query = <<<SQL_QUERY
36         SELECT
37             `ticket_date`
38         FROM
39             `tickets`
40         WHERE
41             `ticket_id` = ?
42           OR
43             `ticket_reply` = ?
44         ORDER BY
45             `ticket_date` DESC
46 SQL_QUERY;
47
48     $rs = exec_query($sql, $query, array($ticket_id, $ticket_id));
49
50     $date_formt = Config::get('DATE_FORMAT');
51     $last_date = date($date_formt, $rs->fields['ticket_date']);
52     return $last_date;
53 }
54
55 ?>
Note: See TracBrowser for help on using the browser.