-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaddc.php
121 lines (93 loc) · 2.85 KB
/
addc.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
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<?php
include("conff.php");
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>THE Blog</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<?php
if(isset($_SESSION['theme']))
{
if($_SESSION['theme']=='1')
{echo'<link rel="stylesheet" type="text/css" href="index.css" />';
echo'<!--[if IE 6]>
<link type="text/css" rel="stylesheet" type="text/css" href="index.css" />
#repeated_back{position:absolute;}
</style>
<![endif]-->';}
if ($_SESSION['theme']=='2')
{echo'<link rel="stylesheet" type="text/css" href="index2.css" />';
echo'<!--[if IE 6]>
<link type="text/css" rel="stylesheet" type="text/css" href="index2.css" />
#repeated_back{position:absolute;}
</style>
<![endif]-->';}
if ($_SESSION['theme']=='3')
{echo'<link rel="stylesheet" type="text/css" href="index3.css" />';
echo'<!--[if IE 6]>
<link type="text/css" rel="stylesheet" type="text/css" href="index3.css" />
#repeated_back{position:absolute;}
</style>
<![endif]-->';
}
}
else
{echo'<link rel="stylesheet" type="text/css" href="index.css" />';}
?>
</head>
<body>
<div id="repeated_back"></div>
<div id="center">
<div id="logo"></div>
<div id="head"></div>
<div id="log">
<?php
if(!isset($_SESSION['username']))
{
echo'
<a href="loginn.php"><div id="b_log"></div></a>';
}
else
{
echo $_SESSION['username'];
echo'
<br/>
<form name="profile-form" id="profile-form" method="post" action="profile.php">
<input type="submit" name="cmdlogout" value="Profile" style="height: 25px; width: 55px" />
</form>
<form name="logout-form" id="logout-form" method="post" action="logout.php">
<input type="submit" name="cmdlogout" value="Logout" style="height: 25px; width: 55px"/>
</form>';
}
?>
</div>
<a href="index.php"><div id="b_home"></div></a>
<a href="blog.php"><div id="b_blogs"></div></a>
<a href="info.php"><div id="b_info"></div></a>
<div id="post_cont">
<div id="post">
<div id="posthead"></div>
<div id="postbody">
<?php
$temp=$_POST['id'];
$query="SELECT * FROM msg WHERE id='$temp' ";
$result=mysql_query($query);
$row=mysql_fetch_array($result);
$_SESSION['com']=$row['coment'];
echo $row['title'];
echo'<br/>';
echo $row['body'];
echo '<form name="input" action="createcomment.php" method="post">';
echo'Comment: <br/><textarea name="post" rows="10" cols="74" wrap="virtual"/>';
echo'</textarea>';
echo'<button type="submit" name="id" value="'; echo $temp; echo'" style="width:74px; height:35px;">Comment</button>';
?>
</form>
</div>
<div id="postfoot"></div>
</div>
</div>
</div>
</body>
</html>