This shows you the differences between two versions of the page.
|
dev:coding_guideline [2011/07/29 15:09] sander Links to dev:variables changed to dev:constants |
dev:coding_guideline [2011/08/27 20:32] (current) sander variable -> constant + fix function list link |
||
|---|---|---|---|
| Line 113: | Line 113: | ||
| </code> | </code> | ||
| - | ==== Predefined functions and variables ===== | + | ==== Predefined functions and constants ===== |
| - | Don't try to reinvent the wheel; when working on pluck, you can use the predefined functions and variables. These functions and variables are stored in these files: | + | Don't try to reinvent the wheel; when working on pluck, you can use the predefined functions and constants. These functions and constants are stored in these files: |
| * data/inc/functions.all.php | * data/inc/functions.all.php | ||
| * data/inc/functions.admin.php | * data/inc/functions.admin.php | ||
| Line 122: | Line 122: | ||
| * data/inc/variables.site.php | * data/inc/variables.site.php | ||
| - | The functions and variables defined in a file containing //all// can be used in both the admin center and the code of the website. Functions and variables with //admin// can only be used in the admin center, and with //site// can only be used in the website. | + | The functions and constants defined in a file containing //all// can be used in both the admin center and the code of the website. Functions and constants with //admin// can only be used in the admin center, and with //site// can only be used in the website. |
| - | + | ||
| - | When you think some function or variable can be useful in more cases, you should add the function/variable to the appropriate file. | + | |
| - | + | ||
| - | The functions and variables are explained on this wiki on the pages listed below. If you add a function/variable, please add a description to the page on the wiki. This makes it easier for other developers and module developers to work on pluck efficiently. | + | |
| - | * [[dev:functions|Function list]] | + | |
| - | * [[constants|Variable list]] | + | |
| + | The functions and constants are explained on this wiki on the pages listed below. If you add a function/constant, please add a description to the page on the wiki. This makes it easier for other developers and module developers to work on pluck efficiently. | ||
| + | * **[[http://www.pluck-cms.org/docs_functions/|Function list]]** | ||
| + | * [[dev:constants|Constant list]] | ||