开发者

Question about class/module

define('', 'http://' . Config::get('url.help'开发者_开发问答));

Where is it pulling url.help from?

Is this a class or a controller?

What is "Config::get"


It is a public static method (get()) on a class (Config) and the :: is called Paamayim Nekudotayim or the Scope Resolution Operator.

url.help will most likely be explode()d on the . dots and used to return a value from an array like the following:

$config['url']['help'];

The values in $config are most likely taken from a plain text configuration file such as XML, YAML or PHP INI style configuration.


The framework or application you are using must provide :

  • A class called Config
  • Which contains (at least) a static method called get

For more informations, you should read the Classes and Objects section of the PHP manual.


Not sure where the corresponding URL is defined, but I would bet that the value for url.help is taken from some configuration file, or some configuration table in your database.

To know how to edit that value, you'll have to find out how to configure your framework/application -- which probably mean reading its documentation (that is specific to your application/framework, and we cannot just guess).


As a sidenote : define() expects the name of a constant as a first parameter, and not an empty string.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜