Opened 5 years ago
Closed 5 years ago
#1485423 closed Bugs (fixed)
Not work "virtuser_query"
| Reported by: | landy | Owned by: | |
|---|---|---|---|
| Priority: | 5 | Milestone: | 0.2-stable |
| Component: | PHP backend | Version: | git-master |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Sorry for bad english.
We use exim 4.69 + mysql 5.1.28 (for usertables).
System FreeBSD 7.0 i386
Roundcube not get good identities from DB.
Config in config/main.inc.php:
$rcmail_config['virtuser_query'] = "SELECT exim.alias.address FROM exim.alias, exim.box WHERE exim.box.login = '%u' AND exim.box.box_id=exim.alias.box LIMIT 0,1";
in error log we get this:
[29-Sep-2008 16:57:34] PHP Warning: mysqli_query() [<a href='function.mysqli-query'>function.mysqli-query</a>]: Empty query in /usr/local/www/roundcube/program/lib/MDB2/Driver/mysqli.php on line 770 [29-Sep-2008 16:57:34] MDB2 Error: unknown error (-1): _doQuery: [Error message: Could not execute statement] [Native code: 0]
in identities adding mail adresses like this: user@localhost
We add this line in file "program/include/rcube_user.php":
$virtuser_query = $rcmail->config->get('virtuser_query');
before this:
// try to resolve the e-mail address from the virtuser table
if ($virtuser_query = $rcmail->config->get('virtuser_query') &&
($sql_result = $dbh->query(preg_replace('/%u/', $dbh->escapeSimple($user), $virtuser_query))) &&
($dbh->num_rows() > 0))
then all work fine fom me.
Change History (2)
comment:1 Changed 5 years ago by alec
- Component changed from Core functionality to PHP backend
- Milestone changed from later to 0.2-stable
comment:2 Changed 5 years ago by alec
- Resolution set to fixed
- Status changed from new to closed
Note: See
TracTickets for help on using
tickets.

Fixed in [123a02c8].