@@ -8,98 +8,98 @@ API adjustment to the old output control code:
8
8
9
9
Checking output control layers status:
10
10
// Using OG()
11
- php_output_get_status(TSRMLS_C );
11
+ php_output_get_status();
12
12
13
13
Starting the default output handler:
14
- // php_start_ob_buffer(NULL, 0, 1 TSRMLS_CC );
15
- php_output_start_default(TSRMLS_C );
14
+ // php_start_ob_buffer(NULL, 0, 1);
15
+ php_output_start_default();
16
16
17
17
Starting an user handler by zval:
18
- // php_start_ob_buffer(zhandler, chunk_size, erase TSRMLS_CC );
19
- php_output_start_user(zhandler, chunk_size, flags TSRMLS_CC );
18
+ // php_start_ob_buffer(zhandler, chunk_size, erase);
19
+ php_output_start_user(zhandler, chunk_size, flags);
20
20
21
21
Starting an internal handler whithout context:
22
- // php_ob_set_internal_handler(my_php_output_handler_func_t, buffer_size, "output handler name", erase TSRMLS_CC );
23
- php_output_start_internal(handler_name, handler_name_len, my_php_output_handler_func_t, chunk_size, flags TSRMLS_CC );
22
+ // php_ob_set_internal_handler(my_php_output_handler_func_t, buffer_size, "output handler name", erase);
23
+ php_output_start_internal(handler_name, handler_name_len, my_php_output_handler_func_t, chunk_size, flags);
24
24
25
25
Starting an internal handler with context:
26
26
// not possible with old API
27
27
php_output_handler *h;
28
- h = php_output_handler_create_internal(handler_name, handler_name_len, my_php_output_handler_context_func_t, chunk_size, flags TSRMLS_CC );
28
+ h = php_output_handler_create_internal(handler_name, handler_name_len, my_php_output_handler_context_func_t, chunk_size, flags);
29
29
php_output_handler_set_context(h, my_context, my_context_dtor);
30
- php_output_handler_start(h TSRMLS_CC );
30
+ php_output_handler_start(h);
31
31
32
32
Testing whether a certain output handler has already been started:
33
- // php_ob_handler_used("output handler name" TSRMLS_CC );
34
- php_output_handler_started(handler_name, handler_name_len TSRMLS_CC );
33
+ // php_ob_handler_used("output handler name");
34
+ php_output_handler_started(handler_name, handler_name_len);
35
35
36
36
Flushing one output buffer:
37
- // php_end_ob_buffer(1, 1 TSRMLS_CC );
38
- php_output_flush(TSRMLS_C );
37
+ // php_end_ob_buffer(1, 1);
38
+ php_output_flush();
39
39
40
40
Flushing all output buffers:
41
41
// not possible with old API
42
- php_output_flush_all(TSRMLS_C );
42
+ php_output_flush_all();
43
43
44
44
Cleaning one output buffer:
45
- // php_ob_end_buffer(0, 1 TSRMLS_CC );
46
- php_output_clean(TSRMLS_C );
45
+ // php_ob_end_buffer(0, 1);
46
+ php_output_clean();
47
47
48
48
Cleaning all output buffers:
49
49
// not possible with old API
50
- php_output_clean_all(TSRMLS_C );
50
+ php_output_clean_all();
51
51
52
52
Discarding one output buffer:
53
- // php_ob_end_buffer(0, 0 TSRMLS_CC );
54
- php_output_discard(TSRMLS_C );
53
+ // php_ob_end_buffer(0, 0);
54
+ php_output_discard();
55
55
56
56
Discarding all output buffers:
57
- // php_ob_end_buffers(0 TSRMLS_CC );
58
- php_output_discard_all(TSRMLS_C );
57
+ // php_ob_end_buffers(0);
58
+ php_output_discard_all();
59
59
60
60
Stopping (and dropping) one output buffer:
61
- // php_ob_end_buffer(1, 0 TSRMLS_CC )
62
- php_output_end(TSRMLS_C );
61
+ // php_ob_end_buffer(1, 0)
62
+ php_output_end();
63
63
64
64
Stopping (and dropping) all output buffers:
65
- // php_ob_end_buffers(1, 0 TSRMLS_CC );
66
- php_output_end_all(TSRMLS_C );
65
+ // php_ob_end_buffers(1, 0);
66
+ php_output_end_all();
67
67
68
68
Retrieving output buffers contents:
69
- // php_ob_get_buffer(zstring TSRMLS_CC );
70
- php_output_get_contents(zstring TSRMLS_CC );
69
+ // php_ob_get_buffer(zstring);
70
+ php_output_get_contents(zstring);
71
71
72
72
Retrieving output buffers length:
73
- // php_ob_get_length(zlength TSRMLS_CC );
74
- php_output_get_length(zlength TSRMLS_CC );
73
+ // php_ob_get_length(zlength);
74
+ php_output_get_length(zlength);
75
75
76
76
Retrieving output buffering level:
77
77
// OG(nesting_level);
78
- php_output_get_level(TSRMLS_C );
78
+ php_output_get_level();
79
79
80
80
Issue a warning because of an output handler conflict:
81
- // php_ob_init_conflict("to be started handler name", "to be tested if already started handler name" TSRMLS_CC );
82
- php_output_handler_conflict(new_handler_name, new_handler_name_len, set_handler_name, set_handler_name_len TSRMLS_CC );
81
+ // php_ob_init_conflict("to be started handler name", "to be tested if already started handler name");
82
+ php_output_handler_conflict(new_handler_name, new_handler_name_len, set_handler_name, set_handler_name_len);
83
83
84
84
Registering a conflict checking function, which will be checked prior starting the handler:
85
85
// not possible with old API, unless hardcoding into output.c
86
- php_output_handler_conflict_register(handler_name, handler_name_len, my_php_output_handler_conflict_check_t TSRMLS_CC );
86
+ php_output_handler_conflict_register(handler_name, handler_name_len, my_php_output_handler_conflict_check_t);
87
87
88
88
Registering a reverse conflict checking function, which will be checked prior starting the specified foreign handler:
89
89
// not possible with old API
90
- php_output_handler_reverse_conflict_register(foreign_handler_name, foreign_handler_name_len, my_php_output_handler_conflict_check_t TSRMLS_CC );
90
+ php_output_handler_reverse_conflict_register(foreign_handler_name, foreign_handler_name_len, my_php_output_handler_conflict_check_t);
91
91
92
92
Facilitating a context from within an output handler callable with ob_start():
93
93
// not possible with old API
94
- php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_GET_OPAQ, (void *) &custom_ctx_ptr_ptr TSRMLS_CC );
94
+ php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_GET_OPAQ, (void *) &custom_ctx_ptr_ptr);
95
95
96
96
Disabling of the output handler by itself:
97
97
//not possible with old API
98
- php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_DISABLE, NULL TSRMLS_CC );
98
+ php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_DISABLE, NULL);
99
99
100
100
Marking an output handler immutable by itself because of irreversibility of its operation:
101
101
// not possible with old API
102
- php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_IMMUTABLE, NULL TSRMLS_CC );
102
+ php_output_handler_hook(PHP_OUTPUT_HANDLER_HOOK_IMMUTABLE, NULL);
103
103
104
104
Restarting the output handler because of a CLEAN operation:
105
105
// not possible with old API
0 commit comments