countryCode}/shiny/64.png"; $data = "**User IP:** $ip\n**Date:** $TheirDate\n**Time:** $TheirTime \n**Location:** $details->city \n**Region:** $details->region\n**Country** $details->country\n**Postal Code:** $details->zip"; //=====================================DISCORD PHP BOT STUFF=========================================\\ $json_data = array ('content'=>"$data", 'username'=>"New Visitor From $details->country", 'avatar_url'=> "$flag"); $make_json = json_encode($json_data); $ch = curl_init( $webhookurl ); //==================CURL OPTIONS FOR POSTING THE INFORMATION PROVIDED ABOVE ==========================\\ curl_setopt( $ch, CURLOPT_POST, 1); curl_setopt( $ch, CURLOPT_POSTFIELDS, $make_json); curl_setopt( $ch, CURLOPT_FOLLOWLOCATION, 1); curl_setopt( $ch, CURLOPT_HEADER, 0); curl_setopt( $ch, CURLOPT_RETURNTRANSFER, 1); //===============THIS OUTPUTS THE CHANNEL SET BY THE WEBHOOK ==========================================\\ $response = curl_exec( $ch ); ?>