diff --git a/Profile Page/profile.html b/Profile Page/profile.html
index cf04e0f..7e81145 100644
--- a/Profile Page/profile.html
+++ b/Profile Page/profile.html
@@ -5,6 +5,8 @@
Profile Page
+
+
@@ -69,7 +71,13 @@
-

+

+
+
Click to upload shadowbox
+
+
diff --git a/Profile Page/scripts.js b/Profile Page/scripts.js
new file mode 100644
index 0000000..1416d76
--- /dev/null
+++ b/Profile Page/scripts.js
@@ -0,0 +1,22 @@
+function uploadShadowbox() {
+ const shadowboxInput = document.querySelector('input[name="shadowboxInput"]');
+ shadowboxInput.click();
+}
+
+//lol I have no idea what this does its an HTTP POST request thats all I know
+function handleShadowboxUpload(input) {
+ const file = input.files[0];
+ const formData = new FormData();
+ formData.append('shadowboxFile', file);
+
+ const xhr = new XMLHttpRequest();
+ xhr.open('POST', '/uploadShadowbox');
+ xhr.onload = function () {
+ if (xhr.status === 200) {
+ console.log('File uploaded successfully');
+ } else {
+ console.error('Error uploading file');
+ }
+ };
+ xhr.send(formData);
+}
\ No newline at end of file
diff --git a/Profile Page/styles2.css b/Profile Page/styles2.css
index 365cccc..1953ee6 100644
--- a/Profile Page/styles2.css
+++ b/Profile Page/styles2.css
@@ -185,6 +185,7 @@ p {
justify-content: center;
align-items: center;
padding-top: 50px;
+ width: 100%;
}
#shadowboxContainer > img {
@@ -192,4 +193,16 @@ p {
max-width: 100%;
box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.5);
+ }
+
+ #shadowboxFallback {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ background-color: #bbbbbb;
+ width: 100%;
+ height: 300px;
+ }
+ #shadowboxFallback > p {
+ margin: auto;
}
\ No newline at end of file