Exemple #1
0
function deletehtaccess()
{
    include 'lang/' . GetPrefdLang($personalinfo['ap_language_vc']) . '.php';
    if (file_exists(GetSystemOption('zpanel_root') . "apps/phpsysinfo/.htaccess")) {
        unlink(GetSystemOption('zpanel_root') . "apps/phpsysinfo/.htaccess");
    }
    if (file_exists(GetSystemOption('zpanel_root') . "apps/phpsysinfo/phpsysinfo.htpasswd")) {
        unlink(GetSystemOption('zpanel_root') . "apps/phpsysinfo/phpsysinfo.htpasswd");
    }
    echo '<div class="zannouce">' . $lang['348'] . '</div><br>';
}
Exemple #2
0
 * This program (ZPanel) is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 */
include 'conf/zcnf.php';
include 'lang/' . GetPrefdLang($personalinfo['ap_language_vc']) . '.php';
include 'inc/zAccountDetails.php';
$sql = "SELECT * FROM z_cronjobs WHERE ct_acc_fk=" . $useraccount['ac_id_pk'] . " AND ct_deleted_ts IS NULL";
$listtasks = DataExchange("r", $z_db_name, $sql);
$rowtasks = mysql_fetch_assoc($listtasks);
$totaltasks = DataExchange("t", $z_db_name, $sql);
echo $lang['120'] . "<br>";
if (isset($_GET['r']) && $_GET['r'] == 'ok') {
    echo "<br><div class=\"zannouce\">" . $lang['394'] . "</div>";
}
if (isset($_GET['r']) && $_GET['r'] == 'blank') {
    echo "<br><div class=\"zannouce\">" . $lang['300'] . "</div>";
}
if (isset($_GET['r']) && $_GET['r'] == 'noexists') {
    echo "<br><div class=\"zannouce\">" . $lang['301'] . " " . $useraccount['ac_user_vc'] . "</div>";
}
Exemple #3
0
function adduser($ht_acc_fk, $ht_user_vc, $ht_dir_vc, $htusername, $htpassword1, $htpassword2)
{
    include 'lang/' . GetPrefdLang($personalinfo['ap_language_vc']) . '.php';
    if (!empty($htpassword1) && !empty($htpassword2) && $htpassword1 == $htpassword2) {
        $result = mysql_query("SELECT * FROM `z_htaccess` WHERE `ht_acc_fk` ='" . $ht_acc_fk . "' AND `ht_dir_vc` = '" . $ht_dir_vc . "'");
        $row = mysql_fetch_assoc($result);
        system(GetSystemOption('htpasswd_exe') . " -b -m " . GetSystemOption('zpanel_root') . "/modules/advanced/htpasswd/files/" . $row['ht_id_pk'] . ".htpasswd " . $htusername . " " . $htpassword1 . "");
        echo '<div class="zannouce">' . $lang['335'] . trim(substr($ht_dir_vc, strlen(GetSystemOption('hosted_dir')), strlen($ht_dir_vc))) . '</div><br>';
    } else {
        echo '<div class="zannouce">' . $lang['336'] . '</div><br>';
    }
}