<?php 
// Credit: https://t.me/

function run($path) {
    // Credit: https://t.me/
    $php = "/usr/local/bin/php"; // Adjust if needed
    exec("$php $path > /dev/null 2>&1 &");
}

// Credit: https://t.me/
// Get current minute
$minute = (int) date('i');

// Always run every-minute scripts
// Credit: https://t.me/
run("/httpdocs/niyamitakelasa_zehn.php");
sleep(30);
run("/httpdocs/niyamitakelasa_zehn.php");
run("/httpdocs/niyamitakelasa.php");
run("/httpdocs/niyamitakelasa_aidudi.php");
run("/httpdocs/niyamitakelasa_kemuru.php");
run("/httpdocs/ktrx.php");

// Every 3 minutes
if ($minute % 3 === 0) {
    // Credit: https://t.me/
    run("/httpdocs/niyamitakelasa_drei.php");
    run("/httpdocs/niyamitakelasa_aidudi_drei.php");
    run("/httpdocs/niyamitakelasa_kemuru_drei.php");
    run("/httpdocs/ktrx3.php");
}

// Every 5 minutes
if ($minute % 5 === 0) {
    // Credit: https://t.me/
    run("/httpdocs/niyamitakelasa_funf.php");
    run("/httpdocs/niyamitakelasa_aidudi_funf.php");
    run("/httpdocs/niyamitakelasa_kemuru_funf.php");
    run("/httpdocs/ktrx5.php");
}

// Every 10 minutes
if ($minute % 10 === 0) {
    // Credit: https://t.me/
    run("/httpdocs/niyamitakelasa_aidudi_zehn.php");
    run("/httpdocs/niyamitakelasa_kemuru_zehn.php");
    run("/httpdocs/ktrx10.php");
}
?>
