From: short <> Date: Sat, 13 Oct 2001 18:19:44 +0000 (+0000) Subject: Now also _getget method supported (for _priv_postget* password fields) X-Git-Tag: rh72~16 X-Git-Url: https://git.jankratochvil.net/?p=nethome.git;a=commitdiff_plain;h=01d79ab597ddd1281d51625a057496fa564aafbe;hp=8fe8838d61eb055b5cb1533e57a075f9427920ea Now also _getget method supported (for _priv_postget* password fields) --- diff --git a/public_html/cgi-bin/postget.php b/public_html/cgi-bin/postget.php index a95466a..bc49678 100644 --- a/public_html/cgi-bin/postget.php +++ b/public_html/cgi-bin/postget.php @@ -1,14 +1,9 @@ '."\n"); -?> - - -postget -

\n"); - unset($HTTP_GET_VARS["_postget"]); foreach ($HTTP_GET_VARS as $key=>$val) { if (ereg("^_priv_(postget.*)\$",$val,$matched)) { if ($HTTP_SERVER_VARS["REMOTE_ADDR"]!="127.0.0.1") @@ -19,12 +14,41 @@ ."
" ); else - $val=chop(join(" ",file("/home/short/priv/".$matched[1],false/*use_include_path*/))); + $HTTP_GET_VARS[$key]=chop(join(" ",file("/home/short/priv/".$matched[1],false/*use_include_path*/))); + } + } + + if ($getget) { + $first='?'; + foreach ($HTTP_GET_VARS as $key=>$val) { + $where.="${first}$key=$val"; + $first='&'; } - print("\n"); + header("Location: $where"); + } + header("Content-type: text/html"); + print(''."\n"); +?> + + +postget +

\n" + ."get\n" + ."

\n"); + } + else { + print("" + ."\n" + ."

\n"); + foreach ($HTTP_GET_VARS as $key=>$val) + print("\n"); + print("\n"); + print("

\n"); } - print("\n"); - print("

\n"); ?> - +