Hi all, I've found the key of all... at least this is what I think ;-)
(And, again, at least, for Debian users)
The thing is I want to have control on what exactly a session lasts,
and advice the user some time before to renew the session if he wants.
If you only set gc_maxlifetime with
Rashmi Badan wrote:
Hi,
I'm using php 5.2.1 with apache 2.2.6 and while running certain tests I see
a segmentation fault - the relevant stack is given below. My php configure
line is as follows
configure '--prefix=/my/php/installdir' *'--with-tsrm-pthreads' *'--with-ldap'
LKSunny wrote:
i know stats_harmonic_mean(), but i am not server admin, i can't install
PECL, so i need make it by manual, but i have't Statistics knowledge, any
one can help me ? thank you very much !!
I doubt anyone is going to write a php version of that function for you.
given that you
At 10:02 AM +0200 12/14/07, Arno Kuhl wrote:
I'm battling with getting the last week number using date(W, $unixdate). If
the date is 30 December 2007 ($unixdate=1198965600)
Not accordingly to my calculations -- try it:
http://webbytedd.com/c/unix-time/
Cheers,
tedd
--
---
-Original Message-
From: tedd [mailto:[EMAIL PROTECTED]
Sent: 14 December 2007 04:50
To: [EMAIL PROTECTED]; php-general@lists.php.net
Cc: Arno Kuhl
Subject: Re: [PHP] PHP date: ISO year = loss of hair
At 10:02 AM +0200 12/14/07, Arno Kuhl wrote:
I'm battling with getting the last week
At 11:59 PM -0500 12/12/07, Robert Cummings wrote:
On Wed, 2007-12-12 at 16:21 -0500, tedd wrote:
Yeah, but we haven't proven order yet either. :-)
Order exists all around us.
Maybe around you, but I have a wife, two daughters, and four female
grandchildren.
I only need to look around
tedd wrote:
At 11:59 PM -0500 12/12/07, Robert Cummings wrote:
On Wed, 2007-12-12 at 16:21 -0500, tedd wrote:
Yeah, but we haven't proven order yet either. :-)
Order exists all around us.
Maybe around you, but I have a wife, two daughters, and four female
grandchildren.
that would
On Dec 14, 2007 3:02 AM, Arno Kuhl [EMAIL PROTECTED] wrote:
I'm battling with getting the last week number using date(W, $unixdate). If
the date is 30 December 2007 ($unixdate=1198965600) then date(W, $unixdate)
returns 01. I know that according to the ISO spec, the last week of the ISO
year
On Dec 14, 2007 9:35 AM, tedd [EMAIL PROTECTED] wrote:
* You know, the point -- what we were talking about, not a point
on the top of my head. :-)
Beldar, when the High Master hears what you have said, he will
surely cut off your phlarg and hand it to you.
--
Daniel P. Brown
[Phone
Hi NG!
I'm having some trouble with my MIME mails.
When I send an email with txt and html format, it all works perfectly in
every type of mailclient i could possibly think of.
But when I attach files, gmail and yahoo doesn't show what i expected.
Thunderbird and Outlook/outlook express
i know it can make simple function, if have Statistics knowledge...
reference:
http://en.wikipedia.org/wiki/Harmonic_Mean
Jochem Maas [EMAIL PROTECTED]
???:[EMAIL PROTECTED]
LKSunny wrote:
i know stats_harmonic_mean(), but i am not server admin, i can't install
PECL, so i need make it by
Daniel Brown wrote:
On Dec 14, 2007 10:36 AM, Jochem Maas [EMAIL PROTECTED] wrote:
omg this is so off topic it's liable to come full circle - actually circles
seem pretty
damned orderly ... which just leaves the question as to whether circles
exist or that
we merely projection them onto
That isn't going to work. Gzip is used for entire files. Do you
understand what I'm trying to do, or am I misunderstanding you?
Bob
On Dec 13, 2007, at 11:13 PM, Casey wrote:
On Dec 13, 2007 7:44 AM, Bob Sabiston [EMAIL PROTECTED] wrote:
On Dec 12, 2007, at 7:20 PM, Casey wrote:
Try
Jay Blanchard wrote:
[snip]
I'm going to be inserting data from a PHP form into a mysql field. The
data could contain special characters like ' \ /, etc. How do I
handle that? just $data = addslashes(htmlspecialchars($data)); before
the insert query? because later on the data will
Revisiting the Zlib PHP html page, I notice that it says that Zlib in
PHP works with uncompressed files, but not with sockets. Could that
be my problem? What does it mean to be using sockets? I'm sending
this data wirelessly from a handheld device to a server, and I'm using
the device
-Original Message-
From: Andrew Ballard [mailto:[EMAIL PROTECTED]
Sent: 14 December 2007 04:38
To: PHP General list
Subject: Re: [PHP] PHP date: ISO year = loss of hair
If the last week of the year is the one that has Dec. 28 in it, and the last
week number is 52, then Dec. 30 SHOULD
On Dec 14, 2007 11:01 AM, Jason Pruim [EMAIL PROTECTED] wrote:
[snip!]
I don't know much about women... Only married to one, but My Son
certainly throws me into chaos at times (Daddy, what does this button
do? *Computer shuts off because he found the power strip...)
[snip!]
*Puts on his
I'm going to be inserting data from a PHP form into a mysql field. The
data could contain special characters like ' \ /, etc. How do I
handle that? just $data = addslashes(htmlspecialchars($data)); before
the insert query? because later on the data will be read back from the
mysql db
On Dec 14, 2007 11:10 AM, Jochem Maas [EMAIL PROTECTED] wrote:
Daniel Brown wrote:
On Dec 14, 2007 10:36 AM, Jochem Maas [EMAIL PROTECTED] wrote:
omg this is so off topic it's liable to come full circle - actually
circles seem pretty
damned orderly ... which just leaves the question as
[snip]
I'm going to be inserting data from a PHP form into a mysql field. The
data could contain special characters like ' \ /, etc. How do I
handle that? just $data = addslashes(htmlspecialchars($data)); before
the insert query? because later on the data will be read back from the
Bastien Koert wrote:
use mysql_real_escape_string
bastien
Date: Fri, 14 Dec 2007 08:40:47 -0600 From: [EMAIL PROTECTED] To:
php-general@lists.php.net Subject: [PHP] how to handle inserting special
characters into a mysql field I'm going to be inserting data from a PHP
form into a
i know stats_harmonic_mean(), but i am not server admin, i can't install
PECL, so i need make it by manual, but i have't Statistics knowledge, any
one can help me ? thank you very much !!
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
use mysql_real_escape_string
bastien
Date: Fri, 14 Dec 2007 08:40:47 -0600 From: [EMAIL PROTECTED] To:
php-general@lists.php.net Subject: [PHP] how to handle inserting special
characters into a mysql field I'm going to be inserting data from a PHP
form into a mysql field. The data
On Dec 14, 2007 10:36 AM, Jochem Maas [EMAIL PROTECTED] wrote:
omg this is so off topic it's liable to come full circle - actually circles
seem pretty
damned orderly ... which just leaves the question as to whether circles exist
or that
we merely projection them onto reality, which is great
On Fri, 2007-12-14 at 11:01 -0500, Daniel Brown wrote:
On Dec 14, 2007 10:36 AM, Jochem Maas [EMAIL PROTECTED] wrote:
omg this is so off topic it's liable to come full circle - actually circles
seem pretty
damned orderly ... which just leaves the question as to whether circles
exist or
On Dec 14, 2007, at 10:36 AM, Jochem Maas wrote:
tedd wrote:
At 11:59 PM -0500 12/12/07, Robert Cummings wrote:
On Wed, 2007-12-12 at 16:21 -0500, tedd wrote:
Yeah, but we haven't proven order yet either. :-)
Order exists all around us.
Maybe around you, but I have a wife, two
LKSunny wrote:
i know it can make simple function, if have Statistics knowledge...
ah so you can read a page and therefore determine it's simple even though
you have no 'Statistics knowledge' - brilliant deduction.
you have 3 choices (given that your to stubborn to ask the sys admin to install
On Fri, 2007-12-14 at 11:01 -0500, Jason Pruim wrote:
On Dec 14, 2007, at 10:36 AM, Jochem Maas wrote:
tedd wrote:
At 11:59 PM -0500 12/12/07, Robert Cummings wrote:
On Wed, 2007-12-12 at 16:21 -0500, tedd wrote:
Yeah, but we haven't proven order yet either. :-)
Order exists all
One subtle thing that always messes up GMail is the use of \r\n
instead of \n in a header somewhere in the whole thing...
I don't know if this is what's killing you or not, but it was killing
me until a couple days ago...
You may also want to just do a diff on the two emails and see what
comes
On Fri, December 14, 2007 8:40 am, Adam Williams wrote:
I'm going to be inserting data from a PHP form into a mysql field.
The
data could contain special characters like ' \ /, etc. How do I
handle that? just $data = addslashes(htmlspecialchars($data)); before
the insert query? because
LKSunny wrote:
i know it can make simple function, if have Statistics knowledge...
I don't think you need to know much about statistics - AFAIK, the
harmonic mean of a group of numbers is simply the reciprocal of
the 'normal' mean:
harmonic_mean(3,4,5,6) = 1/mean(3,4,5,6)
/Per Jessen,
If I am reading Wikipeadia correctly, you want this:
?php
function stats_harmonic_mean($array){
$count = count($array);
$mean = 0;
foreach($array as $n){
$mean += 1/$n;
}
$mean = $count / $mean;
return $mean;
}
?
No guarantees as to correctness.
The *real* function probably
Thanks for all the replies everyone. I have a question on
mysql_real_escape_string(). The PHP example page shows:
$query = sprintf(SELECT * FROM users WHERE user='%s' AND password='%s',
mysql_real_escape_string($user),
mysql_real_escape_string($password));
and I
On Thu, December 13, 2007 11:38 pm, Rashmi Badan wrote:
I'm using php 5.2.1 with apache 2.2.6 and while running certain tests
I see
a segmentation fault - the relevant stack is given below. My php
configure
line is as follows
configure '--prefix=/my/php/installdir' *'--with-tsrm-pthreads'
On Thu, December 13, 2007 6:36 am, Dani Castaños wrote:
I've read a bit about PHP session timeout. Is it configurable?? I
mean,
If i want user logged out after 10 minutes of innactivity... where i
can
to set it up?? Is it possible to expire session configuring php.ini.
I know i will have to
Per Jessen wrote:
I don't think you need to know much about statistics - AFAIK, the
harmonic mean of a group of numbers is simply the reciprocal of
the 'normal' mean:
harmonic_mean(3,4,5,6) = 1/mean(3,4,5,6)
Ignore that.
/Per Jessen, Zürich
--
PHP General Mailing List
On Fri, 2007-12-14 at 11:03 -0600, Adam Williams wrote:
Thanks for all the replies everyone. I have a question on
mysql_real_escape_string(). The PHP example page shows:
$query = sprintf(SELECT * FROM users WHERE user='%s' AND password='%s',
mysql_real_escape_string($user),
On Fri, December 14, 2007 2:02 am, Arno Kuhl wrote:
I'm battling with getting the last week number using date(W,
$unixdate). If
the date is 30 December 2007 ($unixdate=1198965600) then date(W,
$unixdate)
returns 01. I know that according to the ISO spec, the last week of
the ISO
year has 28
5000 records is chump-change.
select *
from products
where product_name is not null
and product name != ''
order by product_id
On a 5000-record set, this should be screaming fast even with no index
UNLESS your server is already drastically overloaded.
On Thu, December 13, 2007 9:14 am, tedd
On Fri, 2007-12-14 at 16:36 +0100, Jochem Maas wrote:
tedd wrote:
At 11:59 PM -0500 12/12/07, Robert Cummings wrote:
On Wed, 2007-12-12 at 16:21 -0500, tedd wrote:
Yeah, but we haven't proven order yet either. :-)
Order exists all around us.
Maybe around you, but I have a wife,
Well you can use get_defined_vars() to find all the variables defined
inside of each scope (for instance global scope) that don't really
need to be defined...
http://php.net/get_defined_vars
They can help you unset() or find variables you otherwise don't need
to use. But that's the best I think
There is a software package called 'gconv' for C which does this...
It may or may not be amenable to PHP...
On Wed, December 12, 2007 3:21 am, Mathijs van Veluw wrote:
Hello there,
We have a large project with lots of classes.
Now i am wondering if there is a way to let something check all
On Wed, December 12, 2007 10:39 am, slith wrote:
I'm working on hotel type booking script where prices will vary
depending on the season. prices are updated every year so i need to
take
a user inputed date and determine which season the date falls under.
I would highly recommend adding a
On Dec 12, 2007 4:21 AM, Mathijs van Veluw [EMAIL PROTECTED]
wrote:
Hello there,
We have a large project with lots of classes.
Now i am wondering if there is a way to let something check all those
files and tell me which methods/functions variables/constants etc..
arn't used anymore.
Or
On Fri, 2007-12-14 at 14:09 -0500, Nathan Nobbe wrote:
On Dec 12, 2007 4:21 AM, Mathijs van Veluw [EMAIL PROTECTED]
wrote:
Hello there,
We have a large project with lots of classes.
Now i am wondering if there is a way to let something check all those
files and tell me which
On Dec 14, 2007 2:49 PM, Robert Cummings [EMAIL PROTECTED] wrote:
On Fri, 2007-12-14 at 14:09 -0500, Nathan Nobbe wrote:
On Dec 12, 2007 4:21 AM, Mathijs van Veluw
[EMAIL PROTECTED]
wrote:
Hello there,
We have a large project with lots of classes.
Now i am wondering if there
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download multiple files in one go, short of zipping them
first into a single file?
Concepts / directional shoves appreciated.
David
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED] wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download multiple files in one go, short of zipping them
first into a single file?
Concepts / directional shoves
On Dec 14, 2007, at 3:37 PM, Daniel Brown wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED]
wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download multiple files in one go, short of
zipping them
first into
On 12/14/07, Jason Pruim [EMAIL PROTECTED] wrote:
On Dec 14, 2007, at 3:37 PM, Daniel Brown wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED]
wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download
On Dec 14, 2007 3:49 PM, David Giragosian [EMAIL PROTECTED] wrote:
On 12/14/07, Jason Pruim [EMAIL PROTECTED] wrote:
On Dec 14, 2007, at 3:37 PM, Daniel Brown wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED]
wrote:
I've used Richard Lynch's Blog example for
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED] wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download multiple files in one go, short of zipping them
first into a single file?
Concepts / directional shoves
On Dec 14, 2007 4:24 PM, Daniel Brown [EMAIL PROTECTED] wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED] wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a way to download multiple files in one go, short of zipping
On 12/14/07, Daniel Brown [EMAIL PROTECTED] wrote:
On Dec 14, 2007 4:24 PM, Daniel Brown [EMAIL PROTECTED] wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED] wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there a
On Fri, 2007-12-14 at 16:24 -0500, Daniel Brown wrote:
On Dec 14, 2007 4:24 PM, Daniel Brown [EMAIL PROTECTED] wrote:
On Dec 14, 2007 3:32 PM, David Giragosian [EMAIL PROTECTED] wrote:
I've used Richard Lynch's Blog example for forcing the download of an
individual file.
Is there
On 12/14/07, Benjamin Darwin [EMAIL PROTECTED] wrote:
Aww, we have to wait all the way to Monday? It's fun to sit back and
watch the conversations on here!
And I call third-ed on that... is that the right word?
--Ben
On Dec 14, 2007 4:40 PM, Daniel Brown [EMAIL PROTECTED] wrote:
On Dec 14, 2007 4:38 PM, Robert Cummings [EMAIL PROTECTED] wrote:
On Fri, 2007-12-14 at 16:24 -0500, Daniel Brown wrote:
You could use AJAX, JavaScript, or AJAX to make multiple requests
to download various files simultaneously. That would pop up the
different boxes.
TFGIF.
Aww, we have to wait all the way to Monday? It's fun to sit back and
watch the conversations on here!
And I call third-ed on that... is that the right word?
--Ben
On Dec 14, 2007 4:40 PM, Daniel Brown [EMAIL PROTECTED] wrote:
You, too, Rob. And to all else, make that seconded by me.
On Fri, 2007-12-14 at 16:58 -0500, Daniel Brown wrote:
On Dec 14, 2007 4:49 PM, David Giragosian [EMAIL PROTECTED] wrote:
On 12/14/07, Benjamin Darwin [EMAIL PROTECTED] wrote:
And I call third-ed on that... is that the right word?
It is now.
Since I'm still at work, I'll pass on
On Dec 14, 2007 4:49 PM, David Giragosian [EMAIL PROTECTED] wrote:
On 12/14/07, Benjamin Darwin [EMAIL PROTECTED] wrote:
And I call third-ed on that... is that the right word?
It is now.
Since I'm still at work, I'll pass on the humor ( though these pretzels are
making me thirsty... ),
On Fri, 2007-12-14 at 17:32 -0500, Daniel Brown wrote:
On Dec 14, 2007 5:05 PM, Robert Cummings [EMAIL PROTECTED] wrote:
I'm at work and at home -- My wife just brought me freshly baked
shortbread to munch on while I finish up some code :)
I miss those days. Not the shortbread, since
On Dec 14, 2007 5:05 PM, Robert Cummings [EMAIL PROTECTED] wrote:
I'm at work and at home -- My wife just brought me freshly baked
shortbread to munch on while I finish up some code :)
I miss those days. Not the shortbread, since I've never had
freshly-baked shortbread (though I love
On Dec 14, 2007 5:58 PM, Robert Cummings [EMAIL PROTECTED] wrote:
On Fri, 2007-12-14 at 17:32 -0500, Daniel Brown wrote:
On Dec 14, 2007 5:05 PM, Robert Cummings [EMAIL PROTECTED] wrote:
I'm at work and at home -- My wife just brought me freshly baked
shortbread to munch on while I finish
Zlib compression is what's used in Gzip. Just try it ;)
$uncompressed = gzuncompress(file_get_contents(binaryfile.ext));
-Casey
On Dec 14, 2007, at 9:45 AM, Bob Sabiston wrote:
That isn't going to work. Gzip is used for entire files. Do you
understand what I'm trying to do, or am I
i testing ~ it's correct
Thank You Very Much !!
Richard Lynch [EMAIL PROTECTED]
???:[EMAIL PROTECTED]
If I am reading Wikipeadia correctly, you want this:
?php
function stats_harmonic_mean($array){
$count = count($array);
$mean = 0;
foreach($array as $n){
$mean += 1/$n;
}
Hiya,
We're using PHP/Java Bridge (PJB) with PHP 5.1.6 and Apache 2.0.61 on
Windows, and experiencing frequent segfaults of Apache. Inspecting
the dump reveals that PHP is crashing somewhere, something to do with
a null pointer exception when reporting an error - seemingly not in
the
On Dec 14, 2007, at 5:59 PM, Daniel Brown wrote:
On Dec 14, 2007 5:58 PM, Robert Cummings [EMAIL PROTECTED] wrote:
On Fri, 2007-12-14 at 17:32 -0500, Daniel Brown wrote:
On Dec 14, 2007 5:05 PM, Robert Cummings [EMAIL PROTECTED]
wrote:
I'm at work and at home -- My wife just brought me
On Fri, 2007-12-14 at 21:39 -0500, Jason Pruim wrote:
On Dec 14, 2007, at 5:59 PM, Daniel Brown wrote:
On Dec 14, 2007 5:58 PM, Robert Cummings [EMAIL PROTECTED] wrote:
On Fri, 2007-12-14 at 17:32 -0500, Daniel Brown wrote:
On Dec 14, 2007 5:05 PM, Robert Cummings [EMAIL PROTECTED]
68 matches
Mail list logo