[PHP-BUG] Req #60606 [NEW]: Add a `set_ini_file()` function to load user configuration file.

2011-12-25 Thread contact at omeid dot me
From: 
Operating system: Irrelevant
PHP version:  Irrelevant
Package:  PHP options/info functions
Bug Type: Feature/Change Request
Bug description:Add a `set_ini_file()` function to load user configuration file.

Description:

There is `set_ini()` that can be used to change value of a given
configuration 
option and for CGI or Fast-CGI users .user.ini file can be used to override
the 
desired configuration options. but there is nothing when you use PHP as a 
server module.

Please add a `set_ini_file($path_to_user_ini);` function.

Expected result:

Here is a bare minimum example code in PHP:

function ini_set_file($ini_file) {
foreach(parse_ini_file($ini_file) as $option => $newvalue){
ini_set($option, $newvalue);
}
}

 


-- 
Edit bug report at https://bugs.php.net/bug.php?id=60606&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=60606&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=60606&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=60606&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=60606&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=60606&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=60606&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=60606&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=60606&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=60606&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=60606&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=60606&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=60606&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=60606&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=60606&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=60606&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=60606&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=60606&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=60606&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=60606&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=60606&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=60606&r=mysqlcfg



Bug #60603 [Bgs]: PCRE functions and encoding UTF-8

2011-12-25 Thread post at kira-bianca dot de
Edit report at https://bugs.php.net/bug.php?id=60603&edit=1

 ID: 60603
 User updated by:post at kira-bianca dot de
 Reported by:post at kira-bianca dot de
 Summary:PCRE functions and encoding UTF-8
 Status: Bogus
 Type:   Bug
 Package:PCRE related
 Operating System:   Windows XP prof. V2002 with SP3
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

I don't understand, why that should not be a bug. If ONE letter is counted as 
TWO letters, that's for me quite an obvious bug. Maybe ​​my final sentence 
the thing made ambiguous.

Ok, I will not discuss it further. A discussion forum is not really here.


Previous Comments:

[2011-12-24 13:34:22] cataphr...@php.net

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.




[2011-12-23 23:13:36] post at kira-bianca dot de

Description:

Hi!

My HTML source I write in the encoding UTF-8 and I have probably found a bug 
(... soon cost me two hours of searching and working for a flaw in my logic).

And indeed, I want with preg_match() a string to check for valid characters and 
simultaneously for a minimum length. In the string should german special 
characters (Ä, Ö, Ü, ß) also be allowed. As I noted, these are all PCRE 
functions treated as two letters, if the encoding is UTF-8. Examples see below.

For tips on how I can work around this problem, I would be grateful.

greeting
Ki-Bi

Test script:
---
/*
   remark:
   The source is saved with encoding UTF-8 (without BOM)
*/
$animal = 'Bär';
if (preg_match('~^[a-zäöüß\.\- ]{4,26}$~i', $animal)){
echo "$animal has a word length from 4 to 26 letters.\n";
}else{
echo "$animal is too short or too long!\n";}
$string = 'Dörte hütet die Schäfchen und trinkt dabei ein Maß Bier. Ärger 
gibt es dabei nicht.';
echo preg_replace('~[äöüß]~i', '*', $string);

Expected result:

Bär has a word length from 4 to 26 letters.
D**rte h**tet die Sch**fchen und trinkt dabei ein Ma** Bier. *�rger gibt es 
dabei nicht.







-- 
Edit this bug report at https://bugs.php.net/bug.php?id=60603&edit=1


[PHP-BUG] Bug #60607 [NEW]: Blank pages under FastCgi IIS

2011-12-25 Thread chutz747 at gmail dot com
From: 
Operating system: Win server 2008RC2
PHP version:  5.3.8
Package:  IIS related
Bug Type: Bug
Bug description:Blank pages under FastCgi IIS

Description:

Followed installation instructions found all over the internet for
installing PHP via fastCGI on WIN server 2008 IIS7.

Downloaded 5.3.8 VC9 non-thread-safe and copied to c:\php

created registry key for IniFilePath = c:\php

in php.ini

changed php dev ini file to php.ini and uncommented necessary modules
changed module ext directory to c:\php\ext
cgi.force_redirect = 0
cgi.fix_pathinfo=1
fastcgi.impersonate = 1;


set IIS handler mappings to *.php, fastcgimodule, c:\php\php-cgi.exe,
PHP_via_FastCGI

set IIS CGI ISAPI Restrictions 

C:\php\php-cgi.exe, PHP -- tried both allowed and not allowed

SET IIS default document to index.php

added c:\php to windows path

127.0.0.1 localhost is set in hosts file

ALL I GET IS BLANK PAGES 

phpinfo function doesn't even display anything.

am I missing something???

I would like a fix ASAP





Test script:
---


Expected result:

the phpinfo output

Actual result:
--
BLANK PAGE

-- 
Edit bug report at https://bugs.php.net/bug.php?id=60607&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=60607&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=60607&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=60607&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=60607&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=60607&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=60607&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=60607&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=60607&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=60607&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=60607&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=60607&r=notwrong
Not enough info: 
https://bugs.php.net/fix.php?id=60607&r=notenoughinfo
Submitted twice: 
https://bugs.php.net/fix.php?id=60607&r=submittedtwice
register_globals:
https://bugs.php.net/fix.php?id=60607&r=globals
PHP 4 support discontinued:  
https://bugs.php.net/fix.php?id=60607&r=php4
Daylight Savings:https://bugs.php.net/fix.php?id=60607&r=dst
IIS Stability:   
https://bugs.php.net/fix.php?id=60607&r=isapi
Install GNU Sed: 
https://bugs.php.net/fix.php?id=60607&r=gnused
Floating point limitations:  
https://bugs.php.net/fix.php?id=60607&r=float
No Zend Extensions:  
https://bugs.php.net/fix.php?id=60607&r=nozend
MySQL Configuration Error:   
https://bugs.php.net/fix.php?id=60607&r=mysqlcfg



Bug #60607 [Opn->Fbk]: Blank pages under FastCgi IIS

2011-12-25 Thread pajoye
Edit report at https://bugs.php.net/bug.php?id=60607&edit=1

 ID: 60607
 Updated by: paj...@php.net
 Reported by:chutz747 at gmail dot com
 Summary:Blank pages under FastCgi IIS
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:IIS related
 Operating System:   Win server 2008RC2
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

Check the error log


Previous Comments:

[2011-12-25 17:17:35] chutz747 at gmail dot com

Description:

Followed installation instructions found all over the internet for installing 
PHP via fastCGI on WIN server 2008 IIS7.

Downloaded 5.3.8 VC9 non-thread-safe and copied to c:\php

created registry key for IniFilePath = c:\php

in php.ini

changed php dev ini file to php.ini and uncommented necessary modules
changed module ext directory to c:\php\ext
cgi.force_redirect = 0
cgi.fix_pathinfo=1
fastcgi.impersonate = 1;


set IIS handler mappings to *.php, fastcgimodule, c:\php\php-cgi.exe, 
PHP_via_FastCGI

set IIS CGI ISAPI Restrictions 

C:\php\php-cgi.exe, PHP -- tried both allowed and not allowed

SET IIS default document to index.php

added c:\php to windows path

127.0.0.1 localhost is set in hosts file

ALL I GET IS BLANK PAGES 

phpinfo function doesn't even display anything.

am I missing something???

I would like a fix ASAP





Test script:
---


Expected result:

the phpinfo output

Actual result:
--
BLANK PAGE






-- 
Edit this bug report at https://bugs.php.net/bug.php?id=60607&edit=1


Bug #60607 [Com]: Blank pages under FastCgi IIS

2011-12-25 Thread chutz747 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=60607&edit=1

 ID: 60607
 Comment by: chutz747 at gmail dot com
 Reported by:chutz747 at gmail dot com
 Summary:Blank pages under FastCgi IIS
 Status: Feedback
 Type:   Bug
 Package:IIS related
 Operating System:   Win server 2008RC2
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

Resolved - Please Close


Previous Comments:

[2011-12-25 17:20:37] paj...@php.net

Check the error log


[2011-12-25 17:17:35] chutz747 at gmail dot com

Description:

Followed installation instructions found all over the internet for installing 
PHP via fastCGI on WIN server 2008 IIS7.

Downloaded 5.3.8 VC9 non-thread-safe and copied to c:\php

created registry key for IniFilePath = c:\php

in php.ini

changed php dev ini file to php.ini and uncommented necessary modules
changed module ext directory to c:\php\ext
cgi.force_redirect = 0
cgi.fix_pathinfo=1
fastcgi.impersonate = 1;


set IIS handler mappings to *.php, fastcgimodule, c:\php\php-cgi.exe, 
PHP_via_FastCGI

set IIS CGI ISAPI Restrictions 

C:\php\php-cgi.exe, PHP -- tried both allowed and not allowed

SET IIS default document to index.php

added c:\php to windows path

127.0.0.1 localhost is set in hosts file

ALL I GET IS BLANK PAGES 

phpinfo function doesn't even display anything.

am I missing something???

I would like a fix ASAP





Test script:
---


Expected result:

the phpinfo output

Actual result:
--
BLANK PAGE






-- 
Edit this bug report at https://bugs.php.net/bug.php?id=60607&edit=1


Bug #60607 [Fbk->Bgs]: Blank pages under FastCgi IIS

2011-12-25 Thread pajoye
Edit report at https://bugs.php.net/bug.php?id=60607&edit=1

 ID: 60607
 Updated by: paj...@php.net
 Reported by:chutz747 at gmail dot com
 Summary:Blank pages under FastCgi IIS
-Status: Feedback
+Status: Bogus
 Type:   Bug
 Package:IIS related
 Operating System:   Win server 2008RC2
 PHP Version:5.3.8
 Block user comment: N
 Private report: N

 New Comment:

no bug > bogus


Previous Comments:

[2011-12-25 18:02:06] chutz747 at gmail dot com

Resolved - Please Close


[2011-12-25 17:20:37] paj...@php.net

Check the error log


[2011-12-25 17:17:35] chutz747 at gmail dot com

Description:

Followed installation instructions found all over the internet for installing 
PHP via fastCGI on WIN server 2008 IIS7.

Downloaded 5.3.8 VC9 non-thread-safe and copied to c:\php

created registry key for IniFilePath = c:\php

in php.ini

changed php dev ini file to php.ini and uncommented necessary modules
changed module ext directory to c:\php\ext
cgi.force_redirect = 0
cgi.fix_pathinfo=1
fastcgi.impersonate = 1;


set IIS handler mappings to *.php, fastcgimodule, c:\php\php-cgi.exe, 
PHP_via_FastCGI

set IIS CGI ISAPI Restrictions 

C:\php\php-cgi.exe, PHP -- tried both allowed and not allowed

SET IIS default document to index.php

added c:\php to windows path

127.0.0.1 localhost is set in hosts file

ALL I GET IS BLANK PAGES 

phpinfo function doesn't even display anything.

am I missing something???

I would like a fix ASAP





Test script:
---


Expected result:

the phpinfo output

Actual result:
--
BLANK PAGE






-- 
Edit this bug report at https://bugs.php.net/bug.php?id=60607&edit=1


Bug #52062 [Csd->Asn]: large timestamps with DateTime::getTimestamp and DateTime::setTimestamp

2011-12-25 Thread stas
Edit report at https://bugs.php.net/bug.php?id=52062&edit=1

 ID: 52062
 Updated by: s...@php.net
 Reported by:dan at bnet dot lt
 Summary:large timestamps with DateTime::getTimestamp and
 DateTime::setTimestamp
-Status: Closed
+Status: Assigned
 Type:   Bug
 Package:Date/time related
 Operating System:   Ubuntu i686 2.6.32-22-generic
 PHP Version:5.3.2
 Assigned To:derick
 Block user comment: N
 Private report: N

 New Comment:

Still reproduceable for me on Mac OS X in 32-bit mode. Test for bug 52062 fails.


Previous Comments:

[2011-12-06 06:20:53] der...@php.net

Automatic comment from SVN on behalf of derick
Revision: http://svn.php.net/viewvc/?view=revision&revision=320481
Log: - Fixed bug #53502 (strtotime with timezone memory leak).
- Fixed bug #52062 (large timestamps with DateTime::getTimestamp and
  DateTime::setTimestamp).
- Fixed bug #51994 (date_parse_from_format is parsing invalid date using 'yz'
  format).
- Fixed bug #51223 (Seg fault while creating (by unserialization)
  DatePeriod).


[2011-12-06 06:04:14] der...@php.net

This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.




[2011-12-06 06:04:07] der...@php.net

Automatic comment from SVN on behalf of derick
Revision: http://svn.php.net/viewvc/?view=revision&revision=320478
Log: - Fixed bug #52062: large timestamps with DateTime::getTimestamp and 
DateTime::setTimestamp.


[2010-06-12 05:15:09] dan at bnet dot lt

Description:

DateTime::getTimestamp(), DateTime::setTimestamp() and DateInterval does not 
work 
with large timestamps (using numbers over x86 integers)

Test script:
---
$d = new DateTime('@1000');
var_dump($d->format('Y-m-d H:i:s U'));
var_dump($d->getTimestamp());

$d->setTimestamp(1000);
var_dump($d->format('Y-m-d H:i:s U'));
var_dump($d->getTimestamp());

$i = new DateInterval('PT1000S');
var_dump($i->format('%s'));


Expected result:

string(32) "5138-11-16 09:46:40 1000"
float(1000)

string(32) "5138-11-16 09:46:40 1000"
float(1000)

string(12) "1000"

Actual result:
--
string(32) "5138-11-16 09:46:40 1000"
bool(false)

string(30) "2008-07-11 04:56:32 1215752192"
int(1215752192)

Exception with message 'DateInterval::__construct(): Unknown or bad format 
(PT1000S)'






-- 
Edit this bug report at https://bugs.php.net/bug.php?id=52062&edit=1