c q
08-06-2002, 04:31 PM
U ppl really have to bear with me. I'm famous for making looots of stupid
errs.
Well, here's the latest.
Suppose I got a standard template called cbit.php, that,lets say looks
like...
<HTML>
<BODY>
<?php
include($HTTP_GET_VARS[target]);
?>
</BODY>
</HTML>
Ok, and I got another page, with some links. What I'm trying to do is to
pass the variable 'target' (which contains the requested filename) on to
cbit.php here's part of that code..
file : some.php
<a href='cbit.php?target="some_vague_file.php"'>Some Vague File</a>
I juss cant get why this doesn't work ! It keeps flashing err 'Use of
undefined constant target - assumed constant 'target' in E:/cbit/cbit.php
on line 43. Actually from what I understand, isn't $target supposed to
fetch the value too ?
But when I replaced the code with a simple print($HTTP_GET_VARS[target]);
still gave the same err, but also displayed the correct contents of that
variable. I even tried passing the absolute address using urlencode, but no
use.
Suggestions ???
-Niharica.
errs.
Well, here's the latest.
Suppose I got a standard template called cbit.php, that,lets say looks
like...
<HTML>
<BODY>
<?php
include($HTTP_GET_VARS[target]);
?>
</BODY>
</HTML>
Ok, and I got another page, with some links. What I'm trying to do is to
pass the variable 'target' (which contains the requested filename) on to
cbit.php here's part of that code..
file : some.php
<a href='cbit.php?target="some_vague_file.php"'>Some Vague File</a>
I juss cant get why this doesn't work ! It keeps flashing err 'Use of
undefined constant target - assumed constant 'target' in E:/cbit/cbit.php
on line 43. Actually from what I understand, isn't $target supposed to
fetch the value too ?
But when I replaced the code with a simple print($HTTP_GET_VARS[target]);
still gave the same err, but also displayed the correct contents of that
variable. I even tried passing the absolute address using urlencode, but no
use.
Suggestions ???
-Niharica.