⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 save_other.cgi

📁 Unix下基于Web的管理工具
💻 CGI
字号:
#!/usr/local/bin/perl# save_other.cgirequire './lilo-lib.pl';&ReadParse();$conf = &get_lilo_conf();if ($in{'delete'}) {	# deleting an existing partition	&save_directive($conf, $conf->[$in{'idx'}]);	&flush_file_lines();	&redirect("");	exit;	}elsif ($in{'new'}) {	# creating a new boot partition	$other = { 'name' => 'other',		   'members' => [ ] };	}else {	# updating an existing image	$oldother = $other = $conf->[$in{'idx'}];	}# Validate and store inputs$in{'label'} =~ /\S+/ || &error($text{'other_ename'});&save_subdirective($other, "label", $in{'label'});$other->{'value'} = $in{'other'};if ($in{'tablemode'} == 0) {	&save_subdirective($other, "table");	}else {	&save_subdirective($other, "table", $in{'table'});	}if ($in{'passmode'} == 0) {	&save_subdirective($other, "password");	}else {	&save_subdirective($other, "password", $in{'password'});	}# Save the actual partition structure&save_directive($conf, $oldother, $other);&flush_file_lines();&redirect("");

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -