,
- Original Message -
From: Richard Lynch [EMAIL PROTECTED]
To: james tu [EMAIL PROTECTED]
Cc: php-general@lists.php.net
Sent: Wednesday, March 30, 2005 12:34 AM
Subject: Re: [PHP] POST variables from a link...and popup new window
On Tue, March 29, 2005 1:09 pm, james tu said:
I have a link
Hi:
I have a link that, when clicked on, pops up a new window.
I want to use the POST method in order to pass information. Right now
I'm appending the parameters to the URL of the link and using GET to
retrieve the name/value pairs.
Is there a way to do this?
--
-James
--
PHP General Mailing
james tu wrote:
Hi:
I have a link that, when clicked on, pops up a new window.
I want to use the POST method in order to pass information. Right now
I'm appending the parameters to the URL of the link and using GET to
retrieve the name/value pairs.
Is there a way to do this?
Yes.
--
John C.
On Tue, March 29, 2005 1:09 pm, james tu said:
I have a link that, when clicked on, pops up a new window.
I want to use the POST method in order to pass information. Right now
I'm appending the parameters to the URL of the link and using GET to
retrieve the name/value pairs.
form
-
From: julian haffegee [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, February 18, 2004 1:58 PM
Subject: Re: [PHP] post variables
Hi Chris
print_r($_REQUEST); (is this what you mean by HTTP Request?)
print_r($_POST);
print_r($_GET);
all give Array()
its apache release
On Thursday 19 February 2004 13:32, julian haffegee wrote:
Hi all,
I solved this today. It seems odd.
If you define an action it DOES NOT work, but if you skip that entirely the
POST variables are sent!
so
form method='POST' works
form method='POST' action ='something.php' doesn't
Hi Chris
print_r($_REQUEST); (is this what you mean by HTTP Request?)
print_r($_POST);
print_r($_GET);
all give Array()
its apache release 10327100 (is that what you mean?)
If I change the form method to GET works, and we get
REQUEST: Array ( [username] = aa [password] = aa )
_GET: Array (
Hi all,
I am having a nightmare accessing my POST variables. I can red them if I use
the GET method on my form, but POST is always blank
I have
while( list($key, $value) = each ($_POST)){
print $key $valuebr;
}
print _REQUEST: ; print_r($_REQUEST);
print _GET: ; print_r($_GET);
print _POST:
I can't think of a reason for this, so I would doublecheck your
assumptions. There is a $_SERVER variable to check the method.
You might want to put the php printenv.php page in place of your current
script to see what it says about the request method and POST variables.
- Lucas
On Tue, 17
Is it possible to ban subscribers who issue this kind of auto-response?
-- Forwarded message --
Date: Tue, 17 Feb 2004 21:33:04 -
From: Alan Hale [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: Re: [PHP] post variables (SpamEnder: BLOCKED
[EMAIL PROTECTED
Hello julian,
Tuesday, February 17, 2004, 9:20:58 PM, you wrote:
jh I am having a nightmare accessing my POST variables. I can red them if I use
jh the GET method on my form, but POST is always blank
A *lot* of people are reporting this as of late and I'm beginning to
wonder what the true cause
Lucas Gonze mailto:[EMAIL PROTECTED]
on Tuesday, February 17, 2004 2:00 PM said:
Is it possible to ban subscribers who issue this kind of
auto-response?
i just wish people were smart enough to understand that no one cares
about the spam in the other persons mailbox. we only care about the
] [EMAIL PROTECTED]
Sent: Tuesday, February 17, 2004 11:22 PM
Subject: Re: [PHP] post variables
Hello julian,
Tuesday, February 17, 2004, 9:20:58 PM, you wrote:
jh I am having a nightmare accessing my POST variables. I can red them if
I use
jh the GET method on my form, but POST is always blank
--- julian haffegee [EMAIL PROTECTED] wrote:
Hi Richard
yes it happens in Netscape 7 too,
The thing is, it works in perl when I access the query string. But not
in php.
could it be a setting in php.ini?
Do you have a way to capture the raw HTTP? I'd like to see:
1. The HTTP Request
2.
On Mon, Oct 27, 2003 at 03:00:32AM -0200, Joao Andrade wrote:
:
: Hey people,
:
: Something odd is happening :) I've this form on a page:
:
: form method=post action=\basics\quotation-add
Backslashes are allowed?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe,
A funny thing was happeng with a GET variable here, after testing it
with an if clause, it would be set to 1, like this, after that:
if ( $_POST['nova'] =! )
$_POST['nova'] = 1... Is that alright?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
[snip]
A funny thing was happeng with a GET variable here, after testing it
with an if clause, it would be set to 1, like this, after that:
if ( $_POST['nova'] =! )
$_POST['nova'] = 1... Is that alright?
[/snip]
GET (see your question) or POSTnot that it matters.
--- Joao Andrade [EMAIL PROTECTED] wrote:
form method=post action=\basics\quotation-add
Windowsitis? Mind your slashes.
Also, you should quote HTML attributes (though this isn't your problem). So,
try this:
form action=/basics/quotation-add method=post
tdinput type=text size=30
--- Joao Andrade [EMAIL PROTECTED] wrote:
if ( $_POST['nova'] =! )
Equal not? Perhaps you mean not equal? :-)
Chris
=
My Blog
http://shiflett.org/
HTTP Developer's Handbook
http://httphandbook.org/
RAMP Training Courses
http://www.nyphp.org/ramp
--
PHP General Mailing
This may be a dumb question but here goes. I have been trying to use $_POST
globals in sql queries.
If I use the following query string it does not work
$query=Select * from users where userid='$_POST['userid']';
However, this works
$userid=$_POST[userid]
$query=Select * from users where
--- Luis Lebron [EMAIL PROTECTED] wrote:
$query=Select * from users where userid='$_POST['userid']';
Use curly braces:
$query = select * from users where userid = '{$_POST['userid']}';
Hope that helps.
Chris
=
My Blog
http://shiflett.org/
HTTP Developer's Handbook
Luis Lebron wrote:
snip
If I use the following query string it does not work
$query=Select * from users where userid='$_POST['userid']';
snip
Use curly braces to eval array elements inside of a string
$query = SELECT * FROM users WHERE userid='{$_POST['userid']}';
--
By-Tor.com
It's all
Hey people,
Something odd is happening :) I've this form on a page:
form method=post action=\basics\quotation-add
table
tr
thAuthor
tdinput type=text size=30 name=author_name
/tr
tr
thNew Category
tdinput type=text size=30 name=new
/tr
tr
thCategory
tdselect name=category
?php
:30 AM
Subject: [PHP] Post variables getting lost
Hey people,
Something odd is happening :) I've this form on a page:
form method=post action=\basics\quotation-add
table
tr
thAuthor
tdinput type=text size=30 name=author_name
/tr
tr
thNew Category
tdinput type=text size
Hey,
So I've got this form that passes POST variables. However, they keep
getting passed as get variables. Example:
form action=?php echo $_SERVER['PHP_SELF']; ? method=post
input type=hidden name=action value=something
input type=submit value= Action
/form
Get's sent to it as:
This has absolutley nothing to do with PHP, and is a client-side issue.
Michael A Smith wrote:
Hey,
So I've got this form that passes POST variables. However, they keep
getting passed as get variables. Example:
form action=?php echo $_SERVER['PHP_SELF']; ? method=post
input type=hidden
Hello,
I am trying to make a script that looks something like:
for ($i=0; $i=12; $i++)
{
echo select name='$i';
echo option values;
}
Then I am posting those to another page, and trying to get the data out
for ($i=0; $i=12; $i++)
{
echo $_POST['$i'];
}
And it doesn't work. Any
--- Brad Bonkoski [EMAIL PROTECTED] wrote:
for ($i=0; $i=12; $i++)
{
echo select name='$i';
echo option values;
}
You only want one select tag.
Chris
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
The problem is right here:
for ($i=0; $i=12; $i++)
{
echo $_POST['$i'];
}
Single quotes cause variables to not be interpolated. IE:
?php
$i = 5;
echo $i;
echo $i;
echo '$i';
?
this prints out:
55$i
See? Change that line to
echo $_POST[$i];
and it should work just fine.
Regards,
A while back somebody answered a question about some PHP code that would
take the $HTTP_POST_VARS and create the SQL that would write them to a
MySQL table (provided the posted var names matches the MySQL
fieldnames).
Does anyone have info on that project? The PHP searchable archive is
30 matches
Mail list logo