Yaf_Dispatcher::getDefaultModule

Retrieve the default module name

説明

public stringnull Yaf_Dispatcher::getDefaultModule()

Get the default module name, which is used when a module name can not be extracted from the request URI. Defaults to "Index".

パラメータ

この関数にはパラメータはありません。

戻り値

The default module name, or null if the application is not initialized.

例

例1 Yaf_Dispatcher::getDefaultModule example

<?php
$app = new Yaf_Application(dirname(__FILE__) . "/conf/application.ini");

var_dump(Yaf_Dispatcher::getInstance()->getDefaultModule());
?>

上の例の出力は、 たとえば以下のようになります。

string(5) "Index"

参考

  • Yaf_Dispatcher::setDefaultModule