1. Trang chủ
  2. » Cao đẳng - Đại học

Lecture Web technologies and programming – Lecture 26: Database connectivity, data insertion, file upload in PHP - TRƯỜNG CÁN BỘ QUẢN LÝ GIÁO DỤC THÀNH PHỐ HỒ CHÍ MINH

20 5 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 20
Dung lượng 1,97 MB

Nội dung

A table is a collection of related data, and it consists of columns and. rows[r]

(1)(2)(3)(4)

Writing regular expression in PHP

Brackets []

Quantifiers +, *, ?, {int range}, and $ Sub-patterns

Predefined character ranges\d:\D:\w:

Validating User’s Input

Validating name:

Validating Password:Validating date:

Validating CNIC:Validating Email:

Validating user’s input

(5)

Defined functions

preg_match():

preg_match_all():preg_grep():

String Functions in PHP

(6)

Intro to MySQL

Creating database in MySQL using

WAMP

Connecting PHP with MySQL

Inserting data in database

CONNECTIONS: user registration

FILES super global variable

File uploading in PHP

Storing reference of uploaded file in

database

User registration in CONNECTIONS

web application with file upload

(7)

With PHP, you can connect to and

manipulate databases

MySQL is the most popular database

system used with PHP.

(8)

What is MySQL?

MySQL is named after co-founder Monty

Widenius's daughter: My

MySQL is a database system used on

the web

MySQL is a database system that runs

on a server

MySQL is ideal for both small and large

applications

MySQL is very fast, reliable, and easy to

use

MySQL uses standard SQL

MySQL compiles on a number of

platforms

MySQL is free to download and use

The data in a MySQL database are stored

in tables. A table is a collection of related data, and it consists of columns and

rows.

(9)

Go to home page of WAMP server

Select PHP myadmin

Login to MySql

Enter database name and click create

database button

(10)

Creating a table in a database:

Select database from the list of

databases

Enter table name and number of

columns

Enter name, data-type and other

required properties for columns

Click create table button

(11)(12)

12

Select

(13)

13

User name is root

(14)

14

(15)

15

Enter database name

(16)

16

(17)

17

Table name

Enter no of

(18)

18

Column name

Data-type

(19)

19

Primary key

Auto

(20)

20

Ngày đăng: 01/04/2021, 18:12

TÀI LIỆU CÙNG NGƯỜI DÙNG

TÀI LIỆU LIÊN QUAN