equal
deleted
inserted
replaced
668 die('host'.$e); |
668 die('host'.$e); |
669 else |
669 else |
670 die('root'.$e); |
670 die('root'.$e); |
671 } |
671 } |
672 $rsp = 'good'; |
672 $rsp = 'good'; |
673 $q = mysql_query('USE '.$dbname, $conn); |
673 $q = mysql_query('USE `' . mysql_real_escape_string($dbname) . '`;', $conn); |
674 if(!$q) |
674 if(!$q) |
675 { |
675 { |
676 $e = mysql_error(); |
676 $e = mysql_error(); |
677 if(strstr($e, 'Unknown database')) |
677 if(strstr($e, 'Unknown database')) |
678 { |
678 { |
701 if(strstr($e, "Lost connection")) |
701 if(strstr($e, "Lost connection")) |
702 die('host'.$e); |
702 die('host'.$e); |
703 else |
703 else |
704 die('auth'.$e); |
704 die('auth'.$e); |
705 } |
705 } |
706 $q = mysql_query('USE '.$dbname, $conn); |
706 $q = mysql_query('USE `' . mysql_real_escape_string($dbname) . '`;', $conn); |
707 if(!$q) |
707 if(!$q) |
708 { |
708 { |
709 $e = mysql_error(); |
709 $e = mysql_error(); |
710 if(strstr($e, 'Unknown database')) |
710 if(strstr($e, 'Unknown database')) |
711 { |
711 { |
1152 <p>If you do not have access to a MySQL server, and you are using your own server, you can download MySQL for free from |
1152 <p>If you do not have access to a MySQL server, and you are using your own server, you can download MySQL for free from |
1153 <a href="http://www.mysql.com/">MySQL.com</a>. <b>Please note that, like Enano, MySQL is licensed under the GNU GPL.</b> |
1153 <a href="http://www.mysql.com/">MySQL.com</a>. <b>Please note that, like Enano, MySQL is licensed under the GNU GPL.</b> |
1154 If you need to modify MySQL and then distribute your modifications, you must either distribute them under the terms of the GPL |
1154 If you need to modify MySQL and then distribute your modifications, you must either distribute them under the terms of the GPL |
1155 or purchase a proprietary license.</p> |
1155 or purchase a proprietary license.</p> |
1156 <?php |
1156 <?php |
1157 if ( file_exists('/etc/enano-is-virt-appliance') ) |
1157 if ( @file_exists('/etc/enano-is-virt-appliance') ) |
1158 { |
1158 { |
1159 echo '<p><b>MySQL login information for this virtual appliance:</b><br /><br />Database hostname: localhost<br />Database login: username "enano", password: "clurichaun" (without quotes)<br />Database name: enano_www1</p>'; |
1159 echo '<p><b>MySQL login information for this virtual appliance:</b><br /><br />Database hostname: localhost<br />Database login: username "enano", password: "clurichaun" (without quotes)<br />Database name: enano_www1</p>'; |
1160 } |
1160 } |
1161 ?> |
1161 ?> |
1162 <form name="dbinfo" action="install.php?mode=website" method="post"> |
1162 <form name="dbinfo" action="install.php?mode=website" method="post"> |