merging awstats branch to trunk, fixes #57, fixes #58

This commit is contained in:
Michael Kaufmann (d00p)
2010-03-22 12:36:59 +00:00
parent d4e310d150
commit 9b843a8ad5
54 changed files with 471 additions and 498 deletions

View File

@@ -0,0 +1,21 @@
<?php
/**
* returns the customer-id of a customer by given domain
*
* @param string $domain users domain
*
* @return int customers id
*/
function getCustomerIdByDomain($domain = null)
{
global $db;
$result = $db->query_first("SELECT `customerid` FROM `" . TABLE_PANEL_DOMAINS . "` WHERE `domain` = '".$domain."'");
if(is_array($result)
&& isset($result['customerid'])
) {
return $result['customerid'];
}
return false;
}