$user = 'u1';
$dbtable = 'vhosts_kp';
$list = mysqli_query ($connection, "SELECT name FROM $dbtable WHERE userid = '$user' ");
$listarr = mysqli_fetch_array ($list);
<select>
<?php foreach ( $listarr as $key => $value ) {
if ($key == 'name') {
echo "<option>$value</option>";
}
}
?>
</select>
print_r ($listarr);
<VirtualHost 127.0.0.1:8080>
ServerName zaglushka.ru
DocumentRoot /var/www/xxx/data/www/zaglushka.ru
ServerAdmin webmaster@zaglushka.ru
AddDefaultCharset UTF-8
php_value upload_max_filesize 10M
AssignUserID danila_p danila_p
CustomLog /var/www/httpd-logs/zaglushka.ru.access.log combined
ErrorLog /var/www/httpd-logs/zaglushka.ru.error.log
<FilesMatch "\.ph(p[3-5]?|tml)$">
SetHandler application/x-httpd-php5
</FilesMatch>
ScriptAlias /php-bin/ /var/www/php-bin-isp-php70/danila_p/
AddHandler application/x-httpd-php5 .php .php3 .php4 .php5 .phtml
Action application/x-httpd-php5 /php-bin/php
ServerAlias www.nn.ru www.zaglushka.ru
DirectoryIndex index.html
ServerAlias 37.46.131.31
</VirtualHost>
<Directory /var/www/xxx/data/www/zaglushka.ru>
Options +Includes -ExecCGI
</Directory>