Passing variable does not work!!!


#1

I wrote a prog which includes passing variables to an other script. the first script works as expected, but the second seems not to recognize the variables at all. I am getting always error messages… anyboby have a solution for the problem?
following my scripts:

wunschtool.php <?php

error_reporting(E_ALL);
// conversion ms in to min, sec

include (“msTominsec_Umw.php”);

// Ini
include(“connect.inc.php”);

echo "
“;
echo “”;
echo "
“;
echo “

” . $nickname .”, your Name is:

”;

echo “


. “”
. “
#

. $ident
. “
Interpret:

. $art
. “
Titel:

. str_replace("’", “’”, $tit)
. “
Duration:

. msTominsec($dur)
. “
”;

echo “


. “Enter your message:

”;

echo “<form action= ‘abschuss.php?ident&art&tit&dur’ method =‘post’”
. “on submit=‘return fcheck();’ target=‘eingebettet’>”
. “”
. “”
. “


. “”
. “”;
?>

And here the script where I was expecting to see the variables passed through from the previous script:

abschuss.php <?php include ("msTominsec_Umw.php"); error_reporting(E_ALL); // Ini include("connect.inc.php"); echo "
"; echo "
";echo "
";echo "
"; echo ""; echo ""; echo ""; echo "

" . $nickname .", Name:

"; $jetzt = time(); $wunschtime = date('d.m.Y H:i:s',$jetzt); echo $wunschtime; echo "
"; echo "
"; echo "
"; echo "" . "" . "" . "" . "" . "" . "" . "
" . $art . "" . $ident . "" . $tit . "" . msTominsec($dur) . "" . $txWidmung . "
"; ?>

I am always gettin an empty table…grrrr!

anybody can help here?

Thanks for your help!

Adriano

kraadde@yahoo.com

#2

You need to have $_POST[‘txWidmung’] instead of $txWidmung in the table or have $txWidmung = $_POST[‘txWidmung’]. The variables are being passed via the $_POST array when you called method=“post” on the other script.


#3

thanks, but it does not change anything. in fact the variable “txWidmung” is and was the only one that was passed correctly and could be “echoed” correctly…It must be something else…

kraadde


#4

Name the variables that you are not receiving. Give me something to work with.


#5

all variables passed via the form action sent in the first php are not available in the second i.e. $art ,$ident ,$tit
are not avaialble…


#6

Are your “register_globals” in the PHP.INI on or off?

If you are not receiving them then perhaps the register_globals are off, which means you would need to access the variables using the SuperGlobals of $_POST and $_GET (or the other super globals.)