bootdisk: f1.cgi (NEW) index2.cgi (NEW) index.cgi (NEW)

juandon juandon w pld.org.pl
Wto, 7 Sty 2003, 19:47:17 CET


Module name:	bootdisk
Changes by:	juandon	03/01/07 19:47:14

Added files:
	f1.cgi index2.cgi index.cgi

Log message:
- html engine

--- NEW FILE: f1.cgi ---
#!/bin/sh

decode_percent_20 () {
    local begin, middle, rest, ch
    ch=
    begin=
    middle=
    rest=$@
    while [ "$middle" != "$rest" ]
    do
	begin=$begin$middle$ch
	middle=${rest%%%20*}
	rest=${rest#*%20}
	ch=" "
    done
    begin=$begin$middle
    echo $begin
}

decode_percent_2F () {
    local begin, middle, rest, ch
    ch=
    begin=
    middle=
    rest=$@
    while [ "$middle" != "$rest" ]
    do
	begin=$begin$middle$ch
	middle=${rest%%%2F*}
	rest=${rest#*%2F}
	ch="/"
    done
    begin=$begin$middle
    echo $begin
}

decode_plus () {
    local begin, middle, rest, ch
    ch=
    begin=
    middle=
    rest=$@
    while [ "$middle" != "$rest" ]
    do
	begin=$begin$middle$ch
	middle=${rest%%+*}
	rest=${rest#*+}
	ch=" "
    done
    begin=$begin$middle
    echo $begin
}

. /home/users/witek/public_html/installer.conf

string=$QUERY_STRING
string=`decode_percent_20 $string`
string=`decode_percent_2F $string`
string=`decode_plus $string`

while [ "x$string" != "x" ]
do
    string2=$string
    begin=${string%%&*}
    string=${string#*&}
    if [ $string2 = $string ]
    then
	string=
    fi
    eval $begin   
done

. index2.cgi

--- NEW FILE: index2.cgi ---
#!/bin/sh

echo "Content-Type: text/html"
echo
cat <<EOF
<?xml version="1.0" encoding="iso-8859-2"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>No title</title>
<meta generator="index.cgi" />
</head>
<body>
<table border="1">
<tbody>
<tr>
<td>
<form name="f1" action="f1.cgi" method="GET">
source is one of:
<ul>
<li>net - ftp, http. source_filesystem has to be net</li>
<li>nfs - nfs server. source_filesystem has to be nfs</li>
<li>cdrom</li>
<li>disk</li>
</ul>
<p>	source =<input type="text" name="source" value="$source" maxlength="10"/></p>
<p>	source_device: either dev/XXX for mount, or machine for nfs, or
server name with optional protocol for net, ftp:// is the default</p>
<p>	source_device = <input type="text" name="source_device" value="$source_device"/></p>
<p>	source_filesystem: ex: iso9660, ext2</p>
<p>	source_filesystem =<input type="text" name="source_filesystem" value="$source_filesystem"/></p>
<p>	source_dir: exact directory where installation files (RPMS and installer directory)
reside</p>
<p>	source_dir = <input type="text" name="source_dir" value="$source_dir"/></p>
<p><input type="submit" /></p>
</form>
</td>
<td>
<form name="f1" action="f1.cgi" method="GET">
<p> source =<select size="4" name="source">
<option>net</option>
<option>nfs</option>
<option selected >cdrom</option>
<option>disk</option>
</select></p>
<p><input type="submit" /></p>
</form>
<hr>
<form name="f1" action="f1.cgi" method="GET">
<p>source_device =<select size="8" name="source_device">
<option>/dev/hda</option>
<option>/dev/hdb</option>
<option selected >/dev/hdc</option>
<option>/dev/hdd</option>
<option>/dev/scd1</option>
<option>/dev/scd2</option>
<option>/dev/scd3</option>
<option>/dev/scd4</option>
</select></p>
<p><input type="submit" /></p>
</form>
<hr> 
<form name="f1" action="f1.cgi" method="GET">
<p>source_filesystem =<select size="8" name="source_filesystem">
<option>none</option>
<option selected >iso9660</option>
<option>ext2</option>
<option>ext3</option>
<option>jfs</option>
<option>reiserfs</option>
<option>vfat</option>
<option>xfs</option>
</select></p>
<p><input type="submit" /></p>
</form>
<hr>
<form name="f1" action="f1.cgi" method="GET">
<p> source_dir =<input type="text" name="source_dir" value="/" /></p>
<p><input type="submit" /></p>
</form>
</td>
</tr>
<tr>
<td>
<form name="f1" action="f1.cgi" method="GET">
net_device =<input type="text" name="net_device" value="$net_device" />
<p>net_device_module =<input type="text" name="net_device_module" value="$net_device_module" /></p>
<p>net_device_module_options =<input type="text" name="net_device_module_options" value="$net_device_module_options" /></p>
<p>net_device_ipaddr =<input type="text" name="net_device_ipaddr" value="$net_device_ipaddr" /></p>
<p>net_device_prefix =<input type="text" name="net_device_prefix" value="$net_device_prefix" /></p>
<p>net_gateway =<input type="text" name="net_device_gateway" value="$net_gateway" /></p>
<p>net_dns =<input type="text" name="net_dns" value="$net_dns" /></p>
<p>net_v6 =<input type="text" name="net_v6" value="$net_v6" /></p>
<p>net_proxy =<input type="text" name="net_proxy" value="$net_proxy" /></p>
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
scsi_hostadapters =<input type="text" name="scsi_hostadapter" value="$scsi_hostadapters" />
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
pcmcia_controller =<input type="text" name="pcmcia_controller" value="$pcmcia_controller" />
<p><input type="submit"/></p>
</form>
</td>			
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
dest_devices =<input type="text" name="dest_devices" value="$dest_devices" />
<p>dest_devices_actions =<input type="text" name="dest_devices_actions" value="$dest_devices_actions" /></p>
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
dest_part1_device =<input type="text" name="dest_part1_device" value="$dest_part1_device" />
<p>dest_part1_size =<input type="text" name="dest_part1_size" value="$dest_part1_size" /></p>
<p>dest_part1_filesystem =<input type="text" name="dest_part1_filesystem" value="$dest_part1_filesystem" /></p>
<p>dest_part1_format_partition =<input type="text" name="dest_part1_format_partition" value="$dest_part1_format_partition" /></p>
<p>dest_part1_mnt_point =<input type="text" name="dest_part1_mnt_point" value="$dest_part1_mnt_point" /></p>
<p>dest_part1_options =<input type="text" name="dest_part1_options" value="$dest_part1_options" /></p>
<p>dest_part1_format_options =<input type="text" name="dest_part1_format_options" value="$dest_part1_format_options" /></p>
<p>dest_part2_device =<input type="text" name="dest_part2_device" value="$dest_part2_device" /></p>
<p>dest_part2_size =<input type="text" name="dest_part2_size" value="$dest_part2_size" /></p>
<p>dest_part2_filesystem =<input type="text" name="dest_part2_filesystem" value="$dest_part2_filesystem" /></p>
<p>dest_part2_format_partition =<input type="text" name="dest_part2_format_partition" value="$dest_part2_format_partition" /></p>
<p>dest_part2_options =<input type="text" name="dest_part2_options" value="$dest_part2_options" /></p>
<p>dest_part2_format_options =<input type="text" name="dest_part2_format_options" value="$dest_part2_format_options" /></p>
<p>dest_part3_device =<input type="text" name="dest_part3_device" value="$dest_part3_device" /></p>
<p>dest_part3_size =<input type="text" name="dest_part3_size" value="$dest_part3_size" /></p>
<p>dest_part3_filesystem =<input type="text" name="dest_part3_filesystem" value="$dest_part3_filesystem" /></p>
<p>dest_part3_format_partition =<input type="text" name="dest_part3_format_partition" value="$dest_part3_format_partition" /></p>
<p>dest_part3_options =<input type="text" name="dest_part3_options" value="$dest_part3_options" /></p>
<p>dest_part3_format_options =<input type="text" name="dest_part3_format_options" value="$dest_part3_format_options" /></p>
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
pkgs_installer =<input type="text" name="pkgs_installer" value="$pkgs_installer" />
<p>pkgs_install_doc =<input type="text" name="pkgs_install_doc" value="$pkgs_install_doc" /></p>
<p>pkgs_install_langs =<input type="text" name="pkgs_install_langs" value="$pkgs_install_langs" /></p>
<p>pkgs_cpus =<input type="text" name="pkgs_cpus" value="$pkgs_cpus" /></p>
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
<tr>
<td><form name="f1" action="f1.cgi" method="GET">
boot_loader=<input type="text" name="boot_loader" value="$boot_loader"
<p>boot_loader_device =<input type="text" name="boot_loader_device" value="$boot_loader_device" /></p>
<p>boot_loader_other =<input type="text" name="boot_loader_other" value="$boot_loader_other" /></p>
<p><input type="submit" /></p>
</form>
</td>
<td></td>
</tr>
</tbody>
</table>
</body>
</html>
EOF

--- NEW FILE: index.cgi ---
#!/bin/sh

. /etc/installer.conf
. index2.cgi



Więcej informacji o liście dyskusyjnej pld-installer