This article describes how to compile the Yii extension component. The example analyzes the implementation skills of the extension component in the Yii framework. For more information, see
This article describes how to compile the Yii extension component. The example analyzes the implementation skills of the extension component in the Yii framework. For more information, see
This article describes how to compile the Yii extension component. Share it with you for your reference. The details are as follows:
Yii introduces the component-based idea of Prado as its main idea. Therefore, components are very important in yii.
Components are generally stored in the components directory. The format example is as follows:
<? Php/*** some description about the components */class Utilities extends CController {public static function testTool ($ param) {// codes }}
Sample format:
<? Phpecho Utilities: testTool ($ param);?>
The reason for implementation is also very simple. Because all extensions inherit the basic class of the system, yii imports and registers the method when this method is used in the application.
I hope this article will help you design php programs based on the Yii framework.