On Tue, Aug 11, 2009 at 08:23:21PM -0700, Allen McCabe wrote:
> I have seen different scripts for working with SQL, and most follow the same
> method with on difference.
>
> Variables are defined (host, password, etc.)
> mysql_connect command
>
> //then, the difference
>
> mysql_select_db comma
I have seen different scripts for working with SQL, and most follow the same
method with on difference.
Variables are defined (host, password, etc.)
mysql_connect command
//then, the difference
mysql_select_db command
//back to common
$sql = "SELECT ... "
$result = mysql_query($ql)
Is the dat
hi,
Is there any way to get realpath cache hit ratio of php?
realpath_cache_size integer
Determines the size of the realpath cache to be used by PHP. This
value should be increased on systems where PHP opens many files, to
reflect the quantity of the file operations performed.
realpath_cache_t
On Tue, Aug 11, 2009 at 03:53:58PM -0400, tedd wrote:
> Hi gang:
>
> I want to show the dates for all Fridays +-30 days from a specific date.
>
> For example, given today's date (8/11/2009) the Fridays that fall
> +-30 days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug
> 28, and Sept 4
> -Original Message-
> Daevid Vincent wrote:
> > NO! For the love of God and all that is holy, don't do that
> accumulator / mod "hack".
> > That's so 1980's. And why make the CPU do all that math
> for every row...
> >
> > Just do this. It's quick and simple:
> >
> > CSS:
> >
Shawn McKenzie wrote:
> tedd wrote:
>> Hi gang:
>>
>> I want to show the dates for all Fridays +-30 days from a specific date.
>>
>> For example, given today's date (8/11/2009) the Fridays that fall +-30
>> days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug 28, and
>> Sept 4.
>>
>> I'm
Jim Lucas wrote:
Robert Cummings wrote:
tedd wrote:
Hi gang:
I want to show the dates for all Fridays +-30 days from a specific date.
For example, given today's date (8/11/2009) the Fridays that fall +-30
days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug 28, and
Sept 4.
I'm cu
Robert Cummings wrote:
> tedd wrote:
>> Hi gang:
>>
>> I want to show the dates for all Fridays +-30 days from a specific date.
>>
>> For example, given today's date (8/11/2009) the Fridays that fall +-30
>> days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug 28, and
>> Sept 4.
>>
>> I'm
tedd wrote:
> Hi gang:
>
> I want to show the dates for all Fridays +-30 days from a specific date.
>
> For example, given today's date (8/11/2009) the Fridays that fall +-30
> days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug 28, and
> Sept 4.
>
> I'm curious, how would you guys so
Let me be the first to welcome you to the list!!!
Rick Duval wrote:
OK, first guys, I'm sorry to have to do this but I can't get off this list!!!
I've followed the instructions on a couple of occasions (the ones at
the bottom of every email):
PHP General Mailing List (http://www.php.net/)
To
OK, first guys, I'm sorry to have to do this but I can't get off this list!!!
I've followed the instructions on a couple of occasions (the ones at
the bottom of every email):
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
Been There, done th
He's pointing out a typo... "forearch" instead of "foreach" :)
LOL!
I almost always miss the jokes.
Thanks for the smiley face to get my (lighter) attention ;-)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
John Butler wrote:
What a lot of good ideas spawned from the OP!
I am learning many things,.. while also actually working (paying
bills), so I regularly have to just go with what I know well.
Anyway, I already have the forearch { loop (for other reasons it is
necessary), and I only needed o
What a lot of good ideas spawned from the OP!
I am learning many things,.. while also actually working (paying
bills), so I regularly have to just go with what I know well.
Anyway, I already have the forearch { loop (for other reasons it is
necessary), and I only needed one color to alternat
tedd wrote:
Hi gang:
I want to show the dates for all Fridays +-30 days from a specific date.
For example, given today's date (8/11/2009) the Fridays that fall
+-30 days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug
28, and Sept 4.
I'm curious, how would you guys solve this?
Allen, you off and running again?
Sure am, thanks, on to the next set of issues. Seems like
programming is always moving on from one error to the next :)
Currently, I am having trouble with echo and php line-returns.
It works on one part of the code, but not on another (instead,
prints it
At 1:53 PM -0600 8/11/09, John Butler wrote:
What a lot of good ideas spawned from the OP!
I am learning many things,.. while also actually working (paying
bills), so I regularly have to just go with what I know well.
Anyway, I already have the forearch { loop (for other reasons it is
necessa
On Tue, Aug 11, 2009 at 3:56 PM, tedd wrote:
> At 12:44 PM -0700 8/11/09, Ben Dunlap wrote:
>>
>> This is probably flame-war tinder, so I'll try to tread more delicately in
>> the future. Next you know we'll be on the ternary operator and which is
>> better, Mac or Windows. ;-)
>>
>> Ben
>
> That w
At 12:44 PM -0700 8/11/09, Ben Dunlap wrote:
This is probably flame-war tinder, so I'll try to tread more delicately in
the future. Next you know we'll be on the ternary operator and which is
better, Mac or Windows. ;-)
Ben
That was won long ago, it's Mac. :-)
Cheers,
tedd
--
---
http:/
Hi gang:
I want to show the dates for all Fridays +-30 days from a specific date.
For example, given today's date (8/11/2009) the Fridays that fall
+-30 days are July 17, July 24, July 31, Aug 7, Aug 14, Aug 21, Aug
28, and Sept 4.
I'm curious, how would you guys solve this?
Cheers,
tedd
-
What a lot of good ideas spawned from the OP!
I am learning many things,.. while also actually working (paying
bills), so I regularly have to just go with what I know well.
Anyway, I already have the forearch { loop (for other reasons it is
necessary), and I only needed one color to alternat
> statements, it becomes unmaintainable very quickly, use a templating
>>> language, ether with a framework(recomended) or standalone.
>>>
>>
>>
>> But he /is/ using a templating language... PHP. ;-)
>>
>
> Keep telling yourself that... and be sure to pat your own back.
>
I'm sure there are plenty
> # before was $styles = array( 'even', 'odd' );
>>> # after new requirements it is...
>>> $styles = array( 'white', 'white', 'gray' );
>>> foreach($items as $item)
>>> {
>>> printf( '%s', current( $styles ), $item );
>>>
>>> next( $styles ) or reset( $styles );
>>> }
>>>
>>>
>>> +5000. I think i
>
> On Aug 11, 2009, at 12:13 AM, hessi...@hessiess.com wrote:
>
>> Do *NOT* get into the habit of outputting your HTML using echo or
>> print
>> statements, it becomes unmaintainable very quickly, use a templating
>> language, ether with a framework(recomended) or standalone.
>
> This soun
Ben Dunlap wrote:
statements, it becomes unmaintainable very quickly, use a templating
language, ether with a framework(recomended) or standalone.
But he /is/ using a templating language... PHP. ;-)
Keep telling yourself that... and be sure to pat your own back.
Cheers,
Rob.
--
http://www
On Tue, 2009-08-11 at 11:54 -0700, Ben Dunlap wrote:
> On Tue, Aug 11, 2009 at 11:52 AM, Ben Dunlap
> wrote:
>
> @Adam
>
> The headers_sent() wasa test to ensure that no other
> data was creeping
> into the
Ben Dunlap wrote:
# before was $styles = array( 'even', 'odd' );
# after new requirements it is...
$styles = array( 'white', 'white', 'gray' );
foreach($items as $item)
{
printf( '%s', current( $styles ), $item );
next( $styles ) or reset( $styles );
}
+5000. I think is by far the most reada
On Tue, Aug 11, 2009 at 11:52 AM, Ben Dunlap wrote:
>
> @Adam
>> The headers_sent() wasa test to ensure that no other data was creeping
>> into the headers before I wanted it to. Keeping it in does no harm, as
>> it is basically saying, if there are no headers that have been sent,
>> send the cor
> @Adam
> The headers_sent() wasa test to ensure that no other data was creeping
> into the headers before I wanted it to. Keeping it in does no harm, as
> it is basically saying, if there are no headers that have been sent,
> send the correct ones for the image.
But if there are headers that ha
On Tue, 2009-08-11 at 13:29 -0500, Adam Shannon wrote:
> On Tue, Aug 11, 2009 at 1:08 PM, Ashley Sheridan
> wrote:
>
> > On Tue, 2009-08-11 at 19:02 +0100, Ashley Sheridan wrote:
> > > I've got a bit of a weird one here. I'm using PHP to output an image.
> > > This works fine when I output as a fi
>
> Personally I try to not use double quoted.
> PHP parses single quoted very much faster.
>
> # for this
> echo "Hi, $name, wellcome $home";
>
> # I use
> echo 'Hi, ', $name, ', wellcome ', $home;
>
I'm not sure if this was true in older versions of PHP, but it's not so much
any more, and I wond
> statements, it becomes unmaintainable very quickly, use a templating
> language, ether with a framework(recomended) or standalone.
But he /is/ using a templating language... PHP. ;-)
Ben
On Tue, Aug 11, 2009 at 1:08 PM, Ashley Sheridan
wrote:
> On Tue, 2009-08-11 at 19:02 +0100, Ashley Sheridan wrote:
> > I've got a bit of a weird one here. I'm using PHP to output an image.
> > This works fine when I output as a file, but when I try to feed it
> > directly to the browser it fills
> # before was $styles = array( 'even', 'odd' );
> # after new requirements it is...
> $styles = array( 'white', 'white', 'gray' );
> foreach($items as $item)
> {
> printf( '%s', current( $styles ), $item );
>
> next( $styles ) or reset( $styles );
> }
>
>
+5000. I think is by far the most readabl
On Tue, 2009-08-11 at 19:02 +0100, Ashley Sheridan wrote:
> I've got a bit of a weird one here. I'm using PHP to output an image.
> This works fine when I output as a file, but when I try to feed it
> directly to the browser it fills the screen with random characters.
>
> I know I've got the heade
I've got a bit of a weird one here. I'm using PHP to output an image.
This works fine when I output as a file, but when I try to feed it
directly to the browser it fills the screen with random characters.
I know I've got the headers right, as it works some of the time. The
only thing I can spot wh
Ashley Sheridan wrote:
On Tue, 2009-08-11 at 17:57 +0200, Aschwin Wesselius wrote:
Ashley Sheridan wrote:
And I really would use a PHP 5 server given the choice. I've tried
speaking to the hosting company a few times, but they brush me off!
Hi Ashley,
And how is their SLA then? Do you take
On Tue, 2009-08-11 at 17:57 +0200, Aschwin Wesselius wrote:
> Ashley Sheridan wrote:
> > And I really would use a PHP 5 server given the choice. I've tried
> > speaking to the hosting company a few times, but they brush me off!
> >
> Hi Ashley,
>
> And how is their SLA then? Do you take full re
Ashley Sheridan wrote:
And I really would use a PHP 5 server given the choice. I've tried
speaking to the hosting company a few times, but they brush me off!
Hi Ashley,
And how is their SLA then? Do you take full responsibility in case of a
security breach? PHP 4 is way long ago and there a
On Tue, Aug 11, 2009 at 12:21 PM, Ford, Mike wrote:
> > -Original Message-
> > From: m a r k u s [mailto:queribus2...@hotmail.com]
> > Sent: 11 August 2009 15:34
> >
> > I see that from PHP 5.3.0 ereg_replace() function is deprecated and
> > throws a warning.
> > I would like to use the p
On Tue, 2009-08-11 at 10:40 -0500, la...@garfieldtech.com wrote:
> The "private" keyword was added in PHP 5. PHP 4 doesn't have visibility
> identifiers. In PHP 4 you have to use "var", which is then always public.
>
> Or you could just use PHP 5 instead of a dead language. :-)
>
> Ashley Sher
On Tue, 11 Aug 2009 18:35:35 +0300, Ashley Sheridan
wrote:
Hey all,
Is there any reason why this shouldn't work correctly on a server
running PHP 4.4.7:
I would at the very least expect to see the 'wtf' printed out. I've got
a whole class I've written that works fine in PHP 5, but on PHP
'Twas brillig, and Alberto García Gómez at 11/08/09 16:05 did gyre and
gimble:
Dear Fellows:
I want ot upgrade my PHP from 5.1.x to 5.2.x. I want to do using rpm, but any
time that I going to upgrade the rpm request me more dependencies.
How can I configure my rpm (or other command) to automat
The "private" keyword was added in PHP 5. PHP 4 doesn't have visibility
identifiers. In PHP 4 you have to use "var", which is then always public.
Or you could just use PHP 5 instead of a dead language. :-)
Ashley Sheridan wrote:
Hey all,
Is there any reason why this shouldn't work correctly
Hey all,
Is there any reason why this shouldn't work correctly on a server
running PHP 4.4.7:
I would at the very least expect to see the 'wtf' printed out. I've got
a whole class I've written that works fine in PHP 5, but on PHP 4
server, it does nothing with even this simple example.
Any ide
> -Original Message-
> From: m a r k u s [mailto:queribus2...@hotmail.com]
> Sent: 11 August 2009 15:34
>
> I see that from PHP 5.3.0 ereg_replace() function is deprecated and
> throws a warning.
> I would like to use the preg_replace() function as an alternative of
> ereg_replace() functi
On Aug 11, 2009, at 12:13 AM, hessi...@hessiess.com wrote:
Do *NOT* get into the habit of outputting your HTML using echo or
print
statements, it becomes unmaintainable very quickly, use a templating
language, ether with a framework(recomended) or standalone.
This sounds interesting. Coul
m a r k u s wrote:
> Hi all,
>
> I see that from PHP 5.3.0 ereg_replace() function is deprecated and
> throws a warning.
> I would like to use the preg_replace() function as an alternative of
> ereg_replace() function but... can't undestand the "\n#[^\n]*\n"
> expression.
>
> $sql = ereg_replace(
Alberto García Gómez wrote:
> Dear Fellows:
>
> I want ot upgrade my PHP from 5.1.x to 5.2.x. I want to do using rpm, but any
> time that I going to upgrade the rpm request me more dependencies.
>
> How can I configure my rpm (or other command) to automaticly satisfy my
> dependencies.
>
>
>
Dear Fellows:
I want ot upgrade my PHP from 5.1.x to 5.2.x. I want to do using rpm, but any
time that I going to upgrade the rpm request me more dependencies.
How can I configure my rpm (or other command) to automaticly satisfy my
dependencies.
Saludos Fraternales
___
Hi all,
I see that from PHP 5.3.0 ereg_replace() function is deprecated and throws a
warning.
I would like to use the preg_replace() function as an alternative of ereg_replace() function but...
can't undestand the "\n#[^\n]*\n" expression.
$sql = ereg_replace("\n#[^\n]*\n", "", $sql);
Any he
At 10:27 AM -0300 8/11/09, Martin Scotta wrote:
A change request just came in - the interaction designer wants every
third line to have a grey background, instead of every second line.
# before was $styles = array( 'even', 'odd' );
# after new requirements it is...
$styles = array( 'white', 'whi
At 2:29 PM +0100 8/11/09, Conor Mac Aoidh wrote:
quick Q:
I have this inside a foreach{} that I want to alternate between on and
off so I can alternate the background-color of my 's.
$tableRowBGcolorBoolCounter != $tableRowBGcolorBoolCounter; //-boolean on
and off
I am looking thru' docs and b
At 9:04 AM +0200 8/11/09, Leidago !Noabeb wrote:
Hi
I have the following tables setup in MYSQL:
Region 1 Region 2
HQ
Tbl1 with autonumbered (PK) Tbl1 with autonumbered (PK)
Tbl1 autonumbered-PK
To explain the above. Basica
quick Q:
I have this inside a foreach{} that I want to alternate between on
and
off so I can alternate the background-color of my 's.
$tableRowBGcolorBoolCounter != $tableRowBGcolorBoolCounter;
//-boolean on
and off
I am looking thru' docs and books, but can't remember (nor find now)
in
On Tue, Aug 11, 2009 at 10:09 AM, tedd wrote:
> At 8:46 AM -0400 8/11/09, tedd wrote:
>
>> At 4:16 PM -0600 8/10/09, John Butler wrote:
>>
>>> quick Q:
>>> I have this inside a foreach{} that I want to alternate between on and
>>> off so I can alternate the background-color of my 's.
>>>
>>> $ta
At 8:46 AM -0400 8/11/09, tedd wrote:
At 4:16 PM -0600 8/10/09, John Butler wrote:
quick Q:
I have this inside a foreach{} that I want to alternate between on
and off so I can alternate the background-color of my 's.
$tableRowBGcolorBoolCounter != $tableRowBGcolorBoolCounter;
//-boolean on
At 4:16 PM -0600 8/10/09, John Butler wrote:
quick Q:
I have this inside a foreach{} that I want to alternate between on
and off so I can alternate the background-color of my 's.
$tableRowBGcolorBoolCounter != $tableRowBGcolorBoolCounter;
//-boolean on and off
I am looking thru' docs and b
On Mon, 10 Aug 2009 01:17:21 +0200, "Ralph Deffke" wrote:
>> On Sun, 9 Aug 2009 20:17:15 +0200, "Ralph Deffke" wrote:
>>
>>> I'm facing the fact that it seems that auto_increment fields in a table not
>>> start at 1 like it was in earlier versions even if I install mySQL brand new
>>> creating all
Hi,
> ...
Sorry, quoted wrong email. Oopsy...
--
Richard Heyes
HTML5 graphing: RGraph - www.rgraph.net (updated 8th August)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Aug 11, 2009, at 3:04 AM, "Leidago !Noabeb"
wrote:
Hi
I have the following tables setup in MYSQL:
Region 1 Region 2
HQ
Tbl1 with autonumbered (PK) Tbl1 with autonumbered (PK)
Tbl1 autonumbered-PK
To explain the a
On Aug 10, 2009, at 11:22 PM, Skip Evans wrote:
Bastien Koert wrote:
Use PHPMailer or one of the other classes available...makes life
so much easier
Kick Ass!!!
Yes! Wow! Was that a breeze! That class rocks!
Thanks tons, Bastien!
I have to admit when I first saw your reply I
Daevid Vincent wrote:
From: Robert Cummings [mailto:rob...@interjinn.com]
However, accelerators don't make scripts faster per se.
They merely cut out the script reading and parsing time.
Which is a HUGE portion of time since PHP is a two-pass step. One that reads
and compiles to opcodes (wit
seems they changing idears on the fly? could it be that the designer is a
smal ugly person while u a a good looking ladykiller ?
on that background I would design a function where u can change ti what ever
u want on the fly something like this
var $a;
function alternate( $a, $_b=array( "red", "r
On Tue, 2009-08-11 at 11:28 +0100, David Otton wrote:
> 2009/8/11 Daevid Vincent :
>
> > NO! For the love of God and all that is holy, don't do that accumulator /
> > mod "hack".
> > That's so 1980's. And why make the CPU do all that math for every row...
> >
> > Just do this. It's quick and s
2009/8/11 Daevid Vincent :
> NO! For the love of God and all that is holy, don't do that accumulator /
> mod "hack".
> That's so 1980's. And why make the CPU do all that math for every row...
>
> Just do this. It's quick and simple:
>
> CSS:
> .dataRow1 { background-color: #DFDFDF; }
>
Hi,
> Very cool!
I'll take that as a compliment... :-)
--
Richard Heyes
HTML5 graphing: RGraph - www.rgraph.net (updated 8th August)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
> -Original Message-
> From: Ralph Deffke [mailto:ralph_def...@yahoo.de]
> Sent: 11 August 2009 01:45
>
> u...
> try
> echo "";
> for( $i=0 ; $i<10; $i++){
> echo "something " . (($a = $a^1) ? "red\n" : "green\n");
> }
The ^ operator is one that has an assigning version, so the abov
> -Original Message-
> From: Daevid Vincent [mailto:dae...@daevid.com]
> Sent: 11 August 2009 02:19
>
> Then YOU have more aggressive error_reporting than the default
> setting
> turned on. You might consider turning it down a notch. NOTICEs are
> basically
> useless and bloat your code IM
On Tue, 11 Aug 2009 10:04:52 +0300, "Leidago !Noabeb"
wrote:
Hi
I have the following tables setup in MYSQL:
Region 1 Region 2
HQ
Tbl1 with autonumbered (PK) Tbl1 with autonumbered (PK)
Tbl1 autonumbered-PK
To explain t
hi there,
this is typical app for db repliction mechanism. it depnds of the size off
your project.
have a look here:
http://dev.mysql.com/doc/refman/5.1/en/replication-howto.html
if this is oversized for u do a dump of each table without the
auto_increment fields. if u read in these tables the m
Check out this link http://www.learnphp-tutorial.com/Email.cfm
On Tue, Aug 11, 2009 at 8:52 AM, Skip Evans wrote:
> Bastien Koert wrote:
>
>>
>> Use PHPMailer or one of the other classes available...makes life
>> so much easier
>>
>>
>
>Kick Ass!!!
>
>
> Yes! Wow! Was that a breeze
Leidago !Noabeb wrote:
> Hi
>
> I have the following tables setup in MYSQL:
>
> Region 1 Region 2
> HQ
> Tbl1 with autonumbered (PK) Tbl1 with autonumbered (PK)
> Tbl1 autonumbered-PK
>
> To explain the above. Basically the
Hi
I have the following tables setup in MYSQL:
Region 1 Region 2
HQ
Tbl1 with autonumbered (PK) Tbl1 with autonumbered (PK)
Tbl1 autonumbered-PK
To explain the above. Basically there are two regions that collect
information
On Tue, 2009-08-11 at 07:13 +, hessi...@hessiess.com wrote:
> Do *NOT* get into the habit of outputting your HTML using echo or print
> statements, it becomes unmaintainable very quickly, use a templating
> language, ether with a framework(recomended) or standalone.
>
> You should learn the ba
75 matches
Mail list logo