php-general Digest 21 Aug 2009 11:26:19 -0000 Issue 6297

2009-08-21 Thread php-general-digest-help
php-general Digest 21 Aug 2009 11:26:19 - Issue 6297 Topics (messages 297042 through 297053): Re: Displaying 2 digit minutes/seconds 297042 by: Ashley Sheridan 297043 by: sono-io.fannullone.us 297044 by: sono-io.fannullone.us 297046 by: Daevid Vincent Submit

php-general Digest 22 Aug 2009 02:34:03 -0000 Issue 6298

2009-08-21 Thread php-general-digest-help
php-general Digest 22 Aug 2009 02:34:03 - Issue 6298 Topics (messages 297054 through 297067): Re: PHP/Ajax Framework - Call for Developers Testers 297054 by: Bob McConnell about to run PHP script when POST data. 297055 by: Jacky 297057 by: Arno Kuhl Re: Invoking

Re: [PHP] Is there limitation for switch case: argument's value?

2009-08-21 Thread Adam Randall
I've never understood why people use switch statements like this as in reality you are using it more like an if/else block, but anyway. The reason why your code is not working is that you are passing into the switch the value of 0, or false, which means that when any of those $sum == N

Re: [PHP] Is there limitation for switch case: argument's value?

2009-08-21 Thread Lars Torben Wilson
2009/8/20 Keith survivor_...@hotmail.com: Hi, I encounter a funny limitation here with switch case as below: The value for $sum is worked as expected for 1 to 8, but not for 0. When the $sum=0, the first case will be return, which is sum=8. Is there any limitation / rules for switch case?

RE: [PHP] SESSION VARIABLES ACROSS DIFFERENT WINDOWS/TABS

2009-08-21 Thread Leon du Plessis
Hi Jamie. Thanks. Good info. I knew something changed somewhere. This works like a charm in IE8..never saw the New Session option under file...me bad !! Greetings. -Original Message- From: Jaime Bozza [mailto:jbo...@mindsites.com] Sent: 20 August 2009 09:49 PM To: Leon du Plessis;

[PHP] Invoking functions stored in a separate directory?

2009-08-21 Thread Clancy
I am developing an idea for a website engine which can be shared between several different websites. Each website would have its own directory under a common root directory, and the engine would be in a separate directory Engine: Root Website_1.com, Website_2.com, Engine The website

RE: [PHP] PHP/Ajax Framework - Call for Developers Testers

2009-08-21 Thread Bob McConnell
From: Raymond Irving Hi Nathan, I agree with you, and I believe that there are many persons who don't like the idea of hosting all their applications on a third party server. IMO there are some advantages and disadvantages to doing so but that's a discussion in itself. Hosted servers are

[PHP] about to run PHP script when POST data.

2009-08-21 Thread Jacky
Hi guys, As I know When we POST a big data(e.g. 500M) to a php script, the php script only can run after the big data finished POST. for example: a.php ?php die(''); ? and I post 500m data to a.php, after that a.php cannot be died immediately. only when the data finished post. How can

RE: [PHP] Invoking functions stored in a separate directory?

2009-08-21 Thread Arno Kuhl
-Original Message- From: Clancy [mailto:clanc...@cybec.com.au] Sent: 21 August 2009 01:26 PM To: php-general@lists.php.net Subject: [PHP] Invoking functions stored in a separate directory? I am developing an idea for a website engine which can be shared between several different

RE: [PHP] about to run PHP script when POST data.

2009-08-21 Thread Arno Kuhl
-Original Message- From: Jacky [mailto:newbde...@gmail.com] Sent: 21 August 2009 03:12 PM To: php-general@lists.php.net Subject: [PHP] about to run PHP script when POST data. Hi guys, As I know When we POST a big data(e.g. 500M) to a php script, the php script only can run after the big

RE: [PHP] Is there limitation for switch case: argument's value?

2009-08-21 Thread Daevid Vincent
Whoa! I didn't even know you could use a switch statement like that. In 20 years of coding, I've never ever used a switch like that first if/else style. PHP never ceases to amaze me in it's flexibility (and ability to shoot yourself in the foot ;-p ) And remember, all your base are belong to

RE: [PHP] Re: Extract column names from a (my)SQL query

2009-08-21 Thread Daevid Vincent
-Original Message- From: Nisse Engström [mailto:news.nospam.0ixbt...@luden.se] If you're using MySQL, you can try mysql_field_name() and see if it gets you anywhere. I don't think it works on empty results though. FYI. It will. -- PHP General Mailing List (http://www.php.net/)

Re: [PHP] Re: Extract column names from a (my)SQL query

2009-08-21 Thread דניאל דנון
You all misunderstood my question, please read my replies above... I'm looking to extract it from a string - *I'm not executing the queries, I only get them as a string* And to the topic: Since everything I found was very complicated to parse, I've crafted my own preg pattern, /^(\*|[a-z_,

Re: [PHP] Re: Extract column names from a (my)SQL query

2009-08-21 Thread דניאל דנון
Update: I've changed it into /^(\*|[a-z_, \(\)0-9]+)[\s]+FROM[\s]+([a-z_\.]+)(\s+)?(WHERE[\s]+(.+))?\s*(LIMIT\s+([0-9]+)\s*,\s*([0-9]+))?\s*(ORDER BY ([a-z0-9, ]+)?(\s*(DESC|ASC)))?$/Ui Only problem that on: SELECT * FROM table WHERE field2='field3' ORDER BY id DESC LIMIT 0,10 it outputs Array

Re: [PHP] HTML text extraction

2009-08-21 Thread Manuel Lemos
Hello, on 08/18/2009 05:37 AM leledumbo said the following: Usually, a website gives preview of its articles by extracting some of the first characters. This is easy if the article is a pure text, but what if it's a HTML text? For instance, if I have the full text: p bla bla bla ul

[PHP] Re: Tidy on a shared host

2009-08-21 Thread Manuel Lemos
Hello, on 08/20/2009 09:47 PM Al said the following: Or, does anyone know of a stand-alone php class that emulates the tidy extension. I've looked; but, not found any. Yes, you may want to try this Secure HTML parser filter package. It comes with parser and a filter class that validates HTML

Re: [PHP] Re: How to download and configure php mvc website locally

2009-08-21 Thread Paul M Foster
On Wed, Aug 19, 2009 at 11:00:46PM -1000, Sumit Sharma wrote: Hi all, The site I have download was developed using cake php. Now when trying to access the website it is showing a blank page. As Sudheer suggested I went to error log and noted down the errors there, which are as follows:

[PHP] Re: How do I extract link text from anchor tag as well as the URL from the href attribute

2009-08-21 Thread Manuel Lemos
Hello, on 08/16/2009 04:33 AM chrysanhy said the following: I have the following code to extract the URLs from the anchor tags of an HTML page: $html = new DOMDocument(); $htmlpage-loadHtmlFile($location); $xpath = new DOMXPath($htmlpage); $links = $xpath-query( '//a' ); foreach ($links