Welcome, Guest. Register Now!
   
Mark Forums Read Mark Forums Read Mark Forums Read


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-25-2007, 08:58 PM
Junior Member
 
Join Date: Jul 2007
Posts: 11
Default Zend_Config_Ini chokes on exclamation point

Hello!

I have an .ini file that contains a section that looks like:
[FOO]
password = some!password
The exclamation point seems to cause zend_config_ini to barf:

Warning: Error parsing ... in C:\xampp\php\PEAR\Zend\Config\Ini.php on line 102

Any ideas?

Thanks!
- Bret
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 10-25-2007, 10:23 PM
Elemental's Avatar
Senior Member
 
Join Date: Jul 2007
Posts: 119
Default

you could convert to xml vs. ini

Zend_Config_Xml ftw!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 10-26-2007, 05:44 PM
Junior Member
 
Join Date: Jul 2007
Posts: 11
Default

I suppose I could convert to XML, but I'd rather not convert our entire system to use the XML format unless it's absolutely my last resort. Is this problem with !'s an issue with Zend, or a fundamental issue with the underlying parse_ini_file command?

Thanks!
- Bret
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 10-27-2007, 09:09 AM
Junior Member
 
Join Date: Oct 2007
Posts: 2
Default

Just put quotes around the value, such as this:

[FOO]
password = "some!password"

Andy
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 06:06 AM.