I can see that the dots will also cause trouble, you are right. In your case you might be better off using Zend_Config_Array.

On the other hand it looks strange to me to see an IP address as a key in any INI file. IP addresses usually are something that could change some day so they shouldn't really be a key. Maybe you might consider something like

[redirect]
IP     = "192.168.0.1"
URL = "http://www.whatever.com";

You might prepend the the keys with a sequence number, if you have more then one redirect... If you should have an ever changing number of redirects then I would think that the whole redirects section should not go into an INI file at all but rather be stored in e.g. a database.

Cheers,

Axel



Alexandre Riveira wrote:
This error is reference a attributte from Zend_Config, examplete

[redirect]
192.168.0.1=http:://...


$config->192.168.0.1 is not attribute valid

Tank's,

Alexandre Riveira
Axel Christ escreveu:

I am quoting from the manual of parse_ini_file():
*Note: * If a value in the ini file contains any non-alphanumeric characters it needs to be enclosed in double-quotes (").

Also I think whitespace around the equals sign might be good, if only for readability.

Cheers,

Axel


Alexandre Riveira wrote:
Zend_Config is not work from content:

[redirect]
200.143.15.7=http://www.mywebsite/page


Solution is possible ?


Tank's

Alexandre Riveira

Reply via email to