AgerNic.com
WEB DEVELOPER SITE, HTML, CSS, PHP, SQL

PHP mysqli_query() Function - mysqli query


The mysqli_query() function performs a query against the database.

PHP mysqli query result - example


Syntax: The basic syntax of the mysqli query;
mysqli_query(connection, query, resultmode);

Example 1:
<?php
$conn=mysqli_connect("localhost", "user", "password", "databbase");
// Check connection
if (mysqli_connect_errno())
  {
  echo "Failed to connect to MySQL:". mysqli_connect_error();
  }
// Perform queries 
mysqli_query($conn,"SELECT * FROM users");
mysqli_query($conn,"INSERT INTO users (FirstName, LastName, email, password) 
VALUES ('Nicky','Lauda',' [email protected]', 'gyars225%ABER')");
mysqli_close($conn);
?>

Note: Be careful when you are deleting records in a table!


mysqli query, select database mysqli
PHP mysqli_query() Function - mysqli query - sql tutorial

Online Editor
ONLINE EDITOR

news templates


COLOR PICKER

news templates
This tool makes it easy to create, adjust, and experiment with custom colors for the web.


HTML Templates
news templates
Magnews2 is a modern and creative free magazine and news website template that will help you kick off your online project in style.


CSS HTML Layout
news templates
Find here examples of creative and unique website layouts.


Free CSS HTML Menu
news templates
Find here examples of creative and unique website CSS HTML menu.


Online Editor
ONLINE EDITOR

news templates


COLOR PICKER

news templates
This tool makes it easy to create, adjust, and experiment with custom colors for the web.


HTML Templates
news templates
Magnews2 is a modern and creative free magazine and news website template that will help you kick off your online project in style.


CSS HTML Layout
news templates
Find here examples of creative and unique website layouts.


Free CSS HTML Menu
news templates
Find here examples of creative and unique website CSS HTML menu.


jQuery replace...
jQuery replaceClass...
jQuery click ()...
jQuery switchClass()...
jQuery draggable()...
jQuery HTML...
jQuery scroll smooth...
jQuery scroll()...
jQuery stop()...
jQuery animate()...
jQuery SlideToggle()...
jQuery slideDown()...
jQuery slideUp()...
jQuery fadeToggle...
jQuery fadeOut()...
jQuery fadeIn()...
jQuery Effects - hide () and show ()...
jQuery Events...
jQuery Attributes...
jQuery Selectors...