php-windows Digest 18 Aug 2004 21:26:27 -0000 Issue 2365
Topics (messages 24429 through 24433):
Re: Newbie working with PHP 5.0, IIS, Win2000
24429 by: Sudeep Zamudra
Graphical popup wiindow on link mouseover
24430 by: Jim MacDiarmid
24432 by: Justin Patrin
Re: using the mail function in php
24431 by: Justin Patrin
24433 by: neil
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
Hi chuck,
As far as the "Notices" are concerned you can disable it from php.ini configuration
file.
Regards,
SuDeEp
Chuck <[EMAIL PROTECTED]> wrote:
Hello everyone. Hopefully someone can help me with this.
I was able to install PHP successfully. I tried a sample script and it
worked fine through IE. I then tried to create a script that would pass a
value on to another script using the post method. These are called Pass.php
and Pass1.php.
Pass.php contains the following.
Name: [input]
Email: [input]
[input]
Pass1.php contains the following.
// Available since PHP 4.1.0
echo $_POST['username'];
echo $_REQUEST['username'];
import_request_variables('p', 'p_');
echo $p_username;
// Available since PHP 3. As of PHP 5.0.0, these long predefined
// variables can be disabled with the register_long_arrays directive.
echo $HTTP_POST_VARS['username'];
// Available if the PHP directive register_globals = on. As of
// PHP 4.2.0 the default value of register_globals = off.
// Using/relying on this method is not preferred.
echo $username;
?>
This is the output I received from this.
CGI Error
The specified CGI application misbehaved by not returning a complete set of
HTTP headers. The headers it did return are:
PHP Notice: Undefined index: username in C:\Web\Pass1.php on line 4
PHP Notice: Undefined index: username in C:\Web\Pass1.php on line 5
PHP Notice: Undefined variable: p_username in C:\Web\Pass1.php on line 8
PHP Notice: Undefined variable: HTTP_POST_VARS in C:\Web\Pass1.php on line
13
PHP Notice: Undefined variable: username in C:\Web\Pass1.php on line 19
I then replaced Pass1.php with the following code to check for any data that
was being posted.// This will check for posted values
$empty = $post = array();
foreach ($_POST as $varname => $varvalue) {
if (empty($varvalue)) {
$empty[$varname] = $varvalue;
} else {
$post[$varname] = $varvalue;
}
}
print "
";
if (empty($empty)) {
print "None of the POSTed values are empty, posted:\n";
var_dump($post);
} else {
print "We have " . count($empty) . " empty values\n";
print "Posted:\n"; var_dump($post);
print "Empty:\n"; var_dump($empty);
exit;
}
?>
This supplied the following output.
CGI Error
The specified CGI application misbehaved by not returning a complete set of
HTTP headers. The headers it did return are:
// This will check for posted values
None of the POSTed values are empty, posted:
array(0) {
}
I would really appreciate if someone could help me figure out what is going
on.
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
--- End Message ---
--- Begin Message ---
Hi everyone,
I have a link on a page and I would like to present dynamic list of names in
graphical popup "window" ( and I use this term loosely) at the cursor
position when a mouseover or the link is done. I don't want a "browser"
window to popup but rather something like resembles a floating square or
layer with a border perhaps.
I've been doing some research and I am aware that you can use the title
attribute of the <a href> tag, I'd like to do something a little bigger. Has
anyone ever done this before?
Thanks in advance,
Jim
--- End Message ---
--- Begin Message ---
On Wed, 18 Aug 2004 11:56:03 -0400, Jim MacDiarmid
<[EMAIL PROTECTED]> wrote:
>
> Hi everyone,
>
> I have a link on a page and I would like to present dynamic list of names in
> graphical popup "window" ( and I use this term loosely) at the cursor
> position when a mouseover or the link is done. I don't want a "browser"
> window to popup but rather something like resembles a floating square or
> layer with a border perhaps.
>
> I've been doing some research and I am aware that you can use the title
> attribute of the <a href> tag, I'd like to do something a little bigger. Has
> anyone ever done this before?
>
http://www.bosrup.com/web/overlib/
Very nice.
Optionally, if you don't want to use someone else's code, use a div
which is absolutely positioned and use onblur in your link tag.
But I suggest using overlib. ;-)
--
DB_DataObject_FormBuilder - The database at your fingertips
http://pear.php.net/package/DB_DataObject_FormBuilder
paperCrane --Justin Patrin--
--- End Message ---
--- Begin Message ---
On Wed, 18 Aug 2004 17:38:45 +1000, neil <[EMAIL PROTECTED]> wrote:
> Thanks Lenny
>
> The stripslashes worked. I didn't think to use it as there was no slashes to
> strip. But since it puts it in they need to be removed.
>
How many times must I say this? If you see slashes, THERE ARE SLASHES
IN THE STRING! If stripslashes removes them, they had to be in there
in the first place. Period. End of story.
> Neil
>
> "Lenny Davila" <[EMAIL PROTECTED]> wrote in message
> news:[EMAIL PROTECTED]
>
>
> Try using the strip slashes http://us3.php.net/stripslashes
>
> stripslashes($messageVariable);
>
--
DB_DataObject_FormBuilder - The database at your fingertips
http://pear.php.net/package/DB_DataObject_FormBuilder
paperCrane --Justin Patrin--
--- End Message ---
--- Begin Message ---
Hi Justin
I'm not sure I appreciate the aggro. I am new to .php and so this is a
learning exercise for me.
THERE IS NO SLASHES in the data being submitted so obviously something is
putting them in.
So again thank you for your help - the stripslashes did work.
Neil
"Justin Patrin" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> On Wed, 18 Aug 2004 17:38:45 +1000, neil <[EMAIL PROTECTED]> wrote:
> > Thanks Lenny
> >
> > The stripslashes worked. I didn't think to use it as there was no
slashes to
> > strip. But since it puts it in they need to be removed.
> >
>
> How many times must I say this? If you see slashes, THERE ARE SLASHES
> IN THE STRING! If stripslashes removes them, they had to be in there
> in the first place. Period. End of story.
>
> > Neil
> >
> > "Lenny Davila" <[EMAIL PROTECTED]> wrote in message
> > news:[EMAIL PROTECTED]
> >
> >
> > Try using the strip slashes http://us3.php.net/stripslashes
> >
> > stripslashes($messageVariable);
> >
> --
> DB_DataObject_FormBuilder - The database at your fingertips
> http://pear.php.net/package/DB_DataObject_FormBuilder
>
> paperCrane --Justin Patrin--
--- End Message ---