Geir Anders Berge wrote:
> I'm sure that this code can be written more efficient, please tell me how,
> but that's not my problem. The problem is that when i run this script all
> lines are executed. I'm sure I'm doing something wrong, but can't find out
> just what.
Okay, it's REALLY hard to see
more stuff
}
else
{
other stuff
}
}
else
{
even more stuff
}
M
-Original Message-
From: Geir Anders Berge [mailto:[EMAIL PROTECTED]
Sent: 28 January 2005 19:05
To: php-general@lists.php.net
Subject: [PHP] Some questions about i
[snip]
$constant)
{
Execute this code if $variable is more than $constant
}
elseif ($variable == $constant)
{
Execute this code if $variable and $constant are equal
}
}
else
{
Execute this code if $variable is not set
}
?>
--
PHP General Mai
I'm sure that this code can be written more efficient, please tell me how,
but that's not my problem. The problem is that when i run this script all
lines are executed. I'm sure I'm doing something wrong, but can't find out
just what.
$constant)
{
Execute this code if $varia
On Friday 03 January 2003 06:15 am, Gareth Hastings wrote:
> Yes I saw those but what it made me think, what's the point of a
> persistent socket if you can't use it again?
i think you could, after enough iterations and if the server allows,
get to a point where each process has its own persiste
Well if you do find the solution please let us know. I would also like to add it to my
PHP lib archive.
I suppose it would be there for stuff like command line PHP.
Mike
*** REPLY SEPARATOR ***
On 02/01/2003 at 5:15 PM Gareth Hastings wrote:
>Yes I saw those but what it mad
here is one about. Anyway back to google :)
> -Original Message-
> From: Michael J. Pawlowsky [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 02, 2003 5:10 PM
> To: Gareth Hastings; [EMAIL PROTECTED]
> Subject: RE: [PHP] Some questions regarding pfsocketopen()
>
Two comments from the manual that are interesting:
php dot net at domainofdarkness dot com
29-Jan-2001 04:26
OK, WRT to the p* functions opening a new connection when one already exists. It is my
understanting that (under Apache anyways) this is on a per-process basis. If you do a
'ps auxw|gr
t :/
> -Original Message-
> From: Michael J. Pawlowsky [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 02, 2003 4:32 PM
> To: Gareth Hastings
> Cc: [EMAIL PROTECTED]
> Subject: RE: [PHP] Some questions regarding pfsocketopen()
>
>
> Well I didnt try to wr
Well I didnt try to write or read to it...
But this works But all that's telling me is that the var is there.. not if it's
still open.. will leave that to you to find out... Let us know
--file s1.php ---
Next";
?>
file s2
Cool... Maybe I will learn something.. :-)
Well in that case (I already deleted you last mail), where are you keeping the file
pointer?
You will need to register the var somewhere.. In a session perhaps?
Mike
Send me your code... I will play with it...
*** REPLY SEPARATOR **
> You will need to have everythng on the same page. Your program ends
once
> the page does.
pfsocketopen() is persistent and stays open even after your script has
finished running until either the timeout period is reached or it gets
disconnected/closedI think. I just don't know how to acc
You will need to have everythng on the same page. Your program ends once the page
does.
Here are some examples straight from the manual.
\n";
} else {
fputs ($fp, "GET / HTTP/1.0\r\nHost: www.example.com\r\n\r\n");
while (!feof($fp)) {
echo fgets ($fp,128);
}
fclose ($f
file resource error.
> -Original Message-
> From: Chris Shiflett [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, January 02, 2003 2:47 PM
> To: Gareth Hastings; 'PHP-List'
> Subject: Re: [PHP] Some questions regarding pfsocketopen()
>
> --- Gareth Hastings
--- Gareth Hastings <[EMAIL PROTECTED]> wrote:
> Could anyone tell me, is it possible to connect to
> a persistent socket after it has been opened by a
> different script?
Sure. Think of it like a persistent database connection in
Oracle, where the listener is on socket 1521 for everyone.
The per
Could anyone tell me, is it possible to connect to a persistent socket
after it has been opened by a different script? There is little
documentation on this function. I did a quick search on google and lots
of people say you can't, some say you can but its really hard and the
rest go..."pf what??"
CTED]>
Sent: Tuesday, August 13, 2002 12:21 PM
Subject: Re: [PHP] Some questions.
> on 13/08/02 3:42 AM, mintbaggio ([EMAIL PROTECTED]) wrote:
>
> > I'm a Chinese university student,I want to ask some questions about
session.
> > These days I'm build a website for my uni
on 13/08/02 3:42 AM, mintbaggio ([EMAIL PROTECTED]) wrote:
> I'm a Chinese university student,I want to ask some questions about session.
> These days I'm build a website for my university with PHP, But I meet a
> question when I develop the part of User Management: After I have log out
> from a
g alphanumeric characters and you can
compare like this
if ($_GET["login"] == $registered_login && $_GET["ses"] == session_id())
// ok autenticated
else
// error: not autenticated
>From: "mintbaggio" <[EMAIL PROTECTED]>
>To: <>
>Sub
Hello
I'm a Chinese university student,I want to ask some questions about session.
These days I'm build a website for my university with PHP, But I meet a
question when I develop the part of User Management: After I have log out
from a user page(I use "session_unset()" and "session_destroy()
How about the sessions?
doesn't sessions also needs to send header data (before any other output)?
the sessions are registered normally..
At 17:07 12/11/01 -0800, Christopher William Wesley wrote:
>Your problem probably is including the miec.php from the .shtml
>document. Does the .shtml docum
But what about the session? It get's registered... doesn't sessions also
need to send header information?
it gets registered... it just doesn't persist...
At 17:07 12/11/01 -0800, you wrote:
>Your problem probably is including the miec.php from the .shtml
>document. Does the .shtml document sen
Your problem probably is including the miec.php from the .shtml
document. Does the .shtml document send any output to the browser before
including your .php script? If so, you're not going to be able to send
any cookies from the .php script. Once any standard output makes it to
the browser (inc
I've recently had a problem with sessions, and came up with a problem that
apparently has no solution...
I want to understand why EXACTLY it does't work...
From what I understand about sessions (reading PHP Docs), cookies are
default and URLs holding the session_id are used if the cookies can
Does anyone here use PHPUnit?
1. If a test script needs some external input to do testing
(notably, database connect info), is it a good idea to present
an HTML form to ask input from user? Or should it also be able
to prompt the user for these in case the test script is run by the PHP binary.
25 matches
Mail list logo