Subversion Repositories Applications.framework

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
5 aurelien 1
<?php
2
 
3
// These are statements and should not have brackets.
4
require_once('blank.inc');
5
require('blank.inc');
6
 
7
$test = true;
8
 
9
// Conditionally including a class file: use include_once
10
if ($test) {
11
    require_once 'blank.inc';
12
    require 'blank.inc';
13
}
14
 
15
// Unconditionally including a class file: use require_once
16
include_once 'blank.inc';
17
include 'blank.inc';
18
 
19
 
20
// These are ok
21
if ($test) {
22
    include_once 'blank.inc';
23
    include 'blank.inc';
24
}
25
 
26
require_once 'blank.inc';
27
require 'blank.inc';
28
 
29
?>
30
<pre>
31
Some content goes here.
32
<?php
33
include_once 'blank.inc';
34
include 'blank.inc';
35
require_once 'blank.inc';
36
require 'blank.inc';
37
?>
38
</pre>
39
<?php
40
 
41
if (include_once 'blank.inc') {
42
    $var = include_once 'blank.inc';
43
    if ($var === true) {
44
    }
45
}
46
 
47
if (require_once 'blank.inc') {
48
    $var = require_once 'blank.inc';
49
    if ($var === true) {
50
    }
51
}
52
 
53
function get_some_value()
54
{
55
    include_once 'blank.inc';
56
    include 'blank.inc';
57
 
58
    // These are ok
59
    if ($test) {
60
        include_once 'blank.inc';
61
        include 'blank.inc';
62
    }
63
 
64
    require_once 'blank.inc';
65
    require 'blank.inc';
66
 
67
    ?>
68
    <pre>
69
    Some content goes here.
70
    <?php
71
    include_once 'blank.inc';
72
    include 'blank.inc';
73
    require_once 'blank.inc';
74
    require 'blank.inc';
75
    ?>
76
    </pre>
77
    <?php
78
 
79
    if (include_once 'blank.inc') {
80
        $var = include_once 'blank.inc';
81
        if ($var === true) {
82
        }
83
    }
84
 
85
    if (require_once 'blank.inc') {
86
        $var = require_once 'blank.inc';
87
        if ($var === true) {
88
        }
89
    }
90
}
91
 
92
 
93
$var = include_once 'blank.inc';
94
if ($var == false) {
95
 
96
}
97
 
98
?>