-
Notifications
You must be signed in to change notification settings - Fork 0
/
create.php
203 lines (178 loc) · 5.44 KB
/
create.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
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
<?php
error_reporting(E_ALL);
session_start();
$user = $_SESSION['logged_user'];
if(!isset($_SESSION['logged_user'])){
header("Location: pages/media.html");
}
?>
<html>
<head>
<style>
body {
display: grid;
grid-template-rows: 7% 10% 75% 0% 15%;
width: auto;
height: auto;
margin: 0;
}
.section1{
display: grid;
background-color: #faf743;
grid-template-columns: 10% 30% 15% 15% 15% 11% 4%;
position: sticky;
}
select {
padding: 10px;
font-size: 16px;
border: 2px solid yellow;
border-radius: 5px;
}
select:focus {
outline: none;
border-color: #3498db; /* Change border color on focus */
}
/* Animation for the select box */
select {
transition: border-color 0.3s ease;
}
/* Animation for the options */
select option {
transition: background-color 0.3s ease, color 0.3s ease;
}
.opt:hover {
background-color: red; /* Change background color on hover */
color: white; /* Change text color on hover */
}
button{
color: #0099CC;
background: #cae3fa;
border: 2px solid #0099CC;
border-radius: 20px;
text-decoration: none;
text-transform: uppercase;
border: none;
color: black;
padding: 11px 11px;
text-align: center;
text-decoration: none;
display: inline-block;
font-size: 12px;
margin: 4px 2px;
transition-duration: 0.4s;
cursor: pointer;
}
.section2 {
display: grid;
background-color: #67cceb;
grid-template-columns: repeat(14,auto);
grid-auto-rows: minmax(10px, auto);
justify-content: space-between;
padding: 5px 2px;
}
button:hover{
background-color: #077ae6;
color: white;
}
.section3 {
background-color: #bef3f7;
height: *;
}
.btn1{
padding:5px;
background-image:linear-gradient(to right,#027ced,#bef3f7);
color:white;
}
.btn1:hover{
background-image:linear-gradient(to left,#027ced,#bef3f7);
color:black;
border: dashed green;
}
.btn2:hover{
background-image:linear-gradient(to left,red,#bef3f7);
color:black;
border: dashed red;
}
.btn2{
padding:5px;
background-image:linear-gradient(to right,red,#bef3f7);
color:white;
}
.bt{
display: grid;
place-items: center;
width: inherit;
height: inherit;
padding: 5px;
}
footer{
background-color: #0a0369;
color: white;
}
.btt{
place-items: right;
}
.anc{
place-items: center;
}
</style>
</head>
<body>
<div class="section1">
<img src="https://upload.wikimedia.org/wikipedia/commons/7/7e/Circle-icons-profile.svg" width="40px" height="40px" style="padding:5px">
<div class=bt id="usergreet">Hello <?php echo $_SESSION['logged_user']; ?>, Lets DIY!!</div>
<div class="bt btt">Select Domain:</div>
<div class=bt>
<select>
<option class=opt value="Agriculture">Agriculture</option>
<option class=opt value="Electornics">Electronics</option>
<option value="Craft">Craft</option>
<!-- Add more font options as needed -->
</select>
</div>
<div class=bt><button class=btn1>See Code</button></div>
<div class=bt><button class=btn2 onclick="sendToServer()">Upload</button></div>
<a href="h.html" class=anc><img src="./help.png" width=20px height=20px style="padding:15px;"></a>
</div>
<div class="section2">
<div class=bt><button onclick="document.execCommand('bold', false, null)"><strong>Bold</strong></button></div>
<div class=bt><button onclick="document.execCommand('italic', false, null)"><em>Italic</em></button></div>
<div class=bt><button onclick="document.execCommand('strikeThrough', false, null)"><strike>Strike</strike></button></div>
<div class=bt><button onclick="document.execCommand('justifyCenter', false, null)">Center</button></div>
<div class=bt><button onclick="document.execCommand('justifyLeft', false, null)">Left</button></div>
<div class=bt><button onclick="document.execCommand('justifyRight', false, null)">Right</button></div>
<div class=bt><input type="color" id="textColorPicker" onchange="changeTextColor(event)"></div>
<div class=bt><input type="color" id="bgColorPicker" onchange="changeBackgroundColor(event)"></div>
<div class=bt><input type="file" id="imageInput" accept="\image/ *" onchange="insertImage()"></div>
<!-- Font Family -->
<div class=bt>
<select title=Font id="fontFamilySelector" onchange="changeFontFamily(this.value)">
<option class=opt value="Arial">Arial</option>
<option class=opt value="Times New Roman">Times New Roman</option>
<!-- Add more font options as needed -->
</select>
</div>
<!-- Font Size -->
<div class=bt><input type="number" id="fontSizeInput" min="1" max="7" onchange="changeFontSize(this.value)"></div>
<!-- Heading Tags -->
<div class=bt><button onclick="changeHeading('h1')">H1</button></div>
<div class=bt><button onclick="changeHeading('h2')">H2</button></div>
<div class=bt><button onclick="changeHeading('h3')">H3</button></div>
<!-- Add more formatting buttons as needed -->
</div>
<form id="imageForm" enctype="multipart/form-data" style="display: none;">
<input type="file" name="image" accept="image/ *">
</form>
<div class="section3" contenteditable="true" id="myEditableDiv" onkeyup="saveContent()">
Editable content goes here<br>
<?php echo $_SESSION['home']; ?>
</div>
<footer>
<center>
<a href="mailto:[email protected]">Email:[email protected]</a><br />
© 2024 ADDS. All rights reserved.
</center>
</footer>
<script type="text/javascript" src="script1.js"></script>
</body>
</html>