here is the trick the solaris guy showed me , i've intergrated it into a
webpage for showing the results
time php somebenchmark.php > /dev/null time will show u the results of the
compiling , the microtime version has to allow time for running through apache
:)
>= Original Message From "Dae
lol this would have to be the first i got from this list, i get dozens of
korean spam everyday , the encoding is all wrong and all comes out is
gibberish characters , how do i stop this ?
>= Original Message From "Sebastian" <[EMAIL PROTECTED]> =
>hehe. i should get me one of those ;)
>
>
>John I'm not sure if you've noticed, ...
Larry, Pete et al.,
Point taken. I won't exacerbate the point, but php.net does point out the lists, and
this "general" group in particular, are for "talking about PHP".
"There are a number of mailing lists devoted to talking about PHP and related
pro
hehe. i should get me one of those ;)
cheers,
- Sebastian
- Original Message -
From: "Matt Giddings" <[EMAIL PROTECTED]>
| mailto:[EMAIL PROTECTED]";
|
| function spam-o-meter( $sender ) {
| return( is_real($sender) ? 'not spam' : 'spam' );
| }
|
| if( spam-o-meter($user)
mailto:[EMAIL PROTECTED]";
function spam-o-meter( $sender ) {
return( is_real($sender) ? 'not spam' : 'spam' );
}
if( spam-o-meter($user) == 'spam' ) {
echo "punt user!";
}
?>
This sender is correct; this was a great opportunity for me to brush up
on some PHP programming and cod
Great Opportunity for all group members!!!
Please Join its free!!! You will have $50 extra Bonuses and earnings
only with sign up this progam.
Bonuses and Earnings:
A $50.00 sign-up bonus will be awarded to each new member of Platinum-
Mails. This bonus will become payable when the member has
Hi,
Sunday, April 6, 2003, 2:51:36 PM, you wrote:
Dd>
Dd> You can use getimagesize on a jpg file to read its size, so either
Dd> save the jpg in MySQL to a file and then do a getImageSize, or before you place
the jpg in to the database read its size and store its dimensions with it in the db.
Dd
You can use getimagesize on a jpg file to read its size, so either
save the jpg in MySQL to a file and then do a getImageSize, or before you place the
jpg in to the database read its size and store its dimensions with it in the db.
I disagree with Andrew. In my humble opinion, I don't think you
I cut and pasted your code and it worked fine for me with PHP 4.3.0
(assuming the first line is really $dayarray = array(9,22,22); )
---John W. Holmes...
PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/
> -Original Message-
> From: G
Oh yeah - I'm using Version 4.2.3 on Linux
__
Do you Yahoo!?
Yahoo! Tax Center - File online, calculators, forms, and more
http://tax.yahoo.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
I would like to remove duplicate array values, and I
presume that array_unique should do this, but the
results are not what I am expecting
Anyone see this before:
$dayarray=(9,22,22);
$duparray = array_unique($dayarray);
$darray = count($duparray);
for($d=0;$d<$darray;$d++){
echo "$d: ".$duparray
> I have a text blurb that is on the home page of a site. I need to make
> this block of text editable through a form in the admin section of
the
> site. Is it worth having a table in the db or would I be better off
> writing to a file for this?
Just use a file. The only problem you'll have is if
Hello all,
I have a text blurb that is on the home page of a site. I need to make
this block of text editable through a form in the admin section of the
site. Is it worth having a table in the db or would I be better off
writing to a file for this?
Thanks,
Charles
--
PHP General Mailing List
You should be asking these questions on a MySQL list...
DELETE FROM table WHERE laikas < NOW() - INTERVAL 60 DAY AND admin != 1
Works on MySQL 3 and 4.
---John W. Holmes...
PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch.com/
> -Original M
Hey all, the next code i wrote is for deleting users who don`t login
for 60 days. This script should work under 4.x.x series of MySQL DB,
but i have 3.x.x version. What should i change in this code that it
should work on 3.x.x version of MySQL. ( time is given as a timestamp
( saved as time() in my
Hello, I wrote the code for deleting the oldest string in the mysql if
it reaches over 15 strings, but it works only under 4.x.x series of MySQL and i have
3.x.x. What should I change in the code that it would work under 3.x.x
version of MySQL? Here`s the code:
$quer = "SELECT COUNT(id) FROM loga
> you also really don't need single quotes in the $_POST...
(if the variable is within a string delimited by _double_ quotes)
> echo "Name: $_POST[name]";
>
> .. should work.
---John W. Holmes...
PHP Architect - A monthly magazine for PHP Professionals. Get your copy
today. http://www.phparch
you also really don't need single quotes in the $_POST...
echo "Name: $_POST[name]";
.. should work.
cheers,
- Sebastian
- Original Message -
From: "Don Read" <[EMAIL PROTECTED]>
|
| On 06-Apr-2003 David McGlone wrote:
| > Hi all, how can I combine this line to use just 1 echo stat
On Saturday 05 April 2003 08:00 pm, John W. Holmes wrote:
> > Hi all, how can I combine this line to use just 1 echo statement?
> >
> > echo "Name: "; echo $_POST['name']
>
> The period is used for string concatenation:
>
> echo "Name: " . $_POST['name'];
>
> Many ways you can do it:
>
> echo "Name
Ajay Lal wrote:
Can you please spend some time with my doubt...
My query is that ...
Is there any option or function in PHP to implement
automatic updation of web pages with the latest
contents from other sites. Like news from news sites etc.
Or do you have any idea about doing it.
Thank you
On 06-Apr-2003 David McGlone wrote:
> Hi all, how can I combine this line to use just 1 echo statement?
>
> echo "Name: "; echo $_POST['name']
>
echo 'Name: ', $_POST['name'];
-or-
echo 'Name: ' .$_POST['name'];
Regards,
--
Don Read [EMAIL PROTECTED]
-
Mike wrote:
Hi,
So I'm working on a CMS that has the ability to move pages from one
category to another, and whole sub-categories (and all their pages) to a
different categories. I have a file that defines the hierarchy of the
menu:
.|Something
..|sub-something
..|sub-something else
.|something -e
> Hi all, how can I combine this line to use just 1 echo statement?
>
> echo "Name: "; echo $_POST['name']
The period is used for string concatenation:
echo "Name: " . $_POST['name'];
Many ways you can do it:
echo "Name: {$_POST['name']}";
echo 'Name: ' . $_POST['name'];
echo "Name: $_POST[nam
Darn you Phillip! ;) I was just about to post that. Also, since we're
being picky, you should also assign the result to $bgcolor in each of
your tests like you are the first one, instead of just testing a
condition. Here are the results with the fourth method that Phillip
mentioned (along with sing
Hi all, how can I combine this line to use just 1 echo statement?
echo "Name: "; echo $_POST['name']
Am I being too picky here?
Thanks,
--
David M.
Edification Web Solutions
http://www.edificationweb.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.n
If you really want to be optimal, use bitwise instead
of modulus :) And ++$i instead of $i++ :) And,
use single not double quotes :) Silly, but true.
http://www.faqts.com/knowledge_base/view.phtml/aid/783/fid/9
And, write less code, so:
$bgcolor = (++$i & 1) ? '#ff' : '#ee';
Hi,
So I'm working on a CMS that has the ability to move pages from one
category to another, and whole sub-categories (and all their pages) to a
different categories. I have a file that defines the hierarchy of the
menu:
.|Something
..|sub-something
..|sub-something else
.|something -else
..|sub-
OF COURSE IT'S OT! The name is PHP: hypertext PREprocessor! This is a
list for PHP, not HTML, javascript, or house decorating!
daniel wrote:
man chill out , message me off list and i can give you a jscript example , as
the description says , "hypertext processor", i dont think jscript even ht
man chill out , message me off list and i can give you a jscript example , as
the description says , "hypertext processor", i dont think jscript even html
is OT !
>= Original Message From Leif K-Brooks <[EMAIL PROTECTED]> =
>There NEEDS to be a manual page for this! PHP is SERVER-SIDE!
It seems that it makes almost no difference if you switch in and out of
the parser or stay within it...
Does this seem like a fair test? Having said that, I would suggest
always using the first method as it's much cleaner to read and color
coding works in most editors.
-- output ---
version one:
When accessing a page called "Create Users", it checks that the user
doing just that is properly logged in--this is part of the admin section
of the site, not the public end. If not, it sends one to a page created
by "login.php". There one is met by instructions to type in a username
and passwo
I had to know... ;-)
Output:
version one:0.56761503219604 seconds
version two:0.3099730014801 seconds
version three: 0.36320495605469 secondss
So the boolean (V2)is faster:
Mine is slightly slower by a 'smidge' (0.06 seconds)
Top one is cleanest but slower.
--- test ---
\n";
$time_
At 01:12 6-4-2003, you wrote:
Does anyone know of a prefix convention used for PHP? What I'm talking
about is using a type of Hungarian notation for PHP variables. I know they
use 'g', 'm', and 'r' for global, method and reference variables but for
other variable types. I get confused once and a
On 05-Apr-2003 Bobby Rahman wrote:
>
>
> Hiya people
>
> After a lot of soul searching, exploring the web and help from many
> people I
> came up with this simple solution:
>
Okey-doke. simple is in the eye of the beholder.
$bgcolor = ($bgcolor == '#E3E8F0' ? '#C7D0E2' : '#E3E8F0');
At 00:42 6-4-2003, you wrote:
Wow you guys are going about that way more complicated than it needs to
be:
$i = 0;
echo "";
Then it just alternates and takes care of itself (plus you get a nice
little index counter as well as a bonus if you want to use $i
DÆVID.
Or in my belief even faster, (withou
Does anyone know of a prefix convention used for PHP? What I'm talking about is using
a type of Hungarian notation for PHP variables. I know they use 'g', 'm', and 'r' for
global, method and reference variables but for other variable types. I get confused
once and a while, while I am coding and
There NEEDS to be a manual page for this! PHP is SERVER-SIDE! That
means that once the page loads (actually, a little before that), PHP is
done. IT DOES NOT KEEP RUNNING! IT RUNS ON THE SERVER'S MACHINE, NOT
THE CLIENT! RTFA!
Shantenese Williams wrote:
Does anyone know if there is a funct
For sure, and this port changes every time I make a new request.
Alex
"Rasmus Lerdorf" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> No, the destination port will not change. You must be looking at the
> source port.
>
> -Rasmus
>
> On Sat, 5 Apr 2003, Alexander Weber wrote
Wow you guys are going about that way more complicated than it needs to
be:
$i = 0;
echo "";
Then it just alternates and takes care of itself (plus you get a nice
little index counter as well as a bonus if you want to use $i
DÆVID.
"A good friend will come and bail you out of jail...but a tru
Tell us more about your script please.
Cheers, Alex
"Dhaval" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> Hi All,
>
> I m trying to build a drop down dynamically. I m quering fields from MSSQL
> 2000 Server. Now look wat is happning when i run my php from a Win2K PC
and
>
No, the destination port will not change. You must be looking at the
source port.
-Rasmus
On Sat, 5 Apr 2003, Alexander Weber wrote:
> So far so good, the next problem is now, that the port changes with every
> new request. Tried this on my "personal" server an my hoster's one.
>
> Perhaps ther
php-general Digest 5 Apr 2003 22:27:49 - Issue 1981
Topics (messages 142502 through 142537):
unsubscribe [EMAIL PROTECTED]
142502 by: Chris Roumbanis
Re: Bug ?
142503 by: David Otton
Re: Finding the height of a JPG in pixels using PHP
142504 by: Andrew Brampton
If
So far so good, the next problem is now, that the port changes with every
new request. Tried this on my "personal" server an my hoster's one.
Perhaps there is another way? JScript, xml or anything other?
Thanx so far,
Alex
"Rasmus Lerdorf" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL
Hiya people
After a lot of soul searching, exploring the web and help from many people I
came up with this simple solution:
Thank you Chris for explaining the toggle $colorset. In the end I decided
this made life alot simplier.
(clearly the brackets have to be correctly aligned)
while( $row
At 02:23 6-4-2003, you wrote:
Does anyone know if there is a function in PHP that allows you to
right-click on an item, and from there a drop down menu pops
up and you can go to another screen, preserving that value that was
clicked on?
If there is no function for right-clicking, then is there a
Does anyone know if there is a function in PHP that allows you to
right-click on an item, and from there a drop down menu pops
up and you can go to another screen, preserving that value that was
clicked on?
If there is no function for right-clicking, then is there a way that
when you are selecti
Well i'm on php4.2.3 Apache and windows xp, and i'm trying to get oci8
working. If this isn't the correct list could you point me in the right
direction?
thx,
Paul
From: "Jim Lucas" <[EMAIL PROTECTED]>
To: "Paul Dymecki" <[EMAIL PROTECTED]>,<[EMAIL PROTECTED]>
Subject: Re: [PHP] oci8
Date: Sa
John,
I'm not sure if you've noticed, but pretty much every question you've
asked on this list of late has received at least one comment about
finding the appropriate resource. If I were in your situation, I'd
start to see a theme.
The PHP General mailing list is for questions about developme
did you reload mysql so it will have the new user?
Jim
- Original Message -
From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
To: "php mailing list list" <[EMAIL PROTECTED]>
Sent: Saturday, April 05, 2003 10:40 AM
Subject: [PHP] mysl_connect question
> When I use myssql to connect to a db wi
Just after we had a long discussion about off topic questions. This one
doesn't even refer to a programming language problem.
Or am I missing someting?
Jim
- Original Message -
From: "Paul Dymecki" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, April 05, 2003 10:30 AM
Subjec
John-
This would best be asked on a Red Hat list, but I can tell you that if you
are using Red Hat 7.3 I would not really count on getting them to release
PHP 4.3 as once a major Red Hat release is out they usually only provide
security updates - NOT feature updates.
Red Hat also modifies the
Where would I go on the redHat site to ask when they are going to
upgrade to PHP 4.3 and MySQL 4.x (now in production). Our CS dept.
won't install them for me until RedHat bundles it. I'm using RH 7.3.
This question would probably be best directed towards:
1) The RedHat site
2) A RedHat newsgroup
> With :
>
> <...
> Envoyez ce fichier :
> <...
>
>
> Is there a parameter wich indicates the directory
> where the file must be uploaded ?
The file is uploaded to the directory specified in php.ini. You must
move/copy it from there before the script ends.
---John W. Holmes...
PHP Architect
sorry i see i made a bit too many ambiguous typing errors.
Hiya I have a dynamic table and am trying to get the rows to be two
different alternate colours. well Ive looked at a couple of snippets of
this colour code and previous mails regarding this. Im having major
troubles intergrating any of
At 22:14 5-4-2003, you wrote:
Hiya I have a dynamic table and am trying to get the rows to be two
different alternate colours. well Ive looked at a couple of snippets of
this colour code and previous mails regarding this. Im having major
troubles intergrating any of these suggestions with my c
Where would I go on the redHat site to ask when they are going to upgrade to PHP 4.3
and MySQL 4.x (now in production). Our CS dept. won't install them for me until RedHat
bundles it. I'm using RH 7.3.
http://www.netcraft.com/?host=compcanlit.usherbrooke.ca&position=limited
Suggestions where to
Hiya I have a dynamic table and am trying to get the rows to be two
different alternate colours. well Ive looked at a couple of snippets of this
colour code and previous mails regarding this. Im having major troubles
intergrating any of these suggestions with my code. Can anyone suggest where
May be this line is wrong :
Echo Geen informatie beschikbaar;
may be use this instead...
echo 'Geen informatie beschikbaar';
no?
:)
regards.
<[EMAIL PROTECTED]> a écrit dans le message de news:
[EMAIL PROTECTED]
> Hi,
>
> I'm trying to do the following.. When $stadpict is filled in it mu
Hi all,
I've pulled my hair out on this, so I'm turning to the experts.
I'm trying to make a directory of a site password protected:
http://www.ivepulledmyhairout.com/protected
I'm getting there from:
http://www.ivepulledmyhairout.com
I've got a login.php page that gets a username and passwor
When I use myssql to connect to a db with anything besides root I get an
error that I cannot connect. I created a user that has access to one
databse called 'menu'. The user has SELECT, UPDATE, and DELETE permissions
for that database.
I can connect on the command line: mysql-u newuser -p. But
Hello,
Sorry for cross posting but i thought i'd get a better response. I was
just wondering if anyone has gotten oci8 working successfully on windows?
I've been trying with not much luck.
thx,
Paul Dymecki
_
Protect your PC
Presumably you know the HTTPS port on your server. Anything not SSL is
going to be straight HTTP. The point here is that SSL happens a layer
below PHP. PHP doesn't care whether it is running over SSL or not. In
fact it has no idea what transport layer is below it. So your only way to
tell is t
But SERVER PORT is not always 80 using HTTP (not HTTPS). So this way is not
really secure.
Alex
"Rasmus Lerdorf" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> I usually just use $_SERVER['SERVER_PORT']
>
> -Rasmus
>
> On Sat, 5 Apr 2003, Alexander Weber wrote:
>
> > Unfortun
For some reason I can't seem to get fread() to work proeprly. Every time I
try to use it, my script simply exits with no output, errors, or logs of any
kind that I can find. It seems to work with fgets() just fine, but I need to
read in binary files. I'm currently running PHP 4.2.2 on Apache 2.0.40
Seems correct to me, try to upload the file with different browsers. Opera,
Netscape, M$. e.g. Rich Text could be: application/MSword, text/richtext,
and some other "nice" applications ;-)
Cheers,
Alex
"Anders Thoresson" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
> Am
I believe you can also prevent the header error by using ob_start();
"Jean-Louis Letortorec" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> To work around that "headers already sent" problem, I use:
>
> if ($condition == true) { echo
> "location.href=('http://...');"; }
>
> That wor
With :
<...
Envoyez ce fichier :
<...
Is there a parameter wich indicates the directory
where the file must be uploaded ?
For example, from the root of my site.
Thank You
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Sat, 5 Apr 2003, John W. Holmes wrote:
> > header('Cache-Control: no-cache, must-revalidate');
> > header('Pragma: no-cache');
> > header('Expires: Mon,26 Jul 1980 05:00:00 GMT');
>
> Kind of a follow on question to this. If you use a method like this on
> public web pages, does anyone know if
> header('Cache-Control: no-cache, must-revalidate');
> header('Pragma: no-cache');
> header('Expires: Mon,26 Jul 1980 05:00:00 GMT');
Kind of a follow on question to this. If you use a method like this on
public web pages, does anyone know if it'll affect how search engines
index your page? Will
I would help if you told us which line the error was on
On Sat, 5 Apr 2003 [EMAIL PROTECTED] wrote:
> Hi,
>
> I'm trying to do the following.. When $stadpict is filled in it must display the
> picture (only the path to the picture is stored in Mysql). But when the string
> ($stadpict) is empty
header('Cache-Control: no-cache, must-revalidate');
header('Pragma: no-cache');
header('Expires: Mon,26 Jul 1980 05:00:00 GMT');
On Sat, 5 Apr 2003, [iso-8859-1] Davíð Örn Jóhannsson wrote:
> Is there any way in php to disable the users cache so that every time
> you reload you fetch the newest
Is there any way in php to disable the users cache so that every time
you reload you fetch the newest version of the site?
Regards, David
> I'm trying to do the following.. When $stadpict is filled in it must
> display the picture (only the path to the picture is stored in Mysql).
But
> when the string ($stadpict) is empty then it must not display the
picture
> (and also not display a box with a red cross in it (can't display
picture
Hi All,
I m trying to build a drop down dynamically. I m quering fields from MSSQL
2000 Server. Now look wat is happning when i run my php from a Win2K PC and
from a Linux Box.
Linux Machine
ABIDA PARVEEN
AHMED HUSSAIN MOHD.HUSSAIN
AHMED HUSSAIN,MOHAMMED HUSSAIN
ANWAR USSAI
ARVINDER SINGHOHAMMED
Hi,
I'm trying to do the following.. When $stadpict is filled in it must display the
picture (only the path to the picture is stored in Mysql). But when the string
($stadpict) is empty then it must not display the picture (and also not display a box
with a red cross in it (can't display picture
You can use getimagesize on a jpg file to read its size, so either save the
jpg in MySQL to a file and then do a getImageSize, or before you place the
jpg in to the database read its size and store its dimensions with it in the
db.
Andrew
- Original Message -
From: "Phil Schwarzmann" <[EMA
On Sat, 5 Apr 2003 13:18:08 +0300, you wrote:
>David, thank you very much. I suspected smth. like this, but still, it is
>weird: PHP already has the "&" operator (?) for assigning by reference.
The reference operator
$b = &$a;
forces $b and $a to be references to the same variable now and forev
unsubscribe [EMAIL PROTECTED]
David, thank you very much. I suspected smth. like this, but still, it is
weird: PHP already has the "&" operator (?) for assigning by reference. And
there is more: I noticed that if I use the "sort" function instead of
"array_multisort", it works as expected.
I still think there is a bug involved
This can be done using the apache_hooks sapi module. Look in
sapi/apache_hooks in the 4.3 sources for details.
-Rasmus
On Sat, 5 Apr 2003, Zoff wrote:
> Tom Rogers wrote:
> > Hi,
> >
> > Saturday, April 5, 2003, 6:29:50 AM, you wrote:
> > Z> Hi !
> >
> > Z> what i want is to write something in
I have JPG files stored as binary in a MySQL database. I am displaying the
JPGs on the screen and also want to know the height (in pixels) of the JPG.
Can PHP do this?
Thanks!
Tom Rogers wrote:
Hi,
Saturday, April 5, 2003, 6:29:50 AM, you wrote:
Z> Hi !
Z> what i want is to write something in PHP which does authentication
Z> (not basic auth but my own DB driven stuff) and after that something
Z> apache resumes normal operation so that whatever is served afterwards
Z> do
On Sat, 5 Apr 2003 09:40:19 +0300, you wrote:
>I tried something like this:
>
>$arrayA = array(5,4,3,2,1);
>$arrayB = $arrayA;
>array_multisort($arrayA);
>echo $arrayA[0], "";
>echo $arrayB[0];
>?>
>
>
>The output is:
>1
>1
>
>I think it should be:
>1
>5
It's not a bug (ie this is expected behavi
Can you please spend some time with my doubt...
My query is that ...
Is there any option or function in PHP to implement
automatic updation of web pages with the latest
contents from other sites. Like news from news sites etc.
Or do you have any idea about doing it.
Thank you for spending yo
HH! Now that makes perfect sense.
Thank you Rasmus for that indepth reply and also the , vs . "trick"
> -Original Message-
> From: Rasmus Lerdorf [mailto:[EMAIL PROTECTED]
> Sent: Friday, April 04, 2003 10:11 PM
> To: Daevid Vincent
> Cc: [EMAIL PROTECTED]
> Subject: RE: [PHP] Re
I usually just use $_SERVER['SERVER_PORT']
-Rasmus
On Sat, 5 Apr 2003, Alexander Weber wrote:
> Unfortunally is not set. It's like the variable does not exist, because when
> I extract the varaible $_SERVER with foreach I don't get HTTPS as key, only
> SERVER_PROTOCOL.
>
> I'm using PHP 4.3.1 as
86 matches
Mail list logo