You are here: Re: How can a php class read from a properties file? « PHP Programming Language « IT news, forums, messages
Re: How can a php class read from a properties file?

Posted by Anthony Smith on 10/05/14 12:00

On Jan 15, 7:45 am, Rob <ratkin...@tbs-ltd.co.uk> wrote:
> On Jan 11, 9:24 pm,AnthonySmith<mrsmi...@hotmail.com> wrote:
>
> > I have a class that calls some web services. I did not want the url of
> > the web services to be hardcoded in the class. What is the best way to
> > go about doing this?
>
> Anthony, you could do this in a similar way to .Net, by using an
> application configuration file.
>
> The file can then be read in using parse_ini_file() -http://uk.php.net/manual/en/function.parse-ini-file.php
>
> The same thing is sometimes done by storing configuration details in a
> database, and reading those in at runtime.
>
> Rob.

Thanks Rob. Exactly what I was looking for.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация