-
Notifications
You must be signed in to change notification settings - Fork 2
/
message.php
56 lines (52 loc) · 1.71 KB
/
message.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
<?php
include "connection.php";
if(empty($_SESSION))
{
session_start();
if(!isset($_SESSION['username']))
header("location:login.php");
}
else if(!isset($_SESSION['username']))
{
header("location:login.php");
exit;
}
$toname=$_SESSION['to'];
$toen=$_SESSION['toen'];
$arrlength=count($toname);
//echo $arrlength;
//echo $toname[0];
for($x=0;$x<$arrlength;$x++)
{
echo "<b><center>".$toname[$x]." ".$toen[$x]."</center><br></b>";
}
?>
<html>
<body>
<link rel="stylesheet" type="text/css" href="innerstyle.css">
<center> <img class="image" src="logo1.jpg" height=200 width=200 style="border-radius:100px; transform:scale(0.7);" > </center>
<h1>SHARECARE SOLUTIONS INDIA</h1>
<hr>
<center><font size= "6"><b><span> PERSONS FROM YOUR HOME TOWN </span></font size></b></center>
<hr>
</body>
</html>
<script type=text/javascript>
function create_button()
{
var x=document.getElementById('butarea');
//var y="<input type='number' placeholder='enrollment'/> <br> <input type=button value='submit'/>";
x.innerHTML+="<center><input type='number' name='to[]' placeholder='enrollment'/> <br></center>";
var y=document.getElementById('morereq');
y.innerHTML="<center><input type='button' value='request another' class='but' onclick='create_button()'/> <br> <br> <br> <input type='submit' class='but' value='request' name='request'/></center>";
}
</script>
<form action="request.php" method="POST">
<br>
<p><center><input type="button" class="but" onclick="create_button()" value="REQUEST SOMEONE"/></center></p>
<div id="butarea"> </div>
<div id='morereq'> </div>
<br>
<p><center> <a href="login_home.php"><input type='button' class='but' value='back'></a></center></p>
</form>
</html>