Click here to Skip to main content
15,886,199 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
QuestionPERL reading .sql file? Pin
josephong21-Mar-10 23:07
josephong21-Mar-10 23:07 
AnswerRe: PERL reading .sql file? Pin
jschell6-Apr-10 10:56
jschell6-Apr-10 10:56 
QuestionDjango trouble Pin
rastaVnuce20-Mar-10 23:57
rastaVnuce20-Mar-10 23:57 
AnswerRe: Django trouble Pin
Chris Austin23-Mar-10 4:28
Chris Austin23-Mar-10 4:28 
GeneralRe: Django trouble Pin
rastaVnuce23-Mar-10 4:41
rastaVnuce23-Mar-10 4:41 
GeneralRe: Django trouble Pin
Chris Austin23-Mar-10 4:47
Chris Austin23-Mar-10 4:47 
GeneralRe: Django trouble Pin
rastaVnuce23-Mar-10 5:00
rastaVnuce23-Mar-10 5:00 
Questioninfinite loop while using php's dir object..? Pin
cjoki19-Mar-10 11:31
cjoki19-Mar-10 11:31 
Hello All,

My co-worker has a script that was caught in a infinite loop... during one run of the script. It has not repeated this behaviour since.

After reading the docs online (w3schools http://www.w3schools.com/php/func_directory_dir.asp[^]) I see this returns a directory stream.

I am wondering if you use the objects function "read()" as the condition of a while loop...

<br />
$dir = dir('/pathway/to/directory');<br />
while($dir->read()!==false)<br />
{<br />
   ... process files...<br />
}<br />


...is it possible to cause an infinite loop when a new file is added via a different script to the same directory during this scripts execution?

the scripts run on a lamp system with ample resources.

Ideas?
AnswerRe: infinite loop while using php's dir object..? Pin
chevu28-Mar-10 23:28
chevu28-Mar-10 23:28 
GeneralRe: infinite loop while using php's dir object..? Pin
cjoki29-Mar-10 4:53
cjoki29-Mar-10 4:53 
GeneralRe: infinite loop while using php's dir object..? Pin
chevu29-Mar-10 19:04
chevu29-Mar-10 19:04 
Questionquery help with table that has no primary keys Pin
scorpio2219-Mar-10 10:26
scorpio2219-Mar-10 10:26 
AnswerRe: query help with table that has no primary keys Pin
PHP_Guy22-Mar-10 11:01
PHP_Guy22-Mar-10 11:01 
QuestionCreating project setup Pin
sarang_k17-Mar-10 18:36
sarang_k17-Mar-10 18:36 
AnswerRe: Creating project setup Pin
PHP_Guy19-Mar-10 7:24
PHP_Guy19-Mar-10 7:24 
QuestionExporting HTML file to PDF format Pin
sarang_k11-Mar-10 22:47
sarang_k11-Mar-10 22:47 
AnswerRe: Exporting HTML file to PDF format Pin
Niall Barr11-Mar-10 23:07
professionalNiall Barr11-Mar-10 23:07 
QuestionUse PEAR's datagrid export to an excel sheet, but getting all unrecognized characters [modified] Pin
alexyxj11-Mar-10 8:44
alexyxj11-Mar-10 8:44 
QuestionStored Procedure with Php and MySQL Pin
scorpio2211-Mar-10 5:19
scorpio2211-Mar-10 5:19 
AnswerRe: Stored Procedure with Php and MySQL Pin
PHP_Guy19-Mar-10 7:46
PHP_Guy19-Mar-10 7:46 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2222-Mar-10 4:25
scorpio2222-Mar-10 4:25 
GeneralRe: Stored Procedure with Php and MySQL Pin
PHP_Guy22-Mar-10 10:44
PHP_Guy22-Mar-10 10:44 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2222-Mar-10 10:56
scorpio2222-Mar-10 10:56 
GeneralRe: Stored Procedure with Php and MySQL Pin
PHP_Guy22-Mar-10 11:21
PHP_Guy22-Mar-10 11:21 
GeneralRe: Stored Procedure with Php and MySQL Pin
scorpio2223-Mar-10 3:44
scorpio2223-Mar-10 3:44 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.