1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
NeTakaya
3 years ago
10

HOW DO I CONNECT TO MY mysql server on my computer locally using php and also how to run it on the browser

Computers and Technology
1 answer:
zhuklara [117]3 years ago
7 0

Answer:

<?php

$mysqli = new mysqli("127.0.0.1:3307", "myUser", "myPass", "databasename");

$query = "SELECT * FROM users ORDER BY name";

if($result = $mysqli->query($query))

{

   echo '<ul>';

while ($obj = $result->fetch_object())

   {

       echo '<li>'.$obj->name.'</li>';

   }

   $result->free();

   echo '</ul>';

}

else

{

   die("nothing found");

}

$mysqli->Close();

?>

Explanation:

This should get you started.

You might be interested in
What can you say about the different website that you used? do they have in common?​
Harrizon [31]
They all have ads. Some have inappropriate ads while some have irrelevant ads with respect to the website your on.
8 0
3 years ago
If there is an value in a array, and the same value comes at the same spot, does it cancel each other out or does it reassing th
kondaur [170]

Explanation:

In simple English, an array is a collection.

In C also, it is a collection of similar type of data which can be either of int, float, double, char (String), etc. All the data types must be same. For example, we can't have an array in which some of the data are integer and some are float.

8 0
3 years ago
Create a bulleted list of four descriptive terms describing possible values a person may have. These may be your own values, or
Minchanka [31]
Create a bulleted list of four descriptive terms describing possible values a person may have.

* always be true to yourself
* honesty is the best policy
* making mistakes leads you to solutions
* it's ok to be wrong
7 0
3 years ago
Most wheel/tire assemblies are balanced using lead weights which should be removed and segregated from other metals
crimeas [40]
The answer is true. I took the test.
6 0
3 years ago
Read 2 more answers
Does anyone know how I can make this return a double with 2 decimal places?
dolphi86 [110]

hi :)   .,..............

Explanation:

8 0
2 years ago
Other questions:
  • Discuss how the user-designer communications gap can cause a good project to go bad.
    8·1 answer
  • What ideas should I write about for information writing
    14·2 answers
  • 6.5 Code Practice: Question 1 please help with code!!! Thank you
    12·1 answer
  • Were does igneous rocks cool?
    9·1 answer
  • Which of the following shows a list of Big-Oh running times in order from slowest to fastest?
    7·2 answers
  • Someone talk to me please........
    5·2 answers
  • You receive an email that appears to legitimately be from your Bank. The email indicates the need for verification of your infor
    15·2 answers
  • Please help with this coding question
    8·2 answers
  • Write a program that asks the user for the name of a text file. The program should display the first 10 lines of the file on the
    6·1 answer
  • Write a function called mul_time that takes a Time_Elapsed object and a number and returns a new Time_Elapsed object that contai
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!