This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
tutorials:development:hello_world_page [2010/07/22 21:38] jonyo |
tutorials:development:hello_world_page [2014/09/25 16:55] (current) |
||
---|---|---|---|
Line 15: | Line 15: | ||
//file / | //file / | ||
- | class addon_hello_world_info { | + | class addon_hello_world_info |
- | var $name = ' | + | { |
- | var $version = ' | + | public |
- | var $title = 'Hello World'; | + | public |
- | var $author = "Hello World, Inc."; | + | public |
- | var $description = ' | + | public |
- | var $auth_tag = ' | + | public |
- | var $pages = array ( | + | public |
+ | public | ||
' | ' | ||
); | ); | ||
Line 31: | Line 32: | ||
//file: / | //file: / | ||
- | class addon_hello_world_pages { | + | class addon_hello_world_pages |
- | function hello_world_page(){ | + | { |
+ | public | ||
+ | { | ||
//Note: The method name matches the page name used in the $pages var in info.php | //Note: The method name matches the page name used in the $pages var in info.php | ||
return "Hello World!"; | return "Hello World!"; | ||
Line 57: | Line 60: | ||
// | // | ||
- | class addon_hello_world_pages { | + | class addon_hello_world_pages |
- | function hello_world_page(){ | + | { |
+ | public | ||
+ | { | ||
//Note: The method name matches the page name used in the $pages var in info.php | //Note: The method name matches the page name used in the $pages var in info.php | ||
?> | ?> | ||
Line 100: | Line 105: | ||
//extend our info class, so we can use $this-> to access vars in it | //extend our info class, so we can use $this-> to access vars in it | ||
- | class addon_hello_world_pages extends addon_hello_world_info { | + | class addon_hello_world_pages extends addon_hello_world_info |
+ | { | ||
- | function hello_world_page(){ | + | public |
+ | { | ||
//Note: The method name matches the page name used in the $pages var in info.php | //Note: The method name matches the page name used in the $pages var in info.php | ||
//First, get instance of the view class | //First, get instance of the view class |