implemented image upload and cropping system, mostly work. it's too zoomed in and appears to be using the xy coords from the top left of the crop selector.

This commit is contained in:
2025-03-29 22:57:43 -06:00
parent 9a45075010
commit ff7e799b7f
14 changed files with 609 additions and 130 deletions
+27 -1
View File
@@ -1,7 +1,33 @@
</body>
<footer>
<script src="js/modal.js"></script>
<?php
if ($_SERVER['SCRIPT_NAME'] == '/user.php') {
$args = [];
$arr = explode('&', $_SERVER['QUERY_STRING']);
foreach ($arr as $a) {
$tmp = explode('=', $a);
$key = $tmp[0];
$value = $tmp[1];
$args[$key] = $value;
}
if (isset($args['action'])) {
if ($args['action'] == 'signup') {
echo '
<script src="js/cropper.js"></script>
<script src="js/profile_picture_cropper_modal.js"></script>
<script src="js/upload.js"></script>
';
} else if ($args['action'] == 'view') {
echo '<script src="js/user_actions_modal.js"></script>
';
}
}
}
?>
</footer>
</html>