OXIESEC PANEL
- Current Dir:
/
/
var
/
www
/
3-31-025chanakya
Server IP: 139.59.38.164
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
05/09/2025 11:18:49 AM
rwxr-xr-x
📄
.htaccess
860 bytes
03/26/2025 03:47:46 AM
rw-r--r--
📁
.vscode
-
03/26/2025 03:47:57 AM
rwxr-xr-x
📁
CreateLeadPage
-
03/26/2025 04:16:47 AM
rwxr-xr-x
📄
ImageMagick-7.1.1-45-Q16-HDRI-x64-dll.exe
22.2 MB
03/26/2025 03:47:54 AM
rw-r--r--
📁
Xpress
-
03/26/2025 04:21:24 AM
rwxr-xr-x
📄
XpressPage.php
47.13 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
about.html
3.26 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
account.php
47.77 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
activate.php
2.19 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
add_channel.php
9.7 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
add_to_channel.php
980 bytes
03/26/2025 03:47:46 AM
rw-r--r--
📁
admin
-
03/26/2025 04:16:40 AM
rwxr-xr-x
📄
analytics.php
37.71 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
assets
-
03/26/2025 04:16:41 AM
rwxr-xr-x
📁
audio
-
03/26/2025 03:48:03 AM
rwxr-xr-x
📄
businessLp.php
46.33 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
bussLp.php
57.87 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
card-news.php
6.2 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
channel.php
36.21 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
chattest.php
8.66 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
clients
-
03/26/2025 03:48:03 AM
rwxr-xr-x
📄
collections.php
94.62 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
comments.php
1.67 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
composer.json
65 bytes
03/26/2025 03:47:46 AM
rw-r--r--
📄
composer.lock
4.03 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
contact.html
3.01 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
cookie.php
750 bytes
03/26/2025 03:47:46 AM
rw-r--r--
📄
copytest.html
4.04 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
creamAdmin
-
03/26/2025 04:07:42 AM
rwxr-xr-x
📄
cream_dashboard.php
25.87 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
creamapi
-
03/26/2025 03:48:04 AM
rwxr-xr-x
📄
create.php
42.93 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
created_magazine.html
11.96 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
dashboard.php
55.52 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
data
-
03/26/2025 04:16:48 AM
rwxr-xr-x
📄
down.html
829 bytes
03/26/2025 03:47:46 AM
rw-r--r--
📁
education-podcasts
-
03/31/2025 06:36:42 AM
rwxr-xr-x
📁
featured_channels
-
03/26/2025 03:48:04 AM
rwxr-xr-x
📄
featured_channels.php
32.48 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
featured_topics.php
26.59 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
fetch_articles.php
1.83 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
fetch_liked_users.php
1.55 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
filter.php
4.91 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
follow_action.php
1.75 KB
03/26/2025 03:47:46 AM
rw-r--r--
📄
follow_dash.php
33.76 KB
03/26/2025 03:47:46 AM
rw-r--r--
📁
form-builder
-
03/26/2025 03:48:04 AM
rwxr-xr-x
📄
function.php
20.61 KB
03/26/2025 03:47:47 AM
rw-r--r--
📁
genai
-
03/26/2025 04:20:06 AM
rwxr-xr-x
📄
generated_article.php
11.86 KB
03/26/2025 03:47:47 AM
rw-r--r--
📄
get_recent_items.php
1.37 KB
03/26/2025 03:47:47 AM
rw-r--r--
📄
handle_channel.php
856 bytes
03/26/2025 03:47:47 AM
rw-r--r--
📁
hindiConverter
-
03/26/2025 04:15:50 AM
rwxr-xr-x
📄
homePin.php
68.38 KB
03/26/2025 03:47:47 AM
rw-r--r--
📁
hps
-
03/26/2025 03:48:05 AM
rwxr-xr-x
📄
impmy_collection.php
124.17 KB
03/26/2025 03:47:47 AM
rw-r--r--
📁
inc
-
03/26/2025 04:15:50 AM
rwxr-xr-x
📄
index.php
30.55 KB
03/26/2025 03:47:48 AM
rw-r--r--
📄
index1.php
61.34 KB
03/26/2025 03:47:50 AM
rw-r--r--
📄
influencer.php
11.72 KB
03/26/2025 03:47:54 AM
rw-r--r--
📁
interface
-
03/26/2025 03:48:05 AM
rwxr-xr-x
📁
kannada
-
03/26/2025 04:20:06 AM
rwxr-xr-x
📄
knobly_logo.png
9.45 KB
03/26/2025 03:47:54 AM
rw-r--r--
📄
landing_page.php
17.27 KB
03/26/2025 03:47:54 AM
rw-r--r--
📄
landing_signin.php
5.11 KB
03/26/2025 03:47:54 AM
rw-r--r--
📁
leadpage
-
03/26/2025 04:15:53 AM
rwxr-xr-x
📄
link.php
5.63 KB
03/26/2025 03:47:54 AM
rw-r--r--
📄
logInCheck.php
4.41 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
loggedInCheck.php
1.15 KB
03/26/2025 03:47:54 AM
rw-r--r--
📄
logo (1).svg
814 bytes
03/26/2025 03:47:55 AM
rw-r--r--
📄
logout.php
503 bytes
03/26/2025 03:47:55 AM
rw-r--r--
📄
magazine.html
4.46 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
magazine.php
23.57 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
more.php
9.21 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
my_collection.php
153.03 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
my_settings.php
17.44 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
navbar.php
3.36 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
new-page.php
10.46 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
newEditor.php
17.04 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
newsletter.php
24.31 KB
03/26/2025 03:47:55 AM
rw-r--r--
📁
pageLanding
-
03/26/2025 04:20:07 AM
rwxr-xr-x
📁
pages
-
03/26/2025 04:15:53 AM
rwxr-xr-x
📄
payment.php
29.86 KB
03/26/2025 03:47:55 AM
rw-r--r--
📁
pdf
-
03/26/2025 03:48:06 AM
rwxr-xr-x
📄
pdftk_server-2.02-win-setup.exe
2.91 MB
03/26/2025 03:47:56 AM
rw-r--r--
📄
post-details.php
37.75 KB
03/26/2025 03:47:55 AM
rw-r--r--
📄
premium.php
21.79 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
privacy.html
12.1 KB
03/26/2025 03:47:56 AM
rw-r--r--
📁
process
-
03/26/2025 03:48:11 AM
rwxr-xr-x
📄
process-plan.php
1.44 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
process.php
1.52 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
process_data.php
5.02 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
profile.php
37.8 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
profile_pic_upload.php
4.83 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
profile_test.php
19.78 KB
03/26/2025 03:47:56 AM
rw-r--r--
📁
reels
-
03/26/2025 04:20:08 AM
rwxr-xr-x
📄
refund.html
9.04 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
replyPost.php
3.93 KB
03/26/2025 03:47:56 AM
rw-r--r--
📁
report
-
03/26/2025 03:48:11 AM
rwxr-xr-x
📄
request_article.php
22.76 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
reset.html
4.7 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
save_profile.php
2.78 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
saved.php
34.28 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
saved_posts.php
49.25 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
search_bar.php
16.95 KB
03/26/2025 03:47:56 AM
rw-r--r--
📁
sendy
-
03/26/2025 04:21:20 AM
rwxr-xr-x
📄
settings.php
81.93 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
sharemarket.php
3.88 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
showcase.php
10.34 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
signInProcess.php
13.83 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
signInProcess_backup.php
11.18 KB
03/26/2025 03:47:56 AM
rw-r--r--
📁
social_media
-
03/26/2025 04:16:12 AM
rwxr-xr-x
📄
start.html
3.99 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
store_articles.php
1.04 KB
03/26/2025 03:47:56 AM
rw-r--r--
📄
stream.php
62.31 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
streamPush.php
29.82 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
streamb.php
40.75 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
streambb.php
47.34 KB
03/26/2025 03:47:57 AM
rw-r--r--
📁
texttovoice
-
03/26/2025 03:48:13 AM
rwxr-xr-x
📁
thumbsUp
-
03/26/2025 03:48:13 AM
rwxr-xr-x
📄
toggle_channel.php
2.28 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
udupi_sign_up.php
34.5 KB
03/26/2025 03:47:57 AM
rw-r--r--
📁
uploads
-
03/26/2025 04:06:46 AM
rwxr-xr-x
📄
usage.html
37.76 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
userActivity.php
9.79 KB
03/26/2025 03:47:57 AM
rw-r--r--
📁
vendor
-
03/26/2025 04:20:23 AM
rwxr-xr-x
📄
verify.php
744 bytes
03/26/2025 03:47:57 AM
rw-r--r--
📄
view.php
13.36 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
view_newsletter.php
1.58 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
xpress_landing_page.php
78.63 KB
03/26/2025 03:47:57 AM
rw-r--r--
📄
xpress_landingpage.html
11.15 KB
03/26/2025 03:47:57 AM
rw-r--r--
Editing: add_channel.php
Close
<?php include 'assets/php/db_connect.php'; include 'assets/php/validate.logged.php'; // Check if form is submitted if ($_SERVER["REQUEST_METHOD"] == "POST") { header('Content-Type: application/json'); // Check for form fields if (isset($_POST['name'], $_POST['bio'], $_FILES['profilepic'])) { // Get data from form $name = trim($_POST['name']); $bio = trim($_POST['bio']); $created_at = date('Y-m-d H:i:s'); // Get current date and time $deleted_at = NULL; // Set to NULL initially // Check if required values are not empty if (empty($name) || empty($bio)) { echo json_encode(['status' => 'error', 'message' => 'Channel name and bio are required.']); exit; } // Prepare and bind statement $stmt = $conn->prepare("INSERT INTO channels (name, bio, created_by, created_at) VALUES (?, ?, ?, ?)"); $stmt->bind_param("ssss", $name, $bio, $gUserId, $created_at); // Execute the query if ($stmt->execute()) { $channel_id = $stmt->insert_id; // Handle profile picture upload $profilepic = $_FILES['profilepic']; $profilepic_name = $channel_id . "_" . time() . ".png"; $profilepic_tmp_name = $profilepic['tmp_name']; $profilepic_path = 'data/channelPic/' . $profilepic_name; // Validate file type (image) $allowed_types = ['image/jpeg', 'image/png', 'image/gif']; if (!in_array($profilepic['type'], $allowed_types)) { echo json_encode(['status' => 'error', 'message' => 'Invalid file type for profile picture.']); exit; } // Move the uploaded file to the desired folder if (move_uploaded_file($profilepic_tmp_name, $profilepic_path)) { $stmt = $conn->prepare("UPDATE channels SET profilePic = ? WHERE id = ?"); $stmt->bind_param("si", $profilepic_name, $channel_id); if ($stmt->execute()) { echo json_encode(['status' => 'success', 'message' => 'New channel added successfully!']); } else { echo json_encode(['status' => 'error', 'message' => 'Error saving profile picture information.']); } } else { echo json_encode(['status' => 'error', 'message' => 'Error uploading profile picture.']); } } else { echo json_encode(['status' => 'error', 'message' => 'Error: ' . $stmt->error]); } $stmt->close(); } else { echo json_encode(['status' => 'error', 'message' => 'Please complete all fields.']); } // Close connection when done $conn->close(); } else { ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Add Channel</title> <script src="assets/js/jquery-3.6.0.min.js"></script> <style> /* Basic Reset */ * { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: Arial, sans-serif; line-height: 1.6; background-color: #f4f4f4; padding: 20px; } h2 { color: #333; text-align: center; margin-bottom: 20px; } .container { width: 100%; max-width: 600px; margin: 0 auto; background-color: #fff; padding: 20px; box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); border-radius: 8px; transition: all 0.3s ease-in-out; } label { display: block; margin-bottom: 8px; font-weight: bold; } input[type="text"], textarea, input[type="file"] { width: 100%; padding: 10px; margin-bottom: 20px; border: 1px solid #ddd; border-radius: 4px; font-size: 16px; transition: all 0.2s ease-in-out; } input[type="submit"] { background-color: #db5919; color: white; border: none; padding: 10px 20px; border-radius: 4px; cursor: pointer; font-size: 16px; width: 100%; transition: background-color 0.2s ease-in-out; } input[type="submit"]:hover { background-color: #c14b16; } #responseMessage { text-align: center; margin-top: 20px; } /* Media Queries for responsiveness */ /* Medium Devices (Tablets) */ @media (max-width: 1024px) { .container { padding: 15px; box-shadow: none; } input[type="submit"] { font-size: 15px; } label, input[type="text"], textarea, input[type="file"] { font-size: 15px; } } /* Small Devices (Phones) */ @media (max-width: 768px) { body { padding: 10px; } .container { padding: 15px; width: 100%; } input[type="submit"] { font-size: 14px; } label, input[type="text"], textarea, input[type="file"] { font-size: 14px; } } /* Extra Small Devices (Phones in Portrait Mode) */ @media (max-width: 480px) { input[type="submit"] { font-size: 14px; padding: 12px; } label, input[type="text"], textarea, input[type="file"] { font-size: 14px; padding: 8px; } .container { padding: 10px; } } /* Very Small Devices (Extra Small Phones) */ @media (max-width: 320px) { .container { padding: 10px; width: 100%; } input[type="submit"] { font-size: 13px; padding: 12px; } label, input[type="text"], textarea, input[type="file"] { font-size: 13px; } } </style> <script> $(document).ready(function() { // Attach a submit event handler to the form $('#addChannelForm').on('submit', function(event) { event.preventDefault(); // Prevent default form submission // Create a FormData object to include all form data var formData = new FormData(this); // Send the AJAX request $.ajax({ url: '', // Replace with your PHP handler type: 'POST', data: formData, processData: false, // Prevent jQuery from automatically transforming the data contentType: false, // Set content type to false (for FormData) success: function(response) { console.log(response); if (response.status === 'success') { // Show alert message alert(response.message); // Redirect to dashboard.php after clicking OK window.location.href = 'dashboard.php'; } else { alert(response.message); // Show error message in alert } }, error: function(xhr, status, error) { // Show alert for errors alert('An error occurred: ' + error); } }); }); }); </script> </head> <body> <div class="container"> <h2>Add Channel</h2> <form id="addChannelForm" enctype="multipart/form-data"> <label for="name">Channel Name:</label> <input type="text" id="name" name="name" required><br><br> <label for="bio">Bio:</label> <textarea id="bio" name="bio" required></textarea><br><br> <label for="profilepic">Profile Picture:</label> <input type="file" id="profilepic" name="profilepic" required><br><br> <input type="submit" value="Add Channel"> </form> <div id="responseMessage"></div> </div> </body> </html> <?php } ?>