Answers.Body: <p>The real issue is that your database credentials are invalid.</p>
  
  <p><code>Access denied for user 'civicrm'@'localhost' (using password: NO)</code></p>
  
  <p><code>Access denied for user 'drupal'@'localhost' (using password: NO)</code></p>
  
  <p>Most likely the warning you are seeing is due to the connection object being FALSE as a result of not being able to connect, instead of a mysqli connection object.</p>
  
  <p><code>The database: 'drupal' does not exist.</code></p>
  
  <p>You should also at the very least create the <code>drupal</code> and <code>civicrm</code> databases you intend to use; Drupal and CiviCRM's installation will create all the necessary tables.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T18:45:31.793Z
Answers.Text: I tried to create those tables, but the errors still appear to me. Do I need to also manually create/change those users on the phpmyadmin?
Answers.UserDisplayName: CelsomTrindade
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T19:08:00.337Z
Answers.Text: Go to the section titled "Create a database and user using phpMyAdmin" - https://www.drupal.org/docs/7/installing-drupal-7/step-2-create-the-database
Answers.UserDisplayName: user3827
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T19:12:25.537Z
Answers.Text: but i st the first error causing a "no database connection", and with it generating the other errors?
Answers.UserDisplayName: CelsomTrindade
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T19:39:48.260Z
Answers.Text: No, it is the other way around. It is also not an error but a PHP warning.
Answers.UserDisplayName: user3827
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T20:13:45.430Z
Answers.Text: I have created both database (drupal and civicrm), the user has all privileges, username and password are correct, but still can't proceed. I don't know what to do and what I did wrong.
Answers.UserDisplayName: CelsomTrindade
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T23:29:18.360Z
Answers.Text: I was able to remove the error "Access denied". But still can't proceed with the installation. Any idea? Already created the database on phpmyadmin
Answers.UserDisplayName: CelsomTrindade
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-07T15:18:23.663Z
Answers.Text: Follow the rest of the setup instructions in the guide I linked. You need to put the database connection details into settings.php for Drupal and civicrm.settings.php for CiviCRM. I suggest getting Drupal working first and then setting up CiviCRM afterward.
Answers.UserDisplayName: user3827
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-07T15:53:29.497Z
Answers.Text: It happens that this problem was happening because of some permissions. After I created the databases, I started getting write permissions errors. I changed the enviroment to my wamp server and now It's working. But anyway, I would need to create the database before proceding anyway, so, thanks for the hint.
Answers.UserDisplayName: CelsomTrindade
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-10-06T18:36:21.110Z
Answers.LastActivityDate: 2016-10-06T18:36:21.110Z
Answers.UserDisplayName: user3827
Body: <p>I'm trying to install CiviCRM 4.7.12 in Drupal7 but I'm unable to proceed with the CiviCrm Installer. Right at the top of the page (outside of the Installer box) I have this error:</p>
  <blockquote>
  <p>Warning: mysqli_real_escape_string() expects parameter 1 to be mysqli, boolean given in ...\docroot\sites\all\modules\civicrm\install\index.php on line 1256</p>
  </blockquote>
  <p>Which is this line: <code>$query = sprintf(&quot;CREATE DATABASE %s&quot;, mysqli_real_escape_string($conn, $database));</code></p>
  <p>After that I can't make the requeriments match, and because of this, I can't procced with the installation. Apart from the error: <code>Your database settings don't appear to be correct</code>, which seems to be default, according to the Installation guide documentation, I have this list of errors:</p>
  <p><strong>CiviCRM Database Details</strong></p>
  <blockquote>
  <p>Are the access credentials correct? -&gt; That username/password doesn't work: Access denied for user 'civicrm'@'localhost' (using password: NO)</p>
  <p>Can I access/create the database? -&gt; I can't create new databases and the database 'civicrm' doesn't exist. (user 'civicrm' doesn't have CREATE DATABASE permissions.)</p>
  <p>Can I access/create InnoDB tables in the database? -&gt; Unable to create InnoDB tables. MySQL InnoDB support is required for CiviCRM but is either not available or not enabled in this MySQL database server. Could not determine if MySQL has InnoDB support. Assuming no.</p>
  <p>Can I create temporary tables in the database? -&gt; Could not login to the database.</p>
  <p>Can I create lock tables in the database? -&gt; Could not connect to the database server.</p>
  <p>Can I create triggers in the database? -&gt; Could not login to the database.</p>
  </blockquote>
  <p><strong>Drupal Database Details</strong></p>
  <blockquote>
  <p>Are the access credentials correct? -&gt; That username/password doesn't work: Access denied for user 'drupal'@'localhost' (using password: NO)</p>
  <p>Can I access/create the database? -&gt; The database: 'drupal' does not exist.</p>
  </blockquote>
  <p>I just started a blank Drupal instance and the only thing I'm trying to install is CiviCRM, I'm also <a href="https://wiki.civicrm.org/confluence/display/CRMDOC/Installing+CiviCRM+for+Drupal+7" rel="nofollow noreferrer">following these steps</a>, the only one o got a little confused was step 2.</p>
  <p>Am I supposed to replace my settings.php with that line of code? Because mine just have this <code>$databases = array();</code> while the one on the guide is filled with information.</p>
  <p>What am I doing wrong?</p>
  
Tags: <installation>
Title: Installing CiviCRM 4.7 in Drupal 7 can't match requirements
ThreadText: # Installing CiviCRM 4.7 in Drupal 7 can't match requirements
  
  (Asked by: username_0 on 2016-10-06)
  
  I'm trying to install CiviCRM 4.7.12 in Drupal7 but I'm unable to proceed with the CiviCrm Installer. Right at the top of the page (outside of the Installer box) I have this error:
  
  > Warning: mysqli\_real\_escape\_string() expects parameter 1 to be mysqli, boolean given in ...\docroot\sites\all\modules\civicrm\install\index.php on line 1256
  
  Which is this line: `$query = sprintf("CREATE DATABASE %s", mysqli_real_escape_string($conn, $database));`
  
  After that I can't make the requeriments match, and because of this, I can't procced with the installation. Apart from the error: `Your database settings don't appear to be correct`, which seems to be default, according to the Installation guide documentation, I have this list of errors:
  
  **CiviCRM Database Details**
  
  > Are the access credentials correct? -> That username/password doesn't work: Access denied for user 'civicrm'@'localhost' (using password: NO)
  >
  > Can I access/create the database? -> I can't create new databases and the database 'civicrm' doesn't exist. (user 'civicrm' doesn't have CREATE DATABASE permissions.)
  >
  > Can I access/create InnoDB tables in the database? -> Unable to create InnoDB tables. MySQL InnoDB support is required for CiviCRM but is either not available or not enabled in this MySQL database server. Could not determine if MySQL has InnoDB support. Assuming no.
  >
  > Can I create temporary tables in the database? -> Could not login to the database.
  >
  > Can I create lock tables in the database? -> Could not connect to the database server.
  >
  > Can I create triggers in the database? -> Could not login to the database.
  
  **Drupal Database Details**
  
  > Are the access credentials correct? -> That username/password doesn't work: Access denied for user 'drupal'@'localhost' (using password: NO)
  >
  > Can I access/create the database? -> The database: 'drupal' does not exist.
  
  I just started a blank Drupal instance and the only thing I'm trying to install is CiviCRM, I'm also [following these steps](https://wiki.civicrm.org/confluence/display/CRMDOC/Installing+CiviCRM+for+Drupal+7), the only one o got a little confused was step 2.
  
  Am I supposed to replace my settings.php with that line of code? Because mine just have this `$databases = array();` while the one on the guide is filled with information.
  
  What am I doing wrong?
  
  **Tags:** installation
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2016-10-06. Score: 2 | Accepted answer
  
  The real issue is that your database credentials are invalid.
  
  `Access denied for user 'civicrm'@'localhost' (using password: NO)`
  
  `Access denied for user 'drupal'@'localhost' (using password: NO)`
  
  Most likely the warning you are seeing is due to the connection object being FALSE as a result of not being able to connect, instead of a mysqli connection object.
  
  `The database: 'drupal' does not exist.`
  
  You should also at the very least create the `drupal` and `civicrm` databases you intend to use; Drupal and CiviCRM's installation will create all the necessary tables.
  
  > **Comments:**
  > **username_0**: I tried to create those tables, but the errors still appear to me. Do I need to also manually create/change those users on the phpmyadmin?  
  > **username_1**: Go to the section titled "Create a database and user using phpMyAdmin" - https://www.drupal.org/docs/7/installing-drupal-7/step-2-create-the-database  
  > **username_0**: but i st the first error causing a "no database connection", and with it generating the other errors?  
  > **username_1**: No, it is the other way around. It is also not an error but a PHP warning.  
  > **username_0**: I have created both database (drupal and civicrm), the user has all privileges, username and password are correct, but still can't proceed. I don't know what to do and what I did wrong.  
  > **username_0**: I was able to remove the error "Access denied". But still can't proceed with the installation. Any idea? Already created the database on phpmyadmin  
  > **username_1**: Follow the rest of the setup instructions in the guide I linked. You need to put the database connection details into settings.php for Drupal and civicrm.settings.php for CiviCRM. I suggest getting Drupal working first and then setting up CiviCRM afterward.  
  > **username_0**: It happens that this problem was happening because of some permissions. After I created the databases, I started getting write permissions errors. I changed the enviroment to my wamp server and now It's working. But anyway, I would need to create the database before proceding anyway, so, thanks for the hint.  
  
  ---
  
  