fixing syscp-feature-request #1236 (cron doesnt delete user directories)
This commit is contained in:
@@ -63,3 +63,35 @@ function ask_yesno($text, $yesfile, $params = array(), $targetname = '')
|
||||
eval("echo \"" . getTemplate('misc/question_yesno', '1') . "\";");
|
||||
exit;
|
||||
}
|
||||
|
||||
function ask_yesno_withcheckbox($text, $chk_text, $yesfile, $params = array(), $targetname = '')
|
||||
{
|
||||
global $userinfo, $db, $s, $header, $footer, $lng;
|
||||
|
||||
$hiddenparams = '';
|
||||
|
||||
if(is_array($params))
|
||||
{
|
||||
foreach($params as $field => $value)
|
||||
{
|
||||
$hiddenparams.= '<input type="hidden" name="' . htmlspecialchars($field) . '" value="' . htmlspecialchars($value) . '" />' . "\n";
|
||||
}
|
||||
}
|
||||
|
||||
if(isset($lng['question'][$text]))
|
||||
{
|
||||
$text = $lng['question'][$text];
|
||||
}
|
||||
|
||||
if(isset($lng['question'][$chk_text]))
|
||||
{
|
||||
$chk_text = $lng['question'][$chk_text];
|
||||
}
|
||||
|
||||
$checkbox = makecheckbox('delete_userfiles', $chk_text, '1', false, '0', true, true);
|
||||
|
||||
$text = strtr($text, array('%s' => $targetname));
|
||||
eval("echo \"" . getTemplate('misc/question_yesno_checkbox', '1') . "\";");
|
||||
exit;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user