-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconnection2.php
More file actions
34 lines (32 loc) · 926 Bytes
/
connection2.php
File metadata and controls
34 lines (32 loc) · 926 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?php
$con=mysql_connect("localhost","root","Qwerty123") or die (mysql_error());
mysql_query("create database if not exists maildb");
mysql_select_db("maildb");
mysql_query('create table if not exists mails(
mailid int(11) NOT NULL AUTO_INCREMENT,
recid varchar(50) NOT NULL,
senid varchar(50) NOT NULL,
sub varchar(50) NOT NULL,
msg text NOT NULL,
status varchar(20) NOT NULL,
primary key( mailid)
);');
mysql_query('create table if not exists userinfo(
user_id int(11) NOT NULL AUTO_INCREMENT,
username char(50) NOT NULL,
password varchar(50) NOT NULL,
mobile bigint(20) NOT NULL,
email varchar(50) NOT NULL,
gender enum("m","f") NOT NULL,
primary key (user_id)
);');
mysql_query('create table if not exists logdetails(
logid int(11) NOT NULL AUTO_INCREMENT,
senid varchar(50) NOT NULL,
recid varchar(50) NOT NULL,
msg text NOT NULL,
status varchar(30) NOT NULL,
parentst varchar(30) NOT NULL,
primary key(logid))
;');
?>