[PHP] Re: RewriteRules

2009-01-13 Thread Nathan Rixham
Jason Pruim wrote: On Jan 12, 2009, at 2:16 PM, Nathan Rixham wrote: Jason Pruim wrote: Hi Everyone, I know it's not a php question... But I know alot of you use rewrite rules and regular expressions and so I thought maybe you would be able to help me. The site: HTTP://purl.raoset.com/test

Re: [PHP] upgrade php 5.2.6 -> 5.2.8 mysql problems!

2009-01-13 Thread Merlin Morgenstern
Hi there, has somebody an idea how to fix this? I do appreciate any help. Thank you in advance, Merlin Merlin Morgenstern wrote: No. The with-pdo-mysql command secures compatibility with oder databases . That workes fine. The yes in the error msg. seams to be normal in this case. I found load

[PHP] Re: RewriteRules

2009-01-13 Thread Jason Pruim
On Jan 13, 2009, at 5:37 AM, Nathan Rixham wrote: Jason Pruim wrote: On Jan 12, 2009, at 2:16 PM, Nathan Rixham wrote: Jason Pruim wrote: Hi Everyone, I know it's not a php question... But I know alot of you use rewrite rules and regular expressions and so I thought maybe you would be

[PHP] Re: Php and CSS where to put it

2009-01-13 Thread Al
Terion Miller wrote: I have this code and the css seems to not work in IE at all, do I need to put it somewhere different on the page maybe? xCount ORDER BY RAND() LIMIT 3"; $result = mysql_query($sql); echo " "; while ($row = mysql_fetch_array($result)) { echo " {$row['title']

Re: [PHP] HowTo use Eclipse PDT and existing mounted directory tree?

2009-01-13 Thread Thodoris
On Mon, Jan 12, 2009 at 8:13 PM, Daevid Vincent wrote: I must be retarded or something because I can't figure out in Eclipse PDT (Linux) how in the heck do I start a new project and have it "point" to an existing directory tree. I DO NOT want Eclipse to pull in a copy of the files or do an

[PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Thodoris
Hi gang, I am generating a spreadsheet using the contents of a mysql table. I guess that there is something in the data that causes iconv used in the module's script to generate this error: *Notice*: iconv() [function.iconv ]: Detected an incomplete multibyte character in input string in

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 15:51 +0200, Thodoris wrote: > Hi gang, > I am generating a spreadsheet using the contents of a mysql table. I > guess that there is something in the data that causes iconv used in the > module's script to generate this error: > > *Notice*: iconv() [function.iconv > ]:

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Thodoris
On Tue, 2009-01-13 at 15:51 +0200, Thodoris wrote: Hi gang, I am generating a spreadsheet using the contents of a mysql table. I guess that there is something in the data that causes iconv used in the module's script to generate this error: *Notice*: iconv() [function.iconv ]: Dete

Re: [PHP] ecommerce related question

2009-01-13 Thread tedd
At 3:58 PM +1030 1/13/09, Travis Moore wrote: Firstly, not really a php question, but generic web stuff, but I feel it's still better answered here. Recently a friend came to me asking to create an ecommerce website. In the past my php work has been primarily a hobby, and as such haven't real

Re: [PHP] HowTo use Eclipse PDT and existing mounted directory tree?

2009-01-13 Thread Eric Butera
On Mon, Jan 12, 2009 at 8:51 PM, Eric Butera wrote: > On Mon, Jan 12, 2009 at 8:13 PM, Daevid Vincent wrote: >> I must be retarded or something because I can't figure out in Eclipse >> PDT (Linux) how in the heck do I start a new project and have it "point" >> to an existing directory tree. >> >>

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 16:07 +0200, Thodoris wrote: > > On Tue, 2009-01-13 at 15:51 +0200, Thodoris wrote: > > > >> Hi gang, > >> I am generating a spreadsheet using the contents of a mysql table. I > >> guess that there is something in the data that causes iconv used in the > >> module's s

[PHP] Re: RewriteRules

2009-01-13 Thread tedd
Jason: In addition to what everyone else has said, try this: $self = basename($_SERVER['SCRIPT_NAME']) I use it for forms -- you might find it useful. Cheers, tedd -- --- http://sperling.com http://ancientstones.com http://earthstones.com -- PHP General Mailing List (http://www.php.net

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: > Jason: > > In addition to what everyone else has said, try this: > > $self = basename($_SERVER['SCRIPT_NAME']) > > I use it for forms -- you might find it useful. > > Cheers, > > tedd > -- > --- > http://sperling.com http://ancientstones.c

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Thodoris
On Tue, 2009-01-13 at 16:07 +0200, Thodoris wrote: On Tue, 2009-01-13 at 15:51 +0200, Thodoris wrote: Hi gang, I am generating a spreadsheet using the contents of a mysql table. I guess that there is something in the data that causes iconv used in the module's script to gene

Re: [PHP] Re: RewriteRules

2009-01-13 Thread tedd
At 2:33 PM + 1/13/09, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: Jason: In addition to what everyone else has said, try this: $self = basename($_SERVER['SCRIPT_NAME']) I use it for forms -- you might find it useful. Cheers, tedd -- --- http://sper

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: > At 2:33 PM + 1/13/09, Ashley Sheridan wrote: > >On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: > >> Jason: > >> > >> In addition to what everyone else has said, try this: > >> > >> $self = basename($_SERVER['SCRIPT_NAME']) > >> > >> I use it

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 16:33 +0200, Thodoris wrote: > > On Tue, 2009-01-13 at 16:07 +0200, Thodoris wrote: > > > >>> On Tue, 2009-01-13 at 15:51 +0200, Thodoris wrote: > >>> > >>> > Hi gang, > I am generating a spreadsheet using the contents of a mysql table. I > gue

[PHP] PHP unlink Permission Error

2009-01-13 Thread Alice Wei
Hi, I have a snippet of code as follows: The problem is that I do not seem to have the correct permissions, even though I seem to have changed the permissions of the folder to 777 already upon the file deletion time. This is the output I got: C:\Inetpub\wwwroot\projectWarning: unli

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 09:42 -0500, Alice Wei wrote: > Hi, > >I have a snippet of code as follows: > > > ini_set('display_errors', 1); error_reporting(E_ALL); > $curDir = getcwd(); > echo $curDir; > chmod($curDir,0777); > unlink("testFile.txt"); > echo unlink("testFile.txt"); > chmod (

Re: [PHP] switch vs elseif

2009-01-13 Thread Jochem Maas
Ashley Sheridan schreef: > On Mon, 2009-01-12 at 15:15 -0500, Frank Stanovcak wrote: >> I've googled, and found some confusing answers. >> I've tried searching the history of the news group, and only found info on >> switch or elseif seperately. :( >> >> Strictly from a performance stand point, n

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Alice Wei
Hi, Ashley: I thought about it and edited my script to check what permission I had, and it appears I do have the permission rights, and it actually changed to 0777. Here is the code: The output: 0777Warning: unlink(testFile.txt) [function.unlink]: Permission denied in C:\Inetpub\wwwro

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 09:50 -0500, Alice Wei wrote: > Hi, Ashley: > > I thought about it and edited my script to check what permission I > had, and it appears I do have the permission rights, and it actually > changed to 0777. Here is the code: > > > ini_set('display_errors', 1); > error_r

Re: [PHP] switch vs elseif

2009-01-13 Thread Eric Butera
On Tue, Jan 13, 2009 at 9:50 AM, Jochem Maas wrote: > switch (true) { >case ($x === $y): >// something >break; > >case ($a != $b): >// something >break; > >case (myFunc()): >// something >

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Alice Wei
Hi, Ashley: I tried to find your corrected errors, but I cannot seem to find it. Have you sent me an empty reply message by mistake? Alice> Subject: RE: [PHP] PHP unlink Permission Error> From: a...@ashleysheridan.co.uk> To: aj...@alumni.iu.edu> CC: php-general@lists.php.net> Date: Tue, 1

[PHP] Another beginner question

2009-01-13 Thread Gary
I have successfully set up the testing server, now I would like to test it out on the remote server, but "put" does not seem to be working. I saved the php document, click put, nothing seems to happen. I am connected to the remote server, but when I put, nothing happens. The file is in the loc

[PHP] Re: Another beginner question

2009-01-13 Thread Gary
Ok...for whatever reason, it has now worked, even though I did not change anything ""Gary"" wrote in message news:1a.17.42308.e90bc...@pb1.pair.com... >I have successfully set up the testing server, now I would like to test it >out on the remote server, but "put" does not seem to be worki

Re: [PHP] Another beginner question

2009-01-13 Thread Dan Shirah
On Tue, Jan 13, 2009 at 10:17 AM, Gary wrote: > I have successfully set up the testing server, now I would like to test it > out on the remote server, but "put" does not seem to be working. I saved > the > php document, click put, nothing seems to happen. I am connected to the > remote server, b

Re: [PHP] Another beginner question

2009-01-13 Thread Gary
Dan Thanks for your reply...however.. This confuses me greatly. My remote server is godaddy, my testing server is apache... Could you explain that for me? Thanks again Gary ""Dan Shirah"" wrote in message news:a16da1ff0901130727v3a51cce9na913c8f12098...@mail.gmail.com... > On Tue, Jan

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread ceo
Not only do you need to check the return value of chmod to see if it worked, but also, I *think*: The file withing the directory can have entirely different permissions, and making the directory world writable won't help that, I don't think... I could be wrong, and a 000 file in a 777 dir

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Thodoris
Is there any chance its characters creeping in from being copied from a M$ program? I found that M$ software uses it's own character encodings for multibyte characters which causes no end of problems for web-based systems. A lot of it was where angled quotation marks were added my Word, and not

Re: [PHP] ecommerce related question

2009-01-13 Thread ceo
For now, as already said, go with PayPal or similar. Do not store the CC#s in your DB or anywhere at all, for any length of time. Not in the SESSION either. Get it and send it to PayPal and wipe it out with http://php.net/unset all in one single HTTP request. For long-term, to learn more,

[PHP] PHP unlink Errors

2009-01-13 Thread Alice Wei
Hi, I have a snippet below that I would like to delete a file. However, I keep getting kicked out because of permission errors, when my folder permission is 0777. Is it possible that someone on the list could point out what my possible errors are to allow this code to be functioning

Re: [PHP] PHP unlink Errors

2009-01-13 Thread Marc
Do you have php_safe_mode enabled? If's that's the case, try turning it off and then run your script again. Alice Wei wrote: Hi, I have a snippet below that I would like to delete a file. However, I keep getting kicked out because of permission errors, when my folder permission is 0777.

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread Shawn McKenzie
Alice Wei wrote: > Hi, Ashley: > > I thought about it and edited my script to check what permission I had, and > it appears I do have the permission rights, and it actually changed to 0777. > Here is the code: > > ini_set('display_errors', 1); error_reporting(E_ALL); > $curDir = getcwd();

RE: [PHP] PHP unlink Errors

2009-01-13 Thread Alice Wei
Hi, Apparently my safe mode is off. I tried fiddling with my code by changing the permission of my intended to delete file as in the following: This is the output I get 07770666You don't have the permission I don't get a failure statement in the line: chmod ($fileToRemove, 0777) or d

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
No, we tend to bottom-post on this list. It's just how we roll... Ash www.ashleysheridan.co.uk

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 15:46 +, c...@l-i-e.com wrote: > Not only do you need to check the return value of chmod to see if it worked, > but also, I *think*: > > > > The file withing the directory can have entirely different permissions, and > making the directory world writable won't help th

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Alice Wei
Hi, Ashley: Sorry. To answer the question from your previous entry, it looks like that my permission could be set and changed for the folder, but when I do it on the "file", I only get 0666. I have the latest code on another entry. Thanks a lot for your help. Alice Alice Wei Indian

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread ceo
touch foo.txt chmod 000 foo.txt rm foo.txt rm: remove write-protected regular empty file `foo.txt'? So the behaviour is at least partially shell/profile dependent... I have no idea how this would affect PHP unlink, if at all. ymmv naiaa ianasg [*] [*] sg: shell guru -- PHP Ge

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 11:33 -0500, Alice Wei wrote: > Hi, Ashley: > > Sorry. To answer the question from your previous entry, it looks > like that my permission could be set and changed for the folder, but > when I do it on the "file", I only get 0666. I have the latest code on > another entry.

Re: [PHP] iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Bastien Koert
On Tue, Jan 13, 2009 at 10:47 AM, Thodoris wrote: > > Is there any chance its characters creeping in from being copied from a >> M$ program? I found that M$ software uses it's own character encodings >> for multibyte characters which causes no end of problems for web-based >> systems. A lot of i

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Alice Wei
> Subject: RE: [PHP] PHP unlink Permission Error> From: > a...@ashleysheridan.co.uk> To: aj...@alumni.iu.edu> CC: > php-general@lists.php.net> Date: Tue, 13 Jan 2009 16:50:31 +> > On Tue, > 2009-01-13 at 11:33 -0500, Alice Wei wrote:> > Hi, Ashley:> > > > Sorry. To > answer the questio

RE: [PHP] PHP unlink Permission Error

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 11:49 -0500, Alice Wei wrote: > > > > > Subject: RE: [PHP] PHP unlink Permission Error > > From: a...@ashleysheridan.co.uk > > To: aj...@alumni.iu.edu > > CC: php-general@lists.php.net > > Date: Tue, 13 Jan 2009 16:50:31 + > > > > On Tue, 2009-01-13 at 11:33 -0500, Ali

Re: [PHP] PHP unlink Permission Error

2009-01-13 Thread VamVan
Alice, I see that you are using windows. For windows only the write permission for the folder and file isn't enough. You need to change the owner ship of the file as well so that u have privilege to delete. Do this , this might work: //Change the owner ship of the file to a non existent user in t

[PHP] Re: Re: Php and CSS where to put it

2009-01-13 Thread Michelle Konzack
Am 2009-01-12 21:56:00, schrieb Ashley Sheridan: > Here's something for fixing IE with hacks: > > http://www.ashleysheridan.co.uk/coding_html_comments.php > > basically it lets you add in extra IE-only stylesheets using comment > code only recognised by IE, and you can use !important to stress yo

Re: [PHP] switch vs elseif

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 15:50 +0100, Jochem Maas wrote: > Ashley Sheridan schreef: > > On Mon, 2009-01-12 at 15:15 -0500, Frank Stanovcak wrote: > >> I've googled, and found some confusing answers. > >> I've tried searching the history of the news group, and only found info on > >> switch or elseif

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Jason Pruim
On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: At 2:33 PM + 1/13/09, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: Jason: In addition to what everyone else has said, try this: $self = basename($_SERVER['SCRI

[PHP] Re: downloading xls files corrupts them

2009-01-13 Thread Michelle Konzack
Am 2009-01-12 13:13:25, schrieb Chris Ditty: > I am using php to download xls files on my server. When I download them, > excel is saying they are corrupted. They are not corrupted on the server > itself. These are simple xls spreadsheets with no formatting in them. > > Here is the headers t

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 13:14 -0500, Jason Pruim wrote: > On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: > > > On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: > >> At 2:33 PM + 1/13/09, Ashley Sheridan wrote: > >>> On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: > Jason: > >

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Jason Pruim
On Jan 13, 2009, at 1:26 PM, Robert Cummings wrote: On Tue, 2009-01-13 at 13:14 -0500, Jason Pruim wrote: On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: At 2:33 PM + 1/13/09, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:20 -0500, t

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Eric Butera
On Tue, Jan 13, 2009 at 1:14 PM, Jason Pruim wrote: > > On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: > >> On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: >>> >>> At 2:33 PM + 1/13/09, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:20 -0500, tedd wrote: > > Jason:

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Kyle Terry
On Tue, Jan 13, 2009 at 10:28 AM, Jason Pruim wrote: > > On Jan 13, 2009, at 1:26 PM, Robert Cummings wrote: > > On Tue, 2009-01-13 at 13:14 -0500, Jason Pruim wrote: >> >>> On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: >>> >>> On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: > At

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Jason Pruim
On Jan 13, 2009, at 1:30 PM, Kyle Terry wrote: On Tue, Jan 13, 2009 at 10:28 AM, Jason Pruim wrote: On Jan 13, 2009, at 1:26 PM, Robert Cummings wrote: On Tue, 2009-01-13 at 13:14 -0500, Jason Pruim wrote: On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:33

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Jason Pruim
On Jan 13, 2009, at 1:29 PM, Eric Butera wrote: On Tue, Jan 13, 2009 at 1:14 PM, Jason Pruim wrote: On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: At 2:33 PM + 1/13/09, Ashley Sheridan wrote: On Tue, 2009-01-13 at 09:20 -0500, te

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Eric Butera
On Tue, Jan 13, 2009 at 1:32 PM, Jason Pruim wrote: > > On Jan 13, 2009, at 1:29 PM, Eric Butera wrote: > > On Tue, Jan 13, 2009 at 1:14 PM, Jason Pruim wrote: > > On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: > > On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: > > At 2:33 PM + 1/13/09,

[PHP] Re: iconv is messing up a spreadsheet generated by the Spreadsheet Excel Writer

2009-01-13 Thread Nisse Engström
On Tue, 13 Jan 2009 15:51:01 +0200, Thodoris wrote: > Hi gang, > I am generating a spreadsheet using the contents of a mysql table. I > guess that there is something in the data that causes iconv used in the > module's script to generate this error: > > *Notice*: iconv() [function.iconv >

[PHP] Suggestions?

2009-01-13 Thread Dan Shirah
Hello all! I have written some code that will calculate all static and floating holidays. I have also written some code that will act as a business day counter. My application currently determines a set number of business days to count. (2 business days and 7 business days from today) This part

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 13:28 -0500, Jason Pruim wrote: > > > > > > Wow, that's really low level... I haven't written a tag in > > years. > > So then the question is begged... How do you write your forms? :) If > there's a better way to do it I'm all ears! Other then using CSS... My > HTML knowledg

Re: [PHP] Suggestions?

2009-01-13 Thread Eric Butera
On Tue, Jan 13, 2009 at 2:00 PM, Dan Shirah wrote: > Hello all! > > I have written some code that will calculate all static and floating > holidays. > > I have also written some code that will act as a business day counter. > > My application currently determines a set number of business days to c

Re: [PHP] Suggestions?

2009-01-13 Thread ceo
Hard to say without knowing the data structures... You can't do a simple count of the holidays and add that, because you might end up with yet another holiday in the result. Start at 12/23 and want to add 6 business days. You find 1 holiday in between, so you add 7 business days and end

Re: [PHP] Suggestions?

2009-01-13 Thread Dan Shirah
On Tue, Jan 13, 2009 at 2:09 PM, Eric Butera wrote: > Are you asking how to do > > $holidays[] = date; > array_push($holidays, date); ? > > If you were generating dates to compare against today tho, you could > just return upon a match at that point and not even store them. No > point in creati

Re: [PHP] Suggestions?

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 19:14 +, c...@l-i-e.com wrote: > Hard to say without knowing the data structures... > > You can't do a simple count of the holidays and add that, because you might > end up with yet another holiday in the result. > > Start at 12/23 and want to add 6 business days. > >

[PHP] Query string question

2009-01-13 Thread Jônatas Zechim
I have something like this on my site: mysite.com/índex.php?msg=Transa%25E7%25E3o+n%25E3o+autorizada i need to convert " Transa%25E7%25E3o+n%25E3o+autorizada" to "Transação não autorizada". The letters ç ã, and others (é, í, ...). Someone can help me? -Mensagem original- De: Eric Bu

Re: [PHP] Query string question

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 17:21 -0200, Jônatas Zechim wrote: > I have something like this on my site: > > mysite.com/índex.php?msg=Transa%25E7%25E3o+n%25E3o+autorizada > > i need to convert " Transa%25E7%25E3o+n%25E3o+autorizada" to "Transação não > autorizada". > > The letters ç ã, and others (é,

Re: [PHP] Suggestions?

2009-01-13 Thread Dan Shirah
On Tue, Jan 13, 2009 at 2:14 PM, wrote: > > Hard to say without knowing the data structures... > > You can't do a simple count of the holidays and add that, because you might > end up with yet another holiday in the result. > > Start at 12/23 and want to add 6 business days. > > You find 1 holida

Re: [PHP] switch vs elseif

2009-01-13 Thread Micah Gersten
Jochem Maas wrote: > switch (true) { > case ($x === $y): > // something > break; > > case ($a != $b): > // something > break; > > case (myFunc()): > // something > break; > > case ($my->getCh

[PHP] php session GC error

2009-01-13 Thread Frank Stanovcak
I'm trying to make sure that my sessions are timed out by my server. I'm running it on winxp, and my php.ini contains the following session.gc_probability = 1 session.gc_divisor = 1 ; After this number of seconds, stored data will be seen as 'garbage' and ; cleaned up by the garbage collectio

Re: [PHP] switch vs elseif

2009-01-13 Thread ceo
I think if they didn't want us to use expressions in the case, then they wouldn't have put support into the language for that. I daresay you are reading more into the text than was intended... I certainly have found switch(true) with complex expressions for case quite handy and very clear

[PHP] Re: php session GC error

2009-01-13 Thread Shawn McKenzie
Frank Stanovcak wrote: > I'm trying to make sure that my sessions are timed out by my server. > I'm running it on winxp, and my php.ini contains the following > > session.gc_probability = 1 > session.gc_divisor = 1 > > ; After this number of seconds, stored data will be seen as 'garbage' and

Re: [PHP] switch vs elseif

2009-01-13 Thread Jochem Maas
Micah Gersten schreef: > Jochem Maas wrote: >> switch (true) { >> case ($x === $y): >> // something >> break; >> >> case ($a != $b): >> // something >> break; >> >> case (myFunc()): >> // something >> break

[PHP] Re: php session GC error

2009-01-13 Thread Frank Stanovcak
"Shawn McKenzie" wrote in message news:f8.ef.24097.e510d...@pb1.pair.com... > Frank Stanovcak wrote: >> I'm trying to make sure that my sessions are timed out by my server. >> I'm running it on winxp, and my php.ini contains the following >> >> session.gc_probability = 1 >> session.gc_divisor

Re: [PHP] switch vs elseif

2009-01-13 Thread Nathan Rixham
Jochem Maas wrote: Micah Gersten schreef: Jochem Maas wrote: switch (true) { should be switch(false) { :-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: php session GC error

2009-01-13 Thread Nathan Rixham
Frank Stanovcak wrote: "Shawn McKenzie" wrote in message news:f8.ef.24097.e510d...@pb1.pair.com... Frank Stanovcak wrote: I'm trying to make sure that my sessions are timed out by my server. I'm running it on winxp, and my php.ini contains the following session.gc_probability = 1 session.gc_d

Re: [PHP] switch vs elseif

2009-01-13 Thread Jochem Maas
Robert Cummings schreef: > On Tue, 2009-01-13 at 15:50 +0100, Jochem Maas wrote: >> Ashley Sheridan schreef: >>> On Mon, 2009-01-12 at 15:15 -0500, Frank Stanovcak wrote: I've googled, and found some confusing answers. I've tried searching the history of the news group, and only found inf

Re: [PHP] switch vs elseif

2009-01-13 Thread Jochem Maas
Nathan Rixham schreef: > Jochem Maas wrote: >> Micah Gersten schreef: >>> Jochem Maas wrote: switch (true) { > > should be switch(false) { > > :-) > it could be either depending on your needs, no? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net

[PHP] Re: php session GC error

2009-01-13 Thread Frank Stanovcak
"Nathan Rixham" wrote in message news:496d03d3.2060...@gmail.com... > Frank Stanovcak wrote: >> "Shawn McKenzie" wrote in message >> news:f8.ef.24097.e510d...@pb1.pair.com... >>> Frank Stanovcak wrote: I'm trying to make sure that my sessions are timed out by my server. I'm running i

Re: [PHP] switch vs elseif

2009-01-13 Thread Shawn McKenzie
Micah Gersten wrote: > Jochem Maas wrote: >> switch (true) { >> case ($x === $y): >> // something >> break; >> >> case ($a != $b): >> // something >> break; >> >> case (myFunc()): >> // something >> break;

Re: [PHP] switch vs elseif

2009-01-13 Thread Robert Cummings
On Tue, 2009-01-13 at 22:12 +0100, Jochem Maas wrote: > Robert Cummings schreef: > > On Tue, 2009-01-13 at 15:50 +0100, Jochem Maas wrote: > >> Ashley Sheridan schreef: > >>> On Mon, 2009-01-12 at 15:15 -0500, Frank Stanovcak wrote: > I've googled, and found some confusing answers. > I've

[PHP] Re: php session GC error

2009-01-13 Thread Shawn McKenzie
Frank Stanovcak wrote: > "Nathan Rixham" wrote in message > news:496d03d3.2060...@gmail.com... >> Frank Stanovcak wrote: >>> "Shawn McKenzie" wrote in message >>> news:f8.ef.24097.e510d...@pb1.pair.com... Frank Stanovcak wrote: > I'm trying to make sure that my sessions are timed out b

[PHP] Re: php session GC error

2009-01-13 Thread Frank Stanovcak
"Shawn McKenzie" wrote in message news:e3.00.25553.8560d...@pb1.pair.com... > Frank Stanovcak wrote: >> "Nathan Rixham" wrote in message >> news:496d03d3.2060...@gmail.com... >>> Frank Stanovcak wrote: "Shawn McKenzie" wrote in message news:f8.ef.24097.e510d...@pb1.pair.com... >

[PHP] installing php 5 with pdflib

2009-01-13 Thread Merlin Morgenstern
Hi there, I am still facing trouble with pdflib and php 5. After hours of research I found that I do have to install the pecl package. So I decided to compile it into php staticly like described here: http://www.php-resource.de/handbuch/install.pecl.static.htm The configure command stops with

Re: [PHP] installing php 5 with pdflib

2009-01-13 Thread Bastien Koert
On Tue, Jan 13, 2009 at 4:38 PM, Merlin Morgenstern wrote: > Hi there, > > I am still facing trouble with pdflib and php 5. After hours of research I > found that I do have to install the pecl package. So I decided to compile it > into php staticly like described here: > http://www.php-resource.de

[PHP] Re: php session GC error

2009-01-13 Thread Frank Stanovcak
So from everything I've read there is no real way to assure a session timeout with out timestamping it myself and dealing with it in code by doing a time compare. bummer. ""Frank Stanovcak"" wrote in message news:57.31.25553.de80d...@pb1.pair.com... > > "Shawn McKenzie" wrote in message >

Re: [PHP] switch vs elseif

2009-01-13 Thread Kirk . Johnson
I regret that I don't recall who made the brilliant observation that programmers spend the majority of their time *reading* code (their own or others) as opposed to *writing* code. So, I make it a point to try to make my code easily scannable. I only and always use the switch construct when eva

Re: [PHP] Re: Re: Php and CSS where to put it

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 18:41 +0100, Michelle Konzack wrote: > Am 2009-01-12 21:56:00, schrieb Ashley Sheridan: > > Here's something for fixing IE with hacks: > > > > http://www.ashleysheridan.co.uk/coding_html_comments.php > > > > basically it lets you add in extra IE-only stylesheets using commen

[PHP] Re: php session GC error

2009-01-13 Thread Nathan Rixham
Frank Stanovcak wrote: So from everything I've read there is no real way to assure a session timeout with out timestamping it myself and dealing with it in code by doing a time compare. bummer. you're probably storing the session in a session cookie (which is default) so session.cookie_life

Re: [PHP] Re: Re: Php and CSS where to put it

2009-01-13 Thread Andrew Ballard
On Tue, Jan 13, 2009 at 5:14 PM, Ashley Sheridan wrote: > Yeah. Now my development goes like this: > > 1. Design for Firefox > 2. Fix for Opera, Safari et al > 3. Fix for IE > But generally speaking, if it works in Firefox, it'll most likely behave > itself in everything except IE ;) >

Re: [PHP] Re: php session GC error

2009-01-13 Thread Andrew Ballard
On Tue, Jan 13, 2009 at 5:08 PM, Nathan Rixham wrote: > Frank Stanovcak wrote: >> >> So from everything I've read there is no real way to assure a session >> timeout with out timestamping it myself and dealing with it in code by doing >> a time compare. >> >> bummer. > > you're probably storing th

Re: [PHP] Re: RewriteRules

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 13:29 -0500, Eric Butera wrote: > On Tue, Jan 13, 2009 at 1:14 PM, Jason Pruim wrote: > > > > On Jan 13, 2009, at 9:46 AM, Ashley Sheridan wrote: > > > >> On Tue, 2009-01-13 at 09:33 -0500, tedd wrote: > >>> > >>> At 2:33 PM + 1/13/09, Ashley Sheridan wrote: > >

Re: [PHP] installing php 5 with pdflib

2009-01-13 Thread Ashley Sheridan
On Tue, 2009-01-13 at 16:58 -0500, Bastien Koert wrote: > On Tue, Jan 13, 2009 at 4:38 PM, Merlin Morgenstern > wrote: > > > Hi there, > > > > I am still facing trouble with pdflib and php 5. After hours of research I > > found that I do have to install the pecl package. So I decided to compile i

Re: [PHP] Holy crap

2009-01-13 Thread Daniel Brown
On Mon, Jan 12, 2009 at 14:30, Robert Cummings wrote: > > 2.0 is the new beta... what did you think Web 2.0 was all about? In Q3 2009, Microsoft is "improving" on that with Web 2.11 for Workgroups. -- daniel.br...@parasane.net || danbr...@php.net http://www.parasane.net/ || http://www.pilo

Re: [PHP] Holy crap

2009-01-13 Thread Kyle Terry
On Tue, Jan 13, 2009 at 5:22 PM, Daniel Brown wrote: > On Mon, Jan 12, 2009 at 14:30, Robert Cummings > wrote: > > > > 2.0 is the new beta... what did you think Web 2.0 was all about? > > In Q3 2009, Microsoft is "improving" on that with Web 2.11 for > Workgroups. > > -- > > daniel.br...@pa

Re: [PHP] Holy crap

2009-01-13 Thread Daniel Brown
On Tue, Jan 13, 2009 at 20:34, Kyle Terry wrote: > > www.idonttrustmicrosoftwithmywebsite.com/ps/i/hate/them/ Couldn't reach the site. Try restarting IIS. -- daniel.br...@parasane.net || danbr...@php.net http://www.parasane.net/ || http://www.pilotpig.net/ Unadvertised dedicated server de

Re: [PHP] upgrade php 5.2.6 -> 5.2.8 mysql problems!

2009-01-13 Thread Tom Rogers
Hi, Tuesday, January 13, 2009, 9:25:57 AM, you wrote: MM> Hello everybody, MM> I am trying to update php 5.2.6 to 5.2.8 on a test system. Somehow it MM> can not find the working mysql installation. With 5.2.6 I everything is MM> fine. MM> Here is the configure command that is pretty much the sa

Re: [PHP] Holy crap

2009-01-13 Thread Kyle Terry
On Tue, Jan 13, 2009 at 5:49 PM, Daniel Brown wrote: > On Tue, Jan 13, 2009 at 20:34, Kyle Terry wrote: > > > > www.idonttrustmicrosoftwithmywebsite.com/ps/i/hate/them/ > > Couldn't reach the site. Try restarting IIS. > > -- > > daniel.br...@parasane.net || danbr...@php.net > http://www.pa

Re: [PHP] Holy crap

2009-01-13 Thread Daniel Brown
On Tue, Jan 13, 2009 at 20:54, Kyle Terry wrote: > > Every time I try I get this error: > > " > HTTP Error 500.22 - Internal Server Error > An ASP.NET setting has been detected that does not apply in Integrated > managed pipeline mode. > Please install .NET 5000 wrapped in SilverLight 15 wrapping

Re: [PHP] Holy crap

2009-01-13 Thread Kyle Terry
On Tue, Jan 13, 2009 at 6:03 PM, Daniel Brown wrote: > On Tue, Jan 13, 2009 at 20:54, Kyle Terry wrote: > > > > Every time I try I get this error: > > > > " > > HTTP Error 500.22 - Internal Server Error > > An ASP.NET setting has been detected that does not apply in Integrated > > managed pipeli

[PHP] PHP, Smarty, and Text

2009-01-13 Thread Daniel Kolbo
Hello, I've been using PHP and Smarty for several years now and I am happy with this "division" of data from presentation. With this philosophy in mind, i am a bit perplexed as to how to handle the text on my sites. That is, the text is data, so i am motivated to store the text in a databas

Re: [PHP] Suggestions?

2009-01-13 Thread Phpster
I have a fiscal calendar table that I use for the same thing, storing the date, day of the week and a column indicating whether the day is a weekday, a weekend or a holiday. This allows me flexibility to also use the table to set business shutdowns as a holiday. A simple date query can retu

Re: [PHP] PHP, Smarty, and Text

2009-01-13 Thread Phpster
What about stripping out all the 'nuances' and just reducing it to just the text where you then control the display and using your templates and css? Bastien Sent from my iPod On Jan 13, 2009, at 9:49 PM, Daniel Kolbo wrote: Hello, I've been using PHP and Smarty for several years now an

  1   2   >