-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathhello.c
More file actions
42 lines (35 loc) · 941 Bytes
/
hello.c
File metadata and controls
42 lines (35 loc) · 941 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
#include "hello.h"
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "ext/standard/info.h"
PHP_MINIT_FUNCTION(my_php_extension) {
return SUCCESS;
}
PHP_MSHUTDOWN_FUNCTION(my_php_extension) {
return SUCCESS;
}
PHP_RINIT_FUNCTION(my_php_extension) {
return SUCCESS;
}
PHP_RSHUTDOWN_FUNCTION(my_php_extension) {
return SUCCESS;
}
PHP_MINFO_FUNCTION(my_php_extension) {
php_info_print_table_start();
php_info_print_table_header(2, "My PHP Extension", "enabled");
php_info_print_table_end();
}
zend_module_entry my_php_extension_module_entry = {
STANDARD_MODULE_HEADER,
"my_php_extension",
myextension_functions,
PHP_MINIT(my_php_extension),
PHP_MSHUTDOWN(my_php_extension),
PHP_RINIT(my_php_extension),
PHP_RSHUTDOWN(my_php_extension),
PHP_MINFO(my_php_extension),
PHP_MY_PHP_EXTENSION_VERSION,
STANDARD_MODULE_PROPERTIES
};
ZEND_GET_MODULE(my_php_extension)