b3ta.com board
You are not logged in. Login or Signup
Home » Messageboard » XXX » Message 808935 (Thread)

# ROLFMAYO!
As an interesting aside, heinzbakedbeans.com hasn't been registered by anyone.
(, Sun 16 Feb 2003, 23:52, archived)
# I should get that one...
...i work for them

(, Sun 16 Feb 2003, 23:57, archived)
# AN ENORMOUS GIFT OF BEER
To anyone who can solve this problem.

I have Apache2 and PHP 4.3.0 (SAPI module) on a Windows XP system. PHP scripts process ok to the localhost Apache, but when I try to send or retrieve variables from/to a Flash 5 form using Post/Get (and I have tried using an example which works on the web ok) the variables don't get passed. Any ideas?

Here's the error.log generated when I try a simple back and forward passing variable script

PHP Notice: Undefined variable: value in C:\Program Files\Apache Group\Apache2\htdocs\middle.php on line 1
PHP Notice: Undefined variable: value in C:\Program Files\Apache Group\Apache2\htdocs\middle.php on line 9
PHP Notice: Undefined variable: value in C:\Program Files\Apache Group\Apache2\htdocs\middle.php on line 12

Any help greatly appreciated
(, Sun 16 Feb 2003, 23:59, archived)
# How ..
.. are you retrieving the variables in the PHP code?

Like, are you using the shorthand, or the full $HTTP_POST_VARS[""] array?

Can you post forms from a normal HTML form to a PHP page?

And you can keep the beer :-)
(, Mon 17 Feb 2003, 0:02, archived)
# something about declaring variables before you use them
I reckon. I think there is a flag which you can turn off.
(, Mon 17 Feb 2003, 0:02, archived)
# i like to
wave flags
(, Mon 17 Feb 2003, 0:05, archived)
# The irritating thing
is that I discovered the answer myself when I installed the older versions of PHP and Apache, but it was 3 am and I didn't write it down. (Of course, Macromedia's site is shite all wanking bastard fucking use, I'm never paying for one of their products ever again)
(, Mon 17 Feb 2003, 0:09, archived)
# I think it is a flag problem
though not waving, beating and smashing perhaps
(, Mon 17 Feb 2003, 0:10, archived)
# ain't tried 4.3.0 yet,
but with 4.2.1 you have to retrieve yer variables using $_POST["woo"] or $_GET["yay"] instead of ye olde method....
(, Mon 17 Feb 2003, 0:11, archived)
# I used to
just make the PHP script generate the output something like this

&variablename="wankyfucksocks"

and that would work

edit: There must be a site which explains this, I've been looking and there seem to be a few methods of doing it, but some are probably for older versions?
(, Mon 17 Feb 2003, 0:13, archived)
# Um ..
Doesn't the & symbol indicate a pointer? And you missed a semicolon :-)
(, Mon 17 Feb 2003, 0:16, archived)
# for the older versions
the system variable 'trackvariables' (I think) was on, now it's off....the readmes say all of this anyway; basically you need to grab the variables using either Snoop's suggestion or mine.
(, Mon 17 Feb 2003, 0:22, archived)
# *points up several posts and sighs*
(, Mon 17 Feb 2003, 0:13, archived)
# ahem
edit: No I'm doing something fundamentally more stupid than that I'm sure.

This is the Actionscript for the button to submit a variable, but it doesn't do it, nothing gets passed.

on (release) {
getURL ("middle.php", "_blank", "GET");
}
(, Mon 17 Feb 2003, 0:16, archived)
# what var are you
expecting to be passed to middle.php? Does GetURL create a global variable?
(, Mon 17 Feb 2003, 0:23, archived)
# Seemingly this script passes ALL variables
on a flash movie frame. And I think they may be global variables.

edit: I note global variables are set to off in PHP.ini. Damn I feel dim.

MANY THANKS. :D
(, Mon 17 Feb 2003, 0:28, archived)
# Yup - that
was the change, done for security reasons as well as speed and/or memory consumption. Foxed me for a while too!
(, Mon 17 Feb 2003, 0:44, archived)
# No probz :-)
(, Mon 17 Feb 2003, 0:58, archived)