-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
167 lines (130 loc) · 5.86 KB
/
index.php
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title> SAQIB </title>
<link href="https://fonts.googleapis.com/css2?family=Source+Sans+Pro:wght@600&display=swap" rel="stylesheet">
<link rel="icon" type="image" href="pic2.jpg">
<link rel="stylesheet" href="port_css.css">
</head>
<body>
<?php
$err = " .";
if($_SERVER['REQUEST_METHOD']=="POST"){
date_default_timezone_set("asia/kolkata");
$name = $_POST['name'];
$phone = $_POST['phone'];
$email = $_POST['email'];
$mess = $_POST['msg'];
$curr_date = date("D/d/m/Y");
$curr_time = date("h:i:sa");
$servername = 'localhost';
$username = 'root';
$password = 'mysql';
$db = 'portfolio';
$conn = new mysqli($servername,$username,$password,$db);
$sql = "INSERT INTO `message`(`Name`, `Phone`, `Email`, `Address`,`Date`, `Time`) VALUES('$name','$phone','$email','$mess','$curr_date','$curr_time')";
// $conn->query($sql);
// Check connection
// if ($conn->connect_error) {
// die("Connection failed: " . $conn->connect_error);
// }
// echo "Connected successfully";
if($conn->query($sql) === TRUE){
// echo "Thanks for messaging.";
$err = "Thanks";
}
}
?>
<header class="head">
<div class="port"> <a href="index.php"> Portfolio </a> </div>
<div><img src="menu.png" alt="" height="30px" width="auto" id="img" onclick="menu_togle()" ></div>
<div id="menu">
<a href="index.php" onclick="hide()"> <div> Home </div> </a>
<a href="#about" onclick="hide()"> <div> About </div> </a>
<a href="#skills" onclick="hide()"> <div> Skills </div> </a>
<a href="#works" onclick="hide()"> <div> Works </div> </a>
<a href="#resume" onclick="hide()"> <div> Resume </div> </a>
<a href="#contact" onclick="hide()"> <div> Contact </div> </a>
</div>
</header>
<div class="home" id="home">
<div class="home_content">
<div class="hello">Hello, My name is </div>
<div class="saqib">Mohd Saqib</div>
<div class="developer">I'm a Web Developer | Student </div>
<a href="#contact"> <button class="hire"> Hire </button> </a>
</div>
</div>
<div id="about">
<div class="who"> About me <hr> </div>
<span class="mypic"> <img src="pic2.jpg" alt="" > </span>
<span class="bio">
I'am currently a 3rd year student of Diploma in
Computer Engineering at Jamia Millia Islamia University.
I am a hard working, honest , good timekeeper and always
willing to learn new skills. I’m a nice fun and friendly person.
</span>
</div>
<div id="skills">
<div class="skill_head"> Skills <hr></div>
<div class="skill_list">
<ul>
<li> C/C++ </li>
<li> JavaScript </li>
<li> HTML </li>
<li> CSS </li>
<li> MySql </li>
<li> PHP </li>
<li> jQuery </li>
</ul>
</div>
</div>
<div id="works">
<div class="work_head"> Works <hr> </div>
<ul class="work_list">
<li> <a href="Icard/Icard_form.php"> Identity Card Generator </a> </li>
<li> <a href="#"> College Website </a> </li>
</ul>
</div>
<div id="resume">
<div class="resume_head"> Resume <hr> </div>
<a href="#"> <div class="resume_download">
Download Resume
</div> </a>
</div>
<div id="contact">
<div class="contact_head"> Contact <hr></div>
<div class="address">
<span class="adr_head"> Address </span> <br> <br>
<span class="adr" > <img src="adress_icon.png" alt="" height="30px" width="auto">  
Dr. BR ambedkar Hostel,Jamia Millia Islamia,<br>
      Okhla Jamia Nagar,
New Delhi- 110025 </span> <br> <hr> <br>
<span class="phone"> <img src="call.png" alt="" height="20px" width="auto">   +91 95480 97513 </span> <br> <hr> <br>
<span class="email"> <img src="message.png" alt="" height="20px" width="auto">   mohdsaqibnavodaya@gmail.com </span> <br> <hr> <br>
<a href="https://www.linkedin.com/in/mohd-saqib-0ab247189/"> <span> <img src="linkedin.png" height="30px" width="auto">   </span> </a>
<a href="https://github.com/MohdSaqib2003/"> <span> <img src="github.png" height="30px" width="auto">   </span> </a>
<a href="https://www.facebook.com/saqibNavodayan/"> <span> <img src="facebook.png" height="30px" width="auto">   </span> </a> <hr>
<br><br>
</div>
<div class="message">
<span class="msg_head"> Message me </span> <br> <br> <br>
<form method="POST" action="<?php $_SERVER['PHP_SELF']; ?>" class="msg_form" onsubmit="return validate()">
<input class="name" type="text" name="name" id="nme" placeholder="Name" autocomplete="OFF">
<input type="phone" class="phone_no" id="phone" name="phone" placeholder="Phone" autocomplete="OFF"> <br>
<input type="email" class="email_adr" id="email" name="email" placeholder="Email" autocomplete="OFF"> <br>
<input type="text" class="msg" name="msg" placeholder="Message" id="mess" autocomplete="OFF"><br><span id="error"> </span><br>
<input type="submit" class="button" value="Send message" id="submit" > <br>
<span id="response"> <?php echo $err;?> </span>
</form>
</div>
</div>
<footer class="thank">
<div>Thanks for visiting</div>
</footer>
<script src="port_js.js">
</script>
</body>
</html>