EasyUI Forum
April 28, 2024, 09:20:54 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: connection to database  (Read 7269 times)
joe007
Newbie
*
Posts: 8


View Profile Email
« on: July 26, 2020, 08:49:44 AM »

Hi,
I'm new on easyui..does anyone know how to connect the data grid with a table on database.

thx,

Joe
Logged
stworthy
Administrator
Hero Member
*****
Posts: 3581


View Profile Email
« Reply #1 on: July 27, 2020, 12:21:37 AM »

This tutorial shows how to create a database table and retrieves data using a php script.
Please look at this tutorial https://www.jeasyui.com/tutorial/app/crud.php
Logged
joe007
Newbie
*
Posts: 8


View Profile Email
« Reply #2 on: July 27, 2020, 02:27:57 AM »

Hi,
Firstly thanks for the respon. I've read the script as below :

$rs = mysql_query('select * from users');
$result = array();
while($row = mysql_fetch_object($rs)){
    array_push($result, $row);
}
 
echo json_encode($result);

my next questions are :
1. Where are the database? it's only users table
2. I can not see the user, password, and db of those script

thx,

Joe
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!