Private
Server IP : 195.201.23.43  /  Your IP : 13.59.203.127
Web Server : Apache
System : Linux webserver2.vercom.be 5.4.0-192-generic #212-Ubuntu SMP Fri Jul 5 09:47:39 UTC 2024 x86_64
User : kdecoratie ( 1041)
PHP Version : 7.1.33-63+ubuntu20.04.1+deb.sury.org+1
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/webmin/virtual-server/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /usr/share/webmin/virtual-server/wizard.cgi
#!/usr/bin/perl
# Show the multi-step post-install wizard

require './virtual-server-lib.pl';
&can_edit_templates() || &error($text{'wizard_ecannot'});
&ReadParse();

if ($in{'cancel'}) {
	# Give up on the whole wizard
	$config{'wizard_run'} = 1;
	&save_module_config();
	&redirect("");
	return;
	}

@wizard_steps = &get_wizard_steps();
$step = $wizard_steps[$in{'step'} || 0];

if ($in{'parse'} || $in{'mypass'}) {
	# Call the parse function for this step, which may return an error.
	# If so, re-display the page .. otherwise, re-direct
	$pfunc = "wizard_parse_".$step;
	if (defined(&$pfunc)) {
		$err = &$pfunc(\%in);
		&webmin_log("wizard", undef, $step);
		}
	if (!$err) {
		# Worked, show next step, if there is one
		if ($in{'step'}+1 < scalar(@wizard_steps)) {
			&redirect("wizard.cgi?step=".($in{'step'}+1));
			}
		else {
			$config{'wizard_run'} = 1;
			&save_module_config();
			&redirect("");
			}
		return;
		}
	}
elsif ($in{'prev'}) {
	# Go back to previous page
	&redirect("wizard.cgi?step=".($in{'step'}-1));
	return;
	}

&ui_print_header($text{'wizard_title_'.$step}, $text{'wizard_title'}, "");

print &ui_form_start("wizard.cgi", "post");
print &ui_hidden("step", $in{'step'});
if ($err) {
	print &ui_alert_box($err, 'warn');
	}
print &ui_table_start(undef, "width=100%", 2);

# Show step-specific inputs
$ffunc = "wizard_show_".$step;
&$ffunc();

print &ui_table_end();
if ($wizard_steps[$in{'step'}] eq 'done') {
	$cmsg = $text{'wizard_end'};
	$ctags = "style=\"font-weight: bold\"";
	}
else {
	$cmsg = $text{'wizard_cancel'};
	}
if ($wizard_steps[$in{'step'}] eq 'alldone') {
	$cmsg = undef;
	$nmsg = $text{'wizard_finish'};
	$mtags = "style=\"font-weight: bold\"";
	}
else {
	$nmsg = $text{'wizard_next'};
	}
print &ui_form_end([
		     [ "prev", $text{'wizard_prev'}, undef, !$in{'step'} ],
		     undef,
		     $cmsg ? [ "cancel", $cmsg, undef, undef, $ctags ] : undef,
		     undef,
		     [ "parse", $nmsg, undef, undef, $mtags ],
		   ], "100%");

1;

Private