@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php return array ( |
2 | - 'root' => |
|
3 | - array ( |
|
2 | + 'root' => |
|
3 | + array ( |
|
4 | 4 | 'pretty_version' => 'dev-master', |
5 | 5 | 'version' => 'dev-master', |
6 | 6 | 'aliases' => |
@@ -8,85 +8,85 @@ discard block |
||
8 | 8 | ), |
9 | 9 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
10 | 10 | 'name' => 'ayecode/invoicing', |
11 | - ), |
|
12 | - 'versions' => |
|
13 | - array ( |
|
11 | + ), |
|
12 | + 'versions' => |
|
13 | + array ( |
|
14 | 14 | 'ayecode/ayecode-connect-helper' => |
15 | 15 | array ( |
16 | - 'pretty_version' => '1.0.3', |
|
17 | - 'version' => '1.0.3.0', |
|
18 | - 'aliases' => |
|
19 | - array ( |
|
20 | - ), |
|
21 | - 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
|
16 | + 'pretty_version' => '1.0.3', |
|
17 | + 'version' => '1.0.3.0', |
|
18 | + 'aliases' => |
|
19 | + array ( |
|
20 | + ), |
|
21 | + 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
|
22 | 22 | ), |
23 | 23 | 'ayecode/invoicing' => |
24 | 24 | array ( |
25 | - 'pretty_version' => 'dev-master', |
|
26 | - 'version' => 'dev-master', |
|
27 | - 'aliases' => |
|
28 | - array ( |
|
29 | - ), |
|
30 | - 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
|
25 | + 'pretty_version' => 'dev-master', |
|
26 | + 'version' => 'dev-master', |
|
27 | + 'aliases' => |
|
28 | + array ( |
|
29 | + ), |
|
30 | + 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
|
31 | 31 | ), |
32 | 32 | 'ayecode/wp-ayecode-ui' => |
33 | 33 | array ( |
34 | - 'pretty_version' => '0.1.45', |
|
35 | - 'version' => '0.1.45.0', |
|
36 | - 'aliases' => |
|
37 | - array ( |
|
38 | - ), |
|
39 | - 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
|
34 | + 'pretty_version' => '0.1.45', |
|
35 | + 'version' => '0.1.45.0', |
|
36 | + 'aliases' => |
|
37 | + array ( |
|
38 | + ), |
|
39 | + 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
|
40 | 40 | ), |
41 | 41 | 'ayecode/wp-font-awesome-settings' => |
42 | 42 | array ( |
43 | - 'pretty_version' => '1.0.12', |
|
44 | - 'version' => '1.0.12.0', |
|
45 | - 'aliases' => |
|
46 | - array ( |
|
47 | - ), |
|
48 | - 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
|
43 | + 'pretty_version' => '1.0.12', |
|
44 | + 'version' => '1.0.12.0', |
|
45 | + 'aliases' => |
|
46 | + array ( |
|
47 | + ), |
|
48 | + 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
|
49 | 49 | ), |
50 | 50 | 'ayecode/wp-super-duper' => |
51 | 51 | array ( |
52 | - 'pretty_version' => '1.0.24', |
|
53 | - 'version' => '1.0.24.0', |
|
54 | - 'aliases' => |
|
55 | - array ( |
|
56 | - ), |
|
57 | - 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
|
52 | + 'pretty_version' => '1.0.24', |
|
53 | + 'version' => '1.0.24.0', |
|
54 | + 'aliases' => |
|
55 | + array ( |
|
56 | + ), |
|
57 | + 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
|
58 | 58 | ), |
59 | 59 | 'composer/installers' => |
60 | 60 | array ( |
61 | - 'pretty_version' => 'v1.10.0', |
|
62 | - 'version' => '1.10.0.0', |
|
63 | - 'aliases' => |
|
64 | - array ( |
|
65 | - ), |
|
66 | - 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
|
61 | + 'pretty_version' => 'v1.10.0', |
|
62 | + 'version' => '1.10.0.0', |
|
63 | + 'aliases' => |
|
64 | + array ( |
|
65 | + ), |
|
66 | + 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
|
67 | 67 | ), |
68 | 68 | 'maxmind-db/reader' => |
69 | 69 | array ( |
70 | - 'pretty_version' => 'v1.6.0', |
|
71 | - 'version' => '1.6.0.0', |
|
72 | - 'aliases' => |
|
73 | - array ( |
|
74 | - ), |
|
75 | - 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
|
70 | + 'pretty_version' => 'v1.6.0', |
|
71 | + 'version' => '1.6.0.0', |
|
72 | + 'aliases' => |
|
73 | + array ( |
|
74 | + ), |
|
75 | + 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
|
76 | 76 | ), |
77 | 77 | 'roundcube/plugin-installer' => |
78 | 78 | array ( |
79 | - 'replaced' => |
|
80 | - array ( |
|
79 | + 'replaced' => |
|
80 | + array ( |
|
81 | 81 | 0 => '*', |
82 | - ), |
|
82 | + ), |
|
83 | 83 | ), |
84 | 84 | 'shama/baton' => |
85 | 85 | array ( |
86 | - 'replaced' => |
|
87 | - array ( |
|
86 | + 'replaced' => |
|
87 | + array ( |
|
88 | 88 | 0 => '*', |
89 | - ), |
|
89 | + ), |
|
90 | + ), |
|
90 | 91 | ), |
91 | - ), |
|
92 | 92 | ); |
@@ -1,90 +1,90 @@ |
||
1 | -<?php return array ( |
|
1 | +<?php return array( |
|
2 | 2 | 'root' => |
3 | - array ( |
|
3 | + array( |
|
4 | 4 | 'pretty_version' => 'dev-master', |
5 | 5 | 'version' => 'dev-master', |
6 | 6 | 'aliases' => |
7 | - array ( |
|
7 | + array( |
|
8 | 8 | ), |
9 | 9 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
10 | 10 | 'name' => 'ayecode/invoicing', |
11 | 11 | ), |
12 | 12 | 'versions' => |
13 | - array ( |
|
13 | + array( |
|
14 | 14 | 'ayecode/ayecode-connect-helper' => |
15 | - array ( |
|
15 | + array( |
|
16 | 16 | 'pretty_version' => '1.0.3', |
17 | 17 | 'version' => '1.0.3.0', |
18 | 18 | 'aliases' => |
19 | - array ( |
|
19 | + array( |
|
20 | 20 | ), |
21 | 21 | 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
22 | 22 | ), |
23 | 23 | 'ayecode/invoicing' => |
24 | - array ( |
|
24 | + array( |
|
25 | 25 | 'pretty_version' => 'dev-master', |
26 | 26 | 'version' => 'dev-master', |
27 | 27 | 'aliases' => |
28 | - array ( |
|
28 | + array( |
|
29 | 29 | ), |
30 | 30 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
31 | 31 | ), |
32 | 32 | 'ayecode/wp-ayecode-ui' => |
33 | - array ( |
|
33 | + array( |
|
34 | 34 | 'pretty_version' => '0.1.45', |
35 | 35 | 'version' => '0.1.45.0', |
36 | 36 | 'aliases' => |
37 | - array ( |
|
37 | + array( |
|
38 | 38 | ), |
39 | 39 | 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
40 | 40 | ), |
41 | 41 | 'ayecode/wp-font-awesome-settings' => |
42 | - array ( |
|
42 | + array( |
|
43 | 43 | 'pretty_version' => '1.0.12', |
44 | 44 | 'version' => '1.0.12.0', |
45 | 45 | 'aliases' => |
46 | - array ( |
|
46 | + array( |
|
47 | 47 | ), |
48 | 48 | 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
49 | 49 | ), |
50 | 50 | 'ayecode/wp-super-duper' => |
51 | - array ( |
|
51 | + array( |
|
52 | 52 | 'pretty_version' => '1.0.24', |
53 | 53 | 'version' => '1.0.24.0', |
54 | 54 | 'aliases' => |
55 | - array ( |
|
55 | + array( |
|
56 | 56 | ), |
57 | 57 | 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
58 | 58 | ), |
59 | 59 | 'composer/installers' => |
60 | - array ( |
|
60 | + array( |
|
61 | 61 | 'pretty_version' => 'v1.10.0', |
62 | 62 | 'version' => '1.10.0.0', |
63 | 63 | 'aliases' => |
64 | - array ( |
|
64 | + array( |
|
65 | 65 | ), |
66 | 66 | 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
67 | 67 | ), |
68 | 68 | 'maxmind-db/reader' => |
69 | - array ( |
|
69 | + array( |
|
70 | 70 | 'pretty_version' => 'v1.6.0', |
71 | 71 | 'version' => '1.6.0.0', |
72 | 72 | 'aliases' => |
73 | - array ( |
|
73 | + array( |
|
74 | 74 | ), |
75 | 75 | 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
76 | 76 | ), |
77 | 77 | 'roundcube/plugin-installer' => |
78 | - array ( |
|
78 | + array( |
|
79 | 79 | 'replaced' => |
80 | - array ( |
|
80 | + array( |
|
81 | 81 | 0 => '*', |
82 | 82 | ), |
83 | 83 | ), |
84 | 84 | 'shama/baton' => |
85 | - array ( |
|
85 | + array( |
|
86 | 86 | 'replaced' => |
87 | - array ( |
|
87 | + array( |
|
88 | 88 | 0 => '*', |
89 | 89 | ), |
90 | 90 | ), |
@@ -12,8 +12,8 @@ discard block |
||
12 | 12 | class InstalledVersions |
13 | 13 | { |
14 | 14 | private static $installed = array ( |
15 | - 'root' => |
|
16 | - array ( |
|
15 | + 'root' => |
|
16 | + array ( |
|
17 | 17 | 'pretty_version' => 'dev-master', |
18 | 18 | 'version' => 'dev-master', |
19 | 19 | 'aliases' => |
@@ -21,87 +21,87 @@ discard block |
||
21 | 21 | ), |
22 | 22 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
23 | 23 | 'name' => 'ayecode/invoicing', |
24 | - ), |
|
25 | - 'versions' => |
|
26 | - array ( |
|
24 | + ), |
|
25 | + 'versions' => |
|
26 | + array ( |
|
27 | 27 | 'ayecode/ayecode-connect-helper' => |
28 | 28 | array ( |
29 | - 'pretty_version' => '1.0.3', |
|
30 | - 'version' => '1.0.3.0', |
|
31 | - 'aliases' => |
|
32 | - array ( |
|
33 | - ), |
|
34 | - 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
|
29 | + 'pretty_version' => '1.0.3', |
|
30 | + 'version' => '1.0.3.0', |
|
31 | + 'aliases' => |
|
32 | + array ( |
|
33 | + ), |
|
34 | + 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
|
35 | 35 | ), |
36 | 36 | 'ayecode/invoicing' => |
37 | 37 | array ( |
38 | - 'pretty_version' => 'dev-master', |
|
39 | - 'version' => 'dev-master', |
|
40 | - 'aliases' => |
|
41 | - array ( |
|
42 | - ), |
|
43 | - 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
|
38 | + 'pretty_version' => 'dev-master', |
|
39 | + 'version' => 'dev-master', |
|
40 | + 'aliases' => |
|
41 | + array ( |
|
42 | + ), |
|
43 | + 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
|
44 | 44 | ), |
45 | 45 | 'ayecode/wp-ayecode-ui' => |
46 | 46 | array ( |
47 | - 'pretty_version' => '0.1.45', |
|
48 | - 'version' => '0.1.45.0', |
|
49 | - 'aliases' => |
|
50 | - array ( |
|
51 | - ), |
|
52 | - 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
|
47 | + 'pretty_version' => '0.1.45', |
|
48 | + 'version' => '0.1.45.0', |
|
49 | + 'aliases' => |
|
50 | + array ( |
|
51 | + ), |
|
52 | + 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
|
53 | 53 | ), |
54 | 54 | 'ayecode/wp-font-awesome-settings' => |
55 | 55 | array ( |
56 | - 'pretty_version' => '1.0.12', |
|
57 | - 'version' => '1.0.12.0', |
|
58 | - 'aliases' => |
|
59 | - array ( |
|
60 | - ), |
|
61 | - 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
|
56 | + 'pretty_version' => '1.0.12', |
|
57 | + 'version' => '1.0.12.0', |
|
58 | + 'aliases' => |
|
59 | + array ( |
|
60 | + ), |
|
61 | + 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
|
62 | 62 | ), |
63 | 63 | 'ayecode/wp-super-duper' => |
64 | 64 | array ( |
65 | - 'pretty_version' => '1.0.24', |
|
66 | - 'version' => '1.0.24.0', |
|
67 | - 'aliases' => |
|
68 | - array ( |
|
69 | - ), |
|
70 | - 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
|
65 | + 'pretty_version' => '1.0.24', |
|
66 | + 'version' => '1.0.24.0', |
|
67 | + 'aliases' => |
|
68 | + array ( |
|
69 | + ), |
|
70 | + 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
|
71 | 71 | ), |
72 | 72 | 'composer/installers' => |
73 | 73 | array ( |
74 | - 'pretty_version' => 'v1.10.0', |
|
75 | - 'version' => '1.10.0.0', |
|
76 | - 'aliases' => |
|
77 | - array ( |
|
78 | - ), |
|
79 | - 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
|
74 | + 'pretty_version' => 'v1.10.0', |
|
75 | + 'version' => '1.10.0.0', |
|
76 | + 'aliases' => |
|
77 | + array ( |
|
78 | + ), |
|
79 | + 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
|
80 | 80 | ), |
81 | 81 | 'maxmind-db/reader' => |
82 | 82 | array ( |
83 | - 'pretty_version' => 'v1.6.0', |
|
84 | - 'version' => '1.6.0.0', |
|
85 | - 'aliases' => |
|
86 | - array ( |
|
87 | - ), |
|
88 | - 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
|
83 | + 'pretty_version' => 'v1.6.0', |
|
84 | + 'version' => '1.6.0.0', |
|
85 | + 'aliases' => |
|
86 | + array ( |
|
87 | + ), |
|
88 | + 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
|
89 | 89 | ), |
90 | 90 | 'roundcube/plugin-installer' => |
91 | 91 | array ( |
92 | - 'replaced' => |
|
93 | - array ( |
|
92 | + 'replaced' => |
|
93 | + array ( |
|
94 | 94 | 0 => '*', |
95 | - ), |
|
95 | + ), |
|
96 | 96 | ), |
97 | 97 | 'shama/baton' => |
98 | 98 | array ( |
99 | - 'replaced' => |
|
100 | - array ( |
|
99 | + 'replaced' => |
|
100 | + array ( |
|
101 | 101 | 0 => '*', |
102 | - ), |
|
102 | + ), |
|
103 | + ), |
|
103 | 104 | ), |
104 | - ), |
|
105 | 105 | ); |
106 | 106 | |
107 | 107 |
@@ -11,93 +11,93 @@ |
||
11 | 11 | |
12 | 12 | class InstalledVersions |
13 | 13 | { |
14 | -private static $installed = array ( |
|
14 | +private static $installed = array( |
|
15 | 15 | 'root' => |
16 | - array ( |
|
16 | + array( |
|
17 | 17 | 'pretty_version' => 'dev-master', |
18 | 18 | 'version' => 'dev-master', |
19 | 19 | 'aliases' => |
20 | - array ( |
|
20 | + array( |
|
21 | 21 | ), |
22 | 22 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
23 | 23 | 'name' => 'ayecode/invoicing', |
24 | 24 | ), |
25 | 25 | 'versions' => |
26 | - array ( |
|
26 | + array( |
|
27 | 27 | 'ayecode/ayecode-connect-helper' => |
28 | - array ( |
|
28 | + array( |
|
29 | 29 | 'pretty_version' => '1.0.3', |
30 | 30 | 'version' => '1.0.3.0', |
31 | 31 | 'aliases' => |
32 | - array ( |
|
32 | + array( |
|
33 | 33 | ), |
34 | 34 | 'reference' => '1af7cdefdbd20d4443a3ab4834e4c1cd8fe57fb4', |
35 | 35 | ), |
36 | 36 | 'ayecode/invoicing' => |
37 | - array ( |
|
37 | + array( |
|
38 | 38 | 'pretty_version' => 'dev-master', |
39 | 39 | 'version' => 'dev-master', |
40 | 40 | 'aliases' => |
41 | - array ( |
|
41 | + array( |
|
42 | 42 | ), |
43 | 43 | 'reference' => '30e6738f2073aa51f1c360079453e76cfcfb9854', |
44 | 44 | ), |
45 | 45 | 'ayecode/wp-ayecode-ui' => |
46 | - array ( |
|
46 | + array( |
|
47 | 47 | 'pretty_version' => '0.1.45', |
48 | 48 | 'version' => '0.1.45.0', |
49 | 49 | 'aliases' => |
50 | - array ( |
|
50 | + array( |
|
51 | 51 | ), |
52 | 52 | 'reference' => 'a8f19cac8310de825ae5fec71d57184ebb2d78d0', |
53 | 53 | ), |
54 | 54 | 'ayecode/wp-font-awesome-settings' => |
55 | - array ( |
|
55 | + array( |
|
56 | 56 | 'pretty_version' => '1.0.12', |
57 | 57 | 'version' => '1.0.12.0', |
58 | 58 | 'aliases' => |
59 | - array ( |
|
59 | + array( |
|
60 | 60 | ), |
61 | 61 | 'reference' => '754cca6fda775f3e0b56b90a810dfcaea62ea288', |
62 | 62 | ), |
63 | 63 | 'ayecode/wp-super-duper' => |
64 | - array ( |
|
64 | + array( |
|
65 | 65 | 'pretty_version' => '1.0.24', |
66 | 66 | 'version' => '1.0.24.0', |
67 | 67 | 'aliases' => |
68 | - array ( |
|
68 | + array( |
|
69 | 69 | ), |
70 | 70 | 'reference' => '4eaa2f6f6e1a29ff71f7fdbd694892d7479ef754', |
71 | 71 | ), |
72 | 72 | 'composer/installers' => |
73 | - array ( |
|
73 | + array( |
|
74 | 74 | 'pretty_version' => 'v1.10.0', |
75 | 75 | 'version' => '1.10.0.0', |
76 | 76 | 'aliases' => |
77 | - array ( |
|
77 | + array( |
|
78 | 78 | ), |
79 | 79 | 'reference' => '1a0357fccad9d1cc1ea0c9a05b8847fbccccb78d', |
80 | 80 | ), |
81 | 81 | 'maxmind-db/reader' => |
82 | - array ( |
|
82 | + array( |
|
83 | 83 | 'pretty_version' => 'v1.6.0', |
84 | 84 | 'version' => '1.6.0.0', |
85 | 85 | 'aliases' => |
86 | - array ( |
|
86 | + array( |
|
87 | 87 | ), |
88 | 88 | 'reference' => 'febd4920bf17c1da84cef58e56a8227dfb37fbe4', |
89 | 89 | ), |
90 | 90 | 'roundcube/plugin-installer' => |
91 | - array ( |
|
91 | + array( |
|
92 | 92 | 'replaced' => |
93 | - array ( |
|
93 | + array( |
|
94 | 94 | 0 => '*', |
95 | 95 | ), |
96 | 96 | ), |
97 | 97 | 'shama/baton' => |
98 | - array ( |
|
98 | + array( |
|
99 | 99 | 'replaced' => |
100 | - array ( |
|
100 | + array( |
|
101 | 101 | 0 => '*', |
102 | 102 | ), |
103 | 103 | ), |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | if ( ! defined( 'ABSPATH' ) ) { |
3 | - exit; |
|
3 | + exit; |
|
4 | 4 | } |
5 | 5 | |
6 | 6 | /** |
@@ -20,29 +20,29 @@ discard block |
||
20 | 20 | public $templates_url; |
21 | 21 | |
22 | 22 | /** |
23 | - * Class constructor. |
|
24 | - * |
|
25 | - * @since 1.0.19 |
|
26 | - */ |
|
27 | - public function __construct() { |
|
23 | + * Class constructor. |
|
24 | + * |
|
25 | + * @since 1.0.19 |
|
26 | + */ |
|
27 | + public function __construct() { |
|
28 | 28 | |
29 | 29 | $this->templates_dir = apply_filters( 'getpaid_default_templates_dir', WPINV_PLUGIN_DIR . 'templates' ); |
30 | 30 | $this->templates_url = apply_filters( 'getpaid_default_templates_url', WPINV_PLUGIN_URL . 'templates' ); |
31 | 31 | |
32 | 32 | // Oxygen plugin |
33 | - if ( defined( 'CT_VERSION' ) ) { |
|
34 | - add_filter( 'wpinv_locate_template', array( $this, 'oxygen_override_template' ), 11, 4 ); |
|
35 | - } |
|
33 | + if ( defined( 'CT_VERSION' ) ) { |
|
34 | + add_filter( 'wpinv_locate_template', array( $this, 'oxygen_override_template' ), 11, 4 ); |
|
35 | + } |
|
36 | 36 | |
37 | 37 | } |
38 | 38 | |
39 | 39 | /** |
40 | - * Checks if this is a preview page |
|
41 | - * |
|
42 | - * @since 1.0.19 |
|
43 | - * @return bool |
|
44 | - */ |
|
45 | - public function is_preview() { |
|
40 | + * Checks if this is a preview page |
|
41 | + * |
|
42 | + * @since 1.0.19 |
|
43 | + * @return bool |
|
44 | + */ |
|
45 | + public function is_preview() { |
|
46 | 46 | return |
47 | 47 | $this->is_divi_preview() || |
48 | 48 | $this->is_elementor_preview() || |
@@ -54,73 +54,73 @@ discard block |
||
54 | 54 | } |
55 | 55 | |
56 | 56 | /** |
57 | - * Checks if this is an elementor preview page |
|
58 | - * |
|
59 | - * @since 1.0.19 |
|
60 | - * @return bool |
|
61 | - */ |
|
62 | - public function is_elementor_preview() { |
|
63 | - return isset( $_REQUEST['elementor-preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor' ) || ( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor_ajax' ); |
|
64 | - } |
|
65 | - |
|
66 | - /** |
|
67 | - * Checks if this is a DIVI preview page |
|
68 | - * |
|
69 | - * @since 1.0.19 |
|
70 | - * @return bool |
|
71 | - */ |
|
72 | - public function is_divi_preview() { |
|
73 | - return isset( $_REQUEST['et_fb'] ) || isset( $_REQUEST['et_pb_preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'et_pb' ); |
|
74 | - } |
|
75 | - |
|
76 | - /** |
|
77 | - * Checks if this is a beaver builder preview page |
|
78 | - * |
|
79 | - * @since 1.0.19 |
|
80 | - * @return bool |
|
81 | - */ |
|
82 | - public function is_beaver_preview() { |
|
83 | - return isset( $_REQUEST['fl_builder'] ); |
|
84 | - } |
|
85 | - |
|
86 | - /** |
|
87 | - * Checks if this is a siteorigin builder preview page |
|
88 | - * |
|
89 | - * @since 1.0.19 |
|
90 | - * @return bool |
|
91 | - */ |
|
92 | - public function is_siteorigin_preview() { |
|
93 | - return ! empty( $_REQUEST['siteorigin_panels_live_editor'] ); |
|
94 | - } |
|
95 | - |
|
96 | - /** |
|
97 | - * Checks if this is a cornerstone builder preview page |
|
98 | - * |
|
99 | - * @since 1.0.19 |
|
100 | - * @return bool |
|
101 | - */ |
|
102 | - public function is_cornerstone_preview() { |
|
103 | - return ! empty( $_REQUEST['cornerstone_preview'] ) || basename( $_SERVER['REQUEST_URI'] ) == 'cornerstone-endpoint'; |
|
104 | - } |
|
105 | - |
|
106 | - /** |
|
107 | - * Checks if this is a fusion builder preview page |
|
108 | - * |
|
109 | - * @since 1.0.19 |
|
110 | - * @return bool |
|
111 | - */ |
|
112 | - public function is_fusion_preview() { |
|
113 | - return ! empty( $_REQUEST['fb-edit'] ) || ! empty( $_REQUEST['fusion_load_nonce'] ); |
|
114 | - } |
|
115 | - |
|
116 | - /** |
|
117 | - * Checks if this is an oxygen builder preview page |
|
118 | - * |
|
119 | - * @since 1.0.19 |
|
120 | - * @return bool |
|
121 | - */ |
|
122 | - public function is_oxygen_preview() { |
|
123 | - return ! empty( $_REQUEST['ct_builder'] ) || ( ! empty( $_REQUEST['action'] ) && ( substr( $_REQUEST['action'], 0, 11 ) === "oxy_render_" || substr( $_REQUEST['action'], 0, 10 ) === "ct_render_" ) ); |
|
57 | + * Checks if this is an elementor preview page |
|
58 | + * |
|
59 | + * @since 1.0.19 |
|
60 | + * @return bool |
|
61 | + */ |
|
62 | + public function is_elementor_preview() { |
|
63 | + return isset( $_REQUEST['elementor-preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor' ) || ( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor_ajax' ); |
|
64 | + } |
|
65 | + |
|
66 | + /** |
|
67 | + * Checks if this is a DIVI preview page |
|
68 | + * |
|
69 | + * @since 1.0.19 |
|
70 | + * @return bool |
|
71 | + */ |
|
72 | + public function is_divi_preview() { |
|
73 | + return isset( $_REQUEST['et_fb'] ) || isset( $_REQUEST['et_pb_preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'et_pb' ); |
|
74 | + } |
|
75 | + |
|
76 | + /** |
|
77 | + * Checks if this is a beaver builder preview page |
|
78 | + * |
|
79 | + * @since 1.0.19 |
|
80 | + * @return bool |
|
81 | + */ |
|
82 | + public function is_beaver_preview() { |
|
83 | + return isset( $_REQUEST['fl_builder'] ); |
|
84 | + } |
|
85 | + |
|
86 | + /** |
|
87 | + * Checks if this is a siteorigin builder preview page |
|
88 | + * |
|
89 | + * @since 1.0.19 |
|
90 | + * @return bool |
|
91 | + */ |
|
92 | + public function is_siteorigin_preview() { |
|
93 | + return ! empty( $_REQUEST['siteorigin_panels_live_editor'] ); |
|
94 | + } |
|
95 | + |
|
96 | + /** |
|
97 | + * Checks if this is a cornerstone builder preview page |
|
98 | + * |
|
99 | + * @since 1.0.19 |
|
100 | + * @return bool |
|
101 | + */ |
|
102 | + public function is_cornerstone_preview() { |
|
103 | + return ! empty( $_REQUEST['cornerstone_preview'] ) || basename( $_SERVER['REQUEST_URI'] ) == 'cornerstone-endpoint'; |
|
104 | + } |
|
105 | + |
|
106 | + /** |
|
107 | + * Checks if this is a fusion builder preview page |
|
108 | + * |
|
109 | + * @since 1.0.19 |
|
110 | + * @return bool |
|
111 | + */ |
|
112 | + public function is_fusion_preview() { |
|
113 | + return ! empty( $_REQUEST['fb-edit'] ) || ! empty( $_REQUEST['fusion_load_nonce'] ); |
|
114 | + } |
|
115 | + |
|
116 | + /** |
|
117 | + * Checks if this is an oxygen builder preview page |
|
118 | + * |
|
119 | + * @since 1.0.19 |
|
120 | + * @return bool |
|
121 | + */ |
|
122 | + public function is_oxygen_preview() { |
|
123 | + return ! empty( $_REQUEST['ct_builder'] ) || ( ! empty( $_REQUEST['action'] ) && ( substr( $_REQUEST['action'], 0, 11 ) === "oxy_render_" || substr( $_REQUEST['action'], 0, 10 ) === "ct_render_" ) ); |
|
124 | 124 | } |
125 | 125 | |
126 | 126 | /** |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | * @param string $template_path The template path relative to the theme's root dir. Defaults to 'invoicing'. |
131 | 131 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
132 | 132 | */ |
133 | - public function locate_template( $template_name, $template_path = '', $default_path = '' ) { |
|
133 | + public function locate_template( $template_name, $template_path = '', $default_path = '' ) { |
|
134 | 134 | |
135 | 135 | // Load the defaults for the template path and default path. |
136 | 136 | $template_path = empty( $template_path ) ? 'invoicing' : $template_path; |
@@ -151,22 +151,22 @@ discard block |
||
151 | 151 | } |
152 | 152 | |
153 | 153 | /** |
154 | - * Loads a template |
|
155 | - * |
|
156 | - * @since 1.0.19 |
|
157 | - * @return bool |
|
158 | - */ |
|
159 | - protected function load_template( $template_name, $template_path, $args ) { |
|
154 | + * Loads a template |
|
155 | + * |
|
156 | + * @since 1.0.19 |
|
157 | + * @return bool |
|
158 | + */ |
|
159 | + protected function load_template( $template_name, $template_path, $args ) { |
|
160 | 160 | |
161 | 161 | if ( is_array( $args ) ){ |
162 | 162 | extract( $args ); |
163 | 163 | } |
164 | 164 | |
165 | 165 | // Fires before loading a template. |
166 | - do_action( 'wpinv_before_template_part', $template_name, $template_path, $args ); |
|
166 | + do_action( 'wpinv_before_template_part', $template_name, $template_path, $args ); |
|
167 | 167 | |
168 | 168 | // Load the template. |
169 | - include( $template_path ); |
|
169 | + include( $template_path ); |
|
170 | 170 | |
171 | 171 | // Fires after loading a template. |
172 | 172 | do_action( 'wpinv_after_template_part', $template_name, $template_path, $args ); |
@@ -183,7 +183,7 @@ discard block |
||
183 | 183 | * @param string $template_path The templates directory relative to the theme's root dir. Defaults to 'invoicing'. |
184 | 184 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
185 | 185 | */ |
186 | - public function display_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
186 | + public function display_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
187 | 187 | |
188 | 188 | // Locate the template. |
189 | 189 | $located = $this->locate_template( $template_name, $template_path, $default_path ); |
@@ -208,74 +208,74 @@ discard block |
||
208 | 208 | * @param string $template_path The templates directory relative to the theme's root dir. Defaults to 'invoicing'. |
209 | 209 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
210 | 210 | */ |
211 | - public function get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
211 | + public function get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
212 | 212 | ob_start(); |
213 | 213 | $this->display_template( $template_name, $args, $template_path, $default_path ); |
214 | 214 | return ob_get_clean(); |
215 | 215 | } |
216 | 216 | |
217 | 217 | /** |
218 | - * Get the geodirectory templates theme path. |
|
219 | - * |
|
220 | - * |
|
221 | - * @return string Template path. |
|
222 | - */ |
|
223 | - public static function get_theme_template_path() { |
|
224 | - $template = get_template(); |
|
225 | - $theme_root = get_theme_root( $template ); |
|
226 | - |
|
227 | - return $theme_root . '/' . $template . '/' . untrailingslashit( wpinv_get_theme_template_dir_name() ); |
|
228 | - |
|
229 | - } |
|
230 | - |
|
231 | - /** |
|
232 | - * Oxygen locate theme template. |
|
233 | - * |
|
234 | - * @param string $template The template. |
|
235 | - * @return string The theme template. |
|
236 | - */ |
|
237 | - public static function oxygen_locate_template( $template ) { |
|
238 | - |
|
239 | - if ( empty( $template ) ) { |
|
240 | - return ''; |
|
241 | - } |
|
242 | - |
|
243 | - $has_filter = has_filter( 'template', 'ct_oxygen_template_name' ); |
|
244 | - |
|
245 | - // Remove template filter |
|
246 | - if ( $has_filter ) { |
|
247 | - remove_filter( 'template', 'ct_oxygen_template_name' ); |
|
248 | - } |
|
249 | - |
|
250 | - $template = self::get_theme_template_path() . '/' . $template; |
|
251 | - |
|
252 | - if ( ! file_exists( $template ) ) { |
|
253 | - $template = ''; |
|
254 | - } |
|
255 | - |
|
256 | - // Add template filter |
|
257 | - if ( $has_filter ) { |
|
258 | - add_filter( 'template', 'ct_oxygen_template_name' ); |
|
259 | - } |
|
260 | - |
|
261 | - return $template; |
|
262 | - } |
|
263 | - |
|
264 | - /** |
|
265 | - * Oxygen override theme template. |
|
266 | - * |
|
267 | - * @param string $located Located template. |
|
268 | - * @param string $template_name Template name. |
|
269 | - * @return string Located template. |
|
270 | - */ |
|
271 | - public function oxygen_override_template( $located, $template_name ) { |
|
218 | + * Get the geodirectory templates theme path. |
|
219 | + * |
|
220 | + * |
|
221 | + * @return string Template path. |
|
222 | + */ |
|
223 | + public static function get_theme_template_path() { |
|
224 | + $template = get_template(); |
|
225 | + $theme_root = get_theme_root( $template ); |
|
226 | + |
|
227 | + return $theme_root . '/' . $template . '/' . untrailingslashit( wpinv_get_theme_template_dir_name() ); |
|
228 | + |
|
229 | + } |
|
230 | + |
|
231 | + /** |
|
232 | + * Oxygen locate theme template. |
|
233 | + * |
|
234 | + * @param string $template The template. |
|
235 | + * @return string The theme template. |
|
236 | + */ |
|
237 | + public static function oxygen_locate_template( $template ) { |
|
238 | + |
|
239 | + if ( empty( $template ) ) { |
|
240 | + return ''; |
|
241 | + } |
|
242 | + |
|
243 | + $has_filter = has_filter( 'template', 'ct_oxygen_template_name' ); |
|
244 | + |
|
245 | + // Remove template filter |
|
246 | + if ( $has_filter ) { |
|
247 | + remove_filter( 'template', 'ct_oxygen_template_name' ); |
|
248 | + } |
|
249 | + |
|
250 | + $template = self::get_theme_template_path() . '/' . $template; |
|
251 | + |
|
252 | + if ( ! file_exists( $template ) ) { |
|
253 | + $template = ''; |
|
254 | + } |
|
255 | + |
|
256 | + // Add template filter |
|
257 | + if ( $has_filter ) { |
|
258 | + add_filter( 'template', 'ct_oxygen_template_name' ); |
|
259 | + } |
|
260 | + |
|
261 | + return $template; |
|
262 | + } |
|
263 | + |
|
264 | + /** |
|
265 | + * Oxygen override theme template. |
|
266 | + * |
|
267 | + * @param string $located Located template. |
|
268 | + * @param string $template_name Template name. |
|
269 | + * @return string Located template. |
|
270 | + */ |
|
271 | + public function oxygen_override_template( $located, $template_name ) { |
|
272 | 272 | |
273 | 273 | $oxygen_overide = self::oxygen_locate_template( $template_name ); |
274 | - if ( ! empty( $oxygen_overide ) ) { |
|
275 | - return $oxygen_overide; |
|
276 | - } |
|
274 | + if ( ! empty( $oxygen_overide ) ) { |
|
275 | + return $oxygen_overide; |
|
276 | + } |
|
277 | 277 | |
278 | - return $located; |
|
279 | - } |
|
278 | + return $located; |
|
279 | + } |
|
280 | 280 | |
281 | 281 | } |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -if ( ! defined( 'ABSPATH' ) ) { |
|
2 | +if (!defined('ABSPATH')) { |
|
3 | 3 | exit; |
4 | 4 | } |
5 | 5 | |
@@ -26,12 +26,12 @@ discard block |
||
26 | 26 | */ |
27 | 27 | public function __construct() { |
28 | 28 | |
29 | - $this->templates_dir = apply_filters( 'getpaid_default_templates_dir', WPINV_PLUGIN_DIR . 'templates' ); |
|
30 | - $this->templates_url = apply_filters( 'getpaid_default_templates_url', WPINV_PLUGIN_URL . 'templates' ); |
|
29 | + $this->templates_dir = apply_filters('getpaid_default_templates_dir', WPINV_PLUGIN_DIR . 'templates'); |
|
30 | + $this->templates_url = apply_filters('getpaid_default_templates_url', WPINV_PLUGIN_URL . 'templates'); |
|
31 | 31 | |
32 | 32 | // Oxygen plugin |
33 | - if ( defined( 'CT_VERSION' ) ) { |
|
34 | - add_filter( 'wpinv_locate_template', array( $this, 'oxygen_override_template' ), 11, 4 ); |
|
33 | + if (defined('CT_VERSION')) { |
|
34 | + add_filter('wpinv_locate_template', array($this, 'oxygen_override_template'), 11, 4); |
|
35 | 35 | } |
36 | 36 | |
37 | 37 | } |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | * @return bool |
61 | 61 | */ |
62 | 62 | public function is_elementor_preview() { |
63 | - return isset( $_REQUEST['elementor-preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor' ) || ( isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'elementor_ajax' ); |
|
63 | + return isset($_REQUEST['elementor-preview']) || (is_admin() && isset($_REQUEST['action']) && $_REQUEST['action'] == 'elementor') || (isset($_REQUEST['action']) && $_REQUEST['action'] == 'elementor_ajax'); |
|
64 | 64 | } |
65 | 65 | |
66 | 66 | /** |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | * @return bool |
71 | 71 | */ |
72 | 72 | public function is_divi_preview() { |
73 | - return isset( $_REQUEST['et_fb'] ) || isset( $_REQUEST['et_pb_preview'] ) || ( is_admin() && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'et_pb' ); |
|
73 | + return isset($_REQUEST['et_fb']) || isset($_REQUEST['et_pb_preview']) || (is_admin() && isset($_REQUEST['action']) && $_REQUEST['action'] == 'et_pb'); |
|
74 | 74 | } |
75 | 75 | |
76 | 76 | /** |
@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | * @return bool |
81 | 81 | */ |
82 | 82 | public function is_beaver_preview() { |
83 | - return isset( $_REQUEST['fl_builder'] ); |
|
83 | + return isset($_REQUEST['fl_builder']); |
|
84 | 84 | } |
85 | 85 | |
86 | 86 | /** |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | * @return bool |
91 | 91 | */ |
92 | 92 | public function is_siteorigin_preview() { |
93 | - return ! empty( $_REQUEST['siteorigin_panels_live_editor'] ); |
|
93 | + return !empty($_REQUEST['siteorigin_panels_live_editor']); |
|
94 | 94 | } |
95 | 95 | |
96 | 96 | /** |
@@ -100,7 +100,7 @@ discard block |
||
100 | 100 | * @return bool |
101 | 101 | */ |
102 | 102 | public function is_cornerstone_preview() { |
103 | - return ! empty( $_REQUEST['cornerstone_preview'] ) || basename( $_SERVER['REQUEST_URI'] ) == 'cornerstone-endpoint'; |
|
103 | + return !empty($_REQUEST['cornerstone_preview']) || basename($_SERVER['REQUEST_URI']) == 'cornerstone-endpoint'; |
|
104 | 104 | } |
105 | 105 | |
106 | 106 | /** |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | * @return bool |
111 | 111 | */ |
112 | 112 | public function is_fusion_preview() { |
113 | - return ! empty( $_REQUEST['fb-edit'] ) || ! empty( $_REQUEST['fusion_load_nonce'] ); |
|
113 | + return !empty($_REQUEST['fb-edit']) || !empty($_REQUEST['fusion_load_nonce']); |
|
114 | 114 | } |
115 | 115 | |
116 | 116 | /** |
@@ -120,7 +120,7 @@ discard block |
||
120 | 120 | * @return bool |
121 | 121 | */ |
122 | 122 | public function is_oxygen_preview() { |
123 | - return ! empty( $_REQUEST['ct_builder'] ) || ( ! empty( $_REQUEST['action'] ) && ( substr( $_REQUEST['action'], 0, 11 ) === "oxy_render_" || substr( $_REQUEST['action'], 0, 10 ) === "ct_render_" ) ); |
|
123 | + return !empty($_REQUEST['ct_builder']) || (!empty($_REQUEST['action']) && (substr($_REQUEST['action'], 0, 11) === "oxy_render_" || substr($_REQUEST['action'], 0, 10) === "ct_render_")); |
|
124 | 124 | } |
125 | 125 | |
126 | 126 | /** |
@@ -130,24 +130,24 @@ discard block |
||
130 | 130 | * @param string $template_path The template path relative to the theme's root dir. Defaults to 'invoicing'. |
131 | 131 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
132 | 132 | */ |
133 | - public function locate_template( $template_name, $template_path = '', $default_path = '' ) { |
|
133 | + public function locate_template($template_name, $template_path = '', $default_path = '') { |
|
134 | 134 | |
135 | 135 | // Load the defaults for the template path and default path. |
136 | - $template_path = empty( $template_path ) ? 'invoicing' : $template_path; |
|
137 | - $default_path = empty( $default_path ) ? $this->templates_dir : $default_path; |
|
138 | - $default_path = apply_filters( 'getpaid_template_default_template_path', $default_path, $template_name ); |
|
136 | + $template_path = empty($template_path) ? 'invoicing' : $template_path; |
|
137 | + $default_path = empty($default_path) ? $this->templates_dir : $default_path; |
|
138 | + $default_path = apply_filters('getpaid_template_default_template_path', $default_path, $template_name); |
|
139 | 139 | |
140 | 140 | // Is it overidden? |
141 | 141 | $template = locate_template( |
142 | - array( trailingslashit( $template_path ) . $template_name, 'wpinv-' . $template_name ) |
|
142 | + array(trailingslashit($template_path) . $template_name, 'wpinv-' . $template_name) |
|
143 | 143 | ); |
144 | 144 | |
145 | 145 | // If not, load the default template. |
146 | - if ( empty( $template ) ) { |
|
147 | - $template = trailingslashit( $default_path ) . $template_name; |
|
146 | + if (empty($template)) { |
|
147 | + $template = trailingslashit($default_path) . $template_name; |
|
148 | 148 | } |
149 | 149 | |
150 | - return apply_filters( 'wpinv_locate_template', $template, $template_name, $template_path, $default_path ); |
|
150 | + return apply_filters('wpinv_locate_template', $template, $template_name, $template_path, $default_path); |
|
151 | 151 | } |
152 | 152 | |
153 | 153 | /** |
@@ -156,20 +156,20 @@ discard block |
||
156 | 156 | * @since 1.0.19 |
157 | 157 | * @return bool |
158 | 158 | */ |
159 | - protected function load_template( $template_name, $template_path, $args ) { |
|
159 | + protected function load_template($template_name, $template_path, $args) { |
|
160 | 160 | |
161 | - if ( is_array( $args ) ){ |
|
162 | - extract( $args ); |
|
161 | + if (is_array($args)) { |
|
162 | + extract($args); |
|
163 | 163 | } |
164 | 164 | |
165 | 165 | // Fires before loading a template. |
166 | - do_action( 'wpinv_before_template_part', $template_name, $template_path, $args ); |
|
166 | + do_action('wpinv_before_template_part', $template_name, $template_path, $args); |
|
167 | 167 | |
168 | 168 | // Load the template. |
169 | - include( $template_path ); |
|
169 | + include($template_path); |
|
170 | 170 | |
171 | 171 | // Fires after loading a template. |
172 | - do_action( 'wpinv_after_template_part', $template_name, $template_path, $args ); |
|
172 | + do_action('wpinv_after_template_part', $template_name, $template_path, $args); |
|
173 | 173 | |
174 | 174 | } |
175 | 175 | |
@@ -183,18 +183,18 @@ discard block |
||
183 | 183 | * @param string $template_path The templates directory relative to the theme's root dir. Defaults to 'invoicing'. |
184 | 184 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
185 | 185 | */ |
186 | - public function display_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
186 | + public function display_template($template_name, $args = array(), $template_path = '', $default_path = '') { |
|
187 | 187 | |
188 | 188 | // Locate the template. |
189 | - $located = $this->locate_template( $template_name, $template_path, $default_path ); |
|
189 | + $located = $this->locate_template($template_name, $template_path, $default_path); |
|
190 | 190 | |
191 | 191 | // Abort if the file does not exist. |
192 | - if ( ! file_exists( $located ) ) { |
|
193 | - getpaid_doing_it_wrong( __METHOD__, sprintf( '<code>%s</code> does not exist.', $located ), '2.0.0' ); |
|
192 | + if (!file_exists($located)) { |
|
193 | + getpaid_doing_it_wrong(__METHOD__, sprintf('<code>%s</code> does not exist.', $located), '2.0.0'); |
|
194 | 194 | return; |
195 | 195 | } |
196 | 196 | |
197 | - $this->load_template( $template_name, $located, $args ); |
|
197 | + $this->load_template($template_name, $located, $args); |
|
198 | 198 | |
199 | 199 | } |
200 | 200 | |
@@ -208,9 +208,9 @@ discard block |
||
208 | 208 | * @param string $template_path The templates directory relative to the theme's root dir. Defaults to 'invoicing'. |
209 | 209 | * @param string $default_path The root path to the default template. Defaults to invoicing/templates |
210 | 210 | */ |
211 | - public function get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) { |
|
211 | + public function get_template($template_name, $args = array(), $template_path = '', $default_path = '') { |
|
212 | 212 | ob_start(); |
213 | - $this->display_template( $template_name, $args, $template_path, $default_path ); |
|
213 | + $this->display_template($template_name, $args, $template_path, $default_path); |
|
214 | 214 | return ob_get_clean(); |
215 | 215 | } |
216 | 216 | |
@@ -222,9 +222,9 @@ discard block |
||
222 | 222 | */ |
223 | 223 | public static function get_theme_template_path() { |
224 | 224 | $template = get_template(); |
225 | - $theme_root = get_theme_root( $template ); |
|
225 | + $theme_root = get_theme_root($template); |
|
226 | 226 | |
227 | - return $theme_root . '/' . $template . '/' . untrailingslashit( wpinv_get_theme_template_dir_name() ); |
|
227 | + return $theme_root . '/' . $template . '/' . untrailingslashit(wpinv_get_theme_template_dir_name()); |
|
228 | 228 | |
229 | 229 | } |
230 | 230 | |
@@ -234,28 +234,28 @@ discard block |
||
234 | 234 | * @param string $template The template. |
235 | 235 | * @return string The theme template. |
236 | 236 | */ |
237 | - public static function oxygen_locate_template( $template ) { |
|
237 | + public static function oxygen_locate_template($template) { |
|
238 | 238 | |
239 | - if ( empty( $template ) ) { |
|
239 | + if (empty($template)) { |
|
240 | 240 | return ''; |
241 | 241 | } |
242 | 242 | |
243 | - $has_filter = has_filter( 'template', 'ct_oxygen_template_name' ); |
|
243 | + $has_filter = has_filter('template', 'ct_oxygen_template_name'); |
|
244 | 244 | |
245 | 245 | // Remove template filter |
246 | - if ( $has_filter ) { |
|
247 | - remove_filter( 'template', 'ct_oxygen_template_name' ); |
|
246 | + if ($has_filter) { |
|
247 | + remove_filter('template', 'ct_oxygen_template_name'); |
|
248 | 248 | } |
249 | 249 | |
250 | 250 | $template = self::get_theme_template_path() . '/' . $template; |
251 | 251 | |
252 | - if ( ! file_exists( $template ) ) { |
|
252 | + if (!file_exists($template)) { |
|
253 | 253 | $template = ''; |
254 | 254 | } |
255 | 255 | |
256 | 256 | // Add template filter |
257 | - if ( $has_filter ) { |
|
258 | - add_filter( 'template', 'ct_oxygen_template_name' ); |
|
257 | + if ($has_filter) { |
|
258 | + add_filter('template', 'ct_oxygen_template_name'); |
|
259 | 259 | } |
260 | 260 | |
261 | 261 | return $template; |
@@ -268,10 +268,10 @@ discard block |
||
268 | 268 | * @param string $template_name Template name. |
269 | 269 | * @return string Located template. |
270 | 270 | */ |
271 | - public function oxygen_override_template( $located, $template_name ) { |
|
271 | + public function oxygen_override_template($located, $template_name) { |
|
272 | 272 | |
273 | - $oxygen_overide = self::oxygen_locate_template( $template_name ); |
|
274 | - if ( ! empty( $oxygen_overide ) ) { |
|
273 | + $oxygen_overide = self::oxygen_locate_template($template_name); |
|
274 | + if (!empty($oxygen_overide)) { |
|
275 | 275 | return $oxygen_overide; |
276 | 276 | } |
277 | 277 |
@@ -19,16 +19,16 @@ discard block |
||
19 | 19 | |
20 | 20 | // Define constants. |
21 | 21 | if ( ! defined( 'WPINV_PLUGIN_FILE' ) ) { |
22 | - define( 'WPINV_PLUGIN_FILE', __FILE__ ); |
|
22 | + define( 'WPINV_PLUGIN_FILE', __FILE__ ); |
|
23 | 23 | } |
24 | 24 | |
25 | 25 | if ( ! defined( 'WPINV_VERSION' ) ) { |
26 | - define( 'WPINV_VERSION', '2.1.10' ); |
|
26 | + define( 'WPINV_VERSION', '2.1.10' ); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | // Include the main Invoicing class. |
30 | 30 | if ( ! class_exists( 'WPInv_Plugin', false ) ) { |
31 | - require_once plugin_dir_path( WPINV_PLUGIN_FILE ) . 'includes/class-wpinv.php'; |
|
31 | + require_once plugin_dir_path( WPINV_PLUGIN_FILE ) . 'includes/class-wpinv.php'; |
|
32 | 32 | } |
33 | 33 | |
34 | 34 | /** |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | $GLOBALS['invoicing'] = new WPInv_Plugin(); |
44 | 44 | } |
45 | 45 | |
46 | - return $GLOBALS['invoicing']; |
|
46 | + return $GLOBALS['invoicing']; |
|
47 | 47 | } |
48 | 48 | |
49 | 49 | /** |
@@ -15,20 +15,20 @@ discard block |
||
15 | 15 | * @package GetPaid |
16 | 16 | */ |
17 | 17 | |
18 | -defined( 'ABSPATH' ) || exit; |
|
18 | +defined('ABSPATH') || exit; |
|
19 | 19 | |
20 | 20 | // Define constants. |
21 | -if ( ! defined( 'WPINV_PLUGIN_FILE' ) ) { |
|
22 | - define( 'WPINV_PLUGIN_FILE', __FILE__ ); |
|
21 | +if (!defined('WPINV_PLUGIN_FILE')) { |
|
22 | + define('WPINV_PLUGIN_FILE', __FILE__); |
|
23 | 23 | } |
24 | 24 | |
25 | -if ( ! defined( 'WPINV_VERSION' ) ) { |
|
26 | - define( 'WPINV_VERSION', '2.1.10' ); |
|
25 | +if (!defined('WPINV_VERSION')) { |
|
26 | + define('WPINV_VERSION', '2.1.10'); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | // Include the main Invoicing class. |
30 | -if ( ! class_exists( 'WPInv_Plugin', false ) ) { |
|
31 | - require_once plugin_dir_path( WPINV_PLUGIN_FILE ) . 'includes/class-wpinv.php'; |
|
30 | +if (!class_exists('WPInv_Plugin', false)) { |
|
31 | + require_once plugin_dir_path(WPINV_PLUGIN_FILE) . 'includes/class-wpinv.php'; |
|
32 | 32 | } |
33 | 33 | |
34 | 34 | /** |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | */ |
40 | 40 | function getpaid() { |
41 | 41 | |
42 | - if ( empty( $GLOBALS['invoicing'] ) ) { |
|
42 | + if (empty($GLOBALS['invoicing'])) { |
|
43 | 43 | $GLOBALS['invoicing'] = new WPInv_Plugin(); |
44 | 44 | } |
45 | 45 | |
@@ -52,9 +52,9 @@ discard block |
||
52 | 52 | * @since 2.0.8 |
53 | 53 | */ |
54 | 54 | function getpaid_deactivation_hook() { |
55 | - update_option( 'wpinv_flush_permalinks', 1 ); |
|
55 | + update_option('wpinv_flush_permalinks', 1); |
|
56 | 56 | } |
57 | -register_deactivation_hook( __FILE__, 'getpaid_deactivation_hook' ); |
|
57 | +register_deactivation_hook(__FILE__, 'getpaid_deactivation_hook'); |
|
58 | 58 | |
59 | 59 | /** |
60 | 60 | * @deprecated |
@@ -64,4 +64,4 @@ discard block |
||
64 | 64 | } |
65 | 65 | |
66 | 66 | // Kickstart the plugin. |
67 | -add_action( 'plugins_loaded', 'getpaid', -100 ); |
|
67 | +add_action('plugins_loaded', 'getpaid', -100); |
@@ -17,10 +17,10 @@ |
||
17 | 17 | $logo_height = wpinv_get_option( 'logo_height' ); |
18 | 18 | if ( ! empty( $logo_width ) && ! empty( $logo_height ) ) { |
19 | 19 | echo sprintf( |
20 | - '<img class="logo" style="width:%spx; height:%spx" src="%s"/>', |
|
21 | - esc_attr( $logo_width ), |
|
22 | - esc_attr( $logo_height ), |
|
23 | - esc_url( $logo ) |
|
20 | + '<img class="logo" style="width:%spx; height:%spx" src="%s"/>', |
|
21 | + esc_attr( $logo_width ), |
|
22 | + esc_attr( $logo_height ), |
|
23 | + esc_url( $logo ) |
|
24 | 24 | ); |
25 | 25 | } else { |
26 | 26 | ?> |
@@ -7,26 +7,26 @@ |
||
7 | 7 | * @version 1.0.19 |
8 | 8 | */ |
9 | 9 | |
10 | -defined( 'ABSPATH' ) || exit; |
|
10 | +defined('ABSPATH') || exit; |
|
11 | 11 | |
12 | 12 | ?> |
13 | -<a target="_blank" class="logo-link text-dark" href="<?php echo esc_url( wpinv_get_business_website() ); ?>"> |
|
13 | +<a target="_blank" class="logo-link text-dark" href="<?php echo esc_url(wpinv_get_business_website()); ?>"> |
|
14 | 14 | |
15 | - <?php if ( $logo = wpinv_get_business_logo() ) { |
|
16 | - $logo_width = wpinv_get_option( 'logo_width' ); |
|
17 | - $logo_height = wpinv_get_option( 'logo_height' ); |
|
18 | - if ( ! empty( $logo_width ) && ! empty( $logo_height ) ) { |
|
15 | + <?php if ($logo = wpinv_get_business_logo()) { |
|
16 | + $logo_width = wpinv_get_option('logo_width'); |
|
17 | + $logo_height = wpinv_get_option('logo_height'); |
|
18 | + if (!empty($logo_width) && !empty($logo_height)) { |
|
19 | 19 | echo sprintf( |
20 | 20 | '<img class="logo" style="width:%spx; height:%spx" src="%s"/>', |
21 | - esc_attr( $logo_width ), |
|
22 | - esc_attr( $logo_height ), |
|
23 | - esc_url( $logo ) |
|
21 | + esc_attr($logo_width), |
|
22 | + esc_attr($logo_height), |
|
23 | + esc_url($logo) |
|
24 | 24 | ); |
25 | 25 | } else { |
26 | 26 | ?> |
27 | - <img class="logo" style="max-width:100%;" src="<?php echo esc_url( $logo ); ?>"> |
|
27 | + <img class="logo" style="max-width:100%;" src="<?php echo esc_url($logo); ?>"> |
|
28 | 28 | <?php } } else { ?> |
29 | - <h1 class="h3"><?php echo esc_html( wpinv_get_business_name() ); ?></h1> |
|
29 | + <h1 class="h3"><?php echo esc_html(wpinv_get_business_name()); ?></h1> |
|
30 | 30 | <?php } ?> |
31 | 31 | |
32 | 32 | </a> |
@@ -8,203 +8,203 @@ discard block |
||
8 | 8 | * @version 1.0.19 |
9 | 9 | */ |
10 | 10 | |
11 | -defined( 'ABSPATH' ) || exit; |
|
11 | +defined('ABSPATH') || exit; |
|
12 | 12 | |
13 | -$pages = wpinv_get_pages( true ); |
|
13 | +$pages = wpinv_get_pages(true); |
|
14 | 14 | |
15 | 15 | $currencies = wpinv_get_currencies(); |
16 | 16 | |
17 | 17 | $currency_code_options = array(); |
18 | -foreach ( $currencies as $code => $name ) { |
|
19 | - $currency_code_options[ $code ] = $code . ' - ' . $name . ' (' . wpinv_currency_symbol( $code ) . ')'; |
|
18 | +foreach ($currencies as $code => $name) { |
|
19 | + $currency_code_options[$code] = $code . ' - ' . $name . ' (' . wpinv_currency_symbol($code) . ')'; |
|
20 | 20 | } |
21 | 21 | |
22 | 22 | $invoice_number_padd_options = array(); |
23 | -for ( $i = 0; $i <= 20; $i++ ) { |
|
23 | +for ($i = 0; $i <= 20; $i++) { |
|
24 | 24 | $invoice_number_padd_options[$i] = $i; |
25 | 25 | } |
26 | 26 | |
27 | 27 | $currency_symbol = wpinv_currency_symbol(); |
28 | 28 | |
29 | 29 | $last_number = $reset_number = ''; |
30 | -if ( $last_invoice_number = get_option( 'wpinv_last_invoice_number' ) ) { |
|
31 | - $last_invoice_number = preg_replace( '/[^0-9]/', '', $last_invoice_number ); |
|
30 | +if ($last_invoice_number = get_option('wpinv_last_invoice_number')) { |
|
31 | + $last_invoice_number = preg_replace('/[^0-9]/', '', $last_invoice_number); |
|
32 | 32 | |
33 | - if ( !empty( $last_invoice_number ) ) { |
|
34 | - $last_number = ' ' . wp_sprintf( __( "( Last Invoice's sequential number: <b>%s</b> )", 'invoicing' ), $last_invoice_number ); |
|
33 | + if (!empty($last_invoice_number)) { |
|
34 | + $last_number = ' ' . wp_sprintf(__("( Last Invoice's sequential number: <b>%s</b> )", 'invoicing'), $last_invoice_number); |
|
35 | 35 | } |
36 | 36 | |
37 | 37 | $nonce = wp_create_nonce('reset_invoice_count'); |
38 | - $reset_number = '<a href="'.add_query_arg(array('reset_invoice_count' => 1, '_nonce' => $nonce)).'" class="btn button">'.__('Force Reset Sequence', 'invoicing' ). '</a>'; |
|
38 | + $reset_number = '<a href="' . add_query_arg(array('reset_invoice_count' => 1, '_nonce' => $nonce)) . '" class="btn button">' . __('Force Reset Sequence', 'invoicing') . '</a>'; |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | $alert_wrapper_start = '<p style="color: #F00">'; |
42 | 42 | $alert_wrapper_close = '</p>'; |
43 | 43 | |
44 | 44 | return array( |
45 | - 'general' => apply_filters( 'wpinv_settings_general', |
|
45 | + 'general' => apply_filters('wpinv_settings_general', |
|
46 | 46 | array( |
47 | 47 | 'main' => array( |
48 | 48 | 'location_settings' => array( |
49 | 49 | 'id' => 'location_settings', |
50 | - 'name' => '<h3>' . __( 'Default Location', 'invoicing' ) . '</h3>', |
|
50 | + 'name' => '<h3>' . __('Default Location', 'invoicing') . '</h3>', |
|
51 | 51 | 'desc' => '', |
52 | 52 | 'type' => 'header', |
53 | 53 | ), |
54 | 54 | 'default_country' => array( |
55 | 55 | 'id' => 'default_country', |
56 | - 'name' => __( 'Default Country', 'invoicing' ), |
|
57 | - 'desc' => __( 'Where does your store operate from?', 'invoicing' ), |
|
56 | + 'name' => __('Default Country', 'invoicing'), |
|
57 | + 'desc' => __('Where does your store operate from?', 'invoicing'), |
|
58 | 58 | 'type' => 'select', |
59 | 59 | 'options' => wpinv_get_country_list(), |
60 | 60 | 'std' => 'GB', |
61 | 61 | 'class' => 'wpi_select2', |
62 | - 'placeholder' => __( 'Select a country', 'invoicing' ), |
|
62 | + 'placeholder' => __('Select a country', 'invoicing'), |
|
63 | 63 | ), |
64 | 64 | 'default_state' => array( |
65 | 65 | 'id' => 'default_state', |
66 | - 'name' => __( 'Default State / Province', 'invoicing' ), |
|
67 | - 'desc' => __( 'What state / province does your store operate from?', 'invoicing' ), |
|
66 | + 'name' => __('Default State / Province', 'invoicing'), |
|
67 | + 'desc' => __('What state / province does your store operate from?', 'invoicing'), |
|
68 | 68 | 'type' => 'country_states', |
69 | 69 | 'class' => 'wpi_select2', |
70 | - 'placeholder' => __( 'Select a state', 'invoicing' ), |
|
70 | + 'placeholder' => __('Select a state', 'invoicing'), |
|
71 | 71 | ), |
72 | 72 | 'store_name' => array( |
73 | 73 | 'id' => 'store_name', |
74 | - 'name' => __( 'Store Name', 'invoicing' ), |
|
75 | - 'desc' => __( 'Store name to print on invoices.', 'invoicing' ), |
|
74 | + 'name' => __('Store Name', 'invoicing'), |
|
75 | + 'desc' => __('Store name to print on invoices.', 'invoicing'), |
|
76 | 76 | 'std' => get_option('blogname'), |
77 | 77 | 'type' => 'text', |
78 | 78 | ), |
79 | 79 | 'logo' => array( |
80 | 80 | 'id' => 'logo', |
81 | - 'name' => __( 'Logo URL', 'invoicing' ), |
|
82 | - 'desc' => __( 'Store logo to print on invoices.', 'invoicing' ), |
|
81 | + 'name' => __('Logo URL', 'invoicing'), |
|
82 | + 'desc' => __('Store logo to print on invoices.', 'invoicing'), |
|
83 | 83 | 'type' => 'text', |
84 | 84 | ), |
85 | 85 | 'logo_width' => array( |
86 | 86 | 'id' => 'logo_width', |
87 | - 'name' => __( 'Logo width', 'invoicing' ), |
|
88 | - 'desc' => __( 'Logo width to use in invoice image.', 'invoicing' ), |
|
87 | + 'name' => __('Logo width', 'invoicing'), |
|
88 | + 'desc' => __('Logo width to use in invoice image.', 'invoicing'), |
|
89 | 89 | 'type' => 'number', |
90 | 90 | ), |
91 | 91 | 'logo_height' => array( |
92 | 92 | 'id' => 'logo_height', |
93 | - 'name' => __( 'Logo height', 'invoicing' ), |
|
94 | - 'desc' => __( 'Logo height to use in invoice image.', 'invoicing' ), |
|
93 | + 'name' => __('Logo height', 'invoicing'), |
|
94 | + 'desc' => __('Logo height to use in invoice image.', 'invoicing'), |
|
95 | 95 | 'type' => 'number', |
96 | 96 | ), |
97 | 97 | 'store_address' => array( |
98 | 98 | 'id' => 'store_address', |
99 | - 'name' => __( 'Store Address', 'invoicing' ), |
|
100 | - 'desc' => __( 'Enter the store address to display on invoice', 'invoicing' ), |
|
99 | + 'name' => __('Store Address', 'invoicing'), |
|
100 | + 'desc' => __('Enter the store address to display on invoice', 'invoicing'), |
|
101 | 101 | 'type' => 'textarea', |
102 | 102 | ), |
103 | 103 | 'page_settings' => array( |
104 | 104 | 'id' => 'page_settings', |
105 | - 'name' => '<h3>' . __( 'Page Settings', 'invoicing' ) . '</h3>', |
|
105 | + 'name' => '<h3>' . __('Page Settings', 'invoicing') . '</h3>', |
|
106 | 106 | 'desc' => '', |
107 | 107 | 'type' => 'header', |
108 | 108 | ), |
109 | 109 | 'checkout_page' => array( |
110 | 110 | 'id' => 'checkout_page', |
111 | - 'name' => __( 'Checkout Page', 'invoicing' ), |
|
112 | - 'desc' => __( 'This is the checkout page where buyers will complete their payments. The <b>[wpinv_checkout]</b> short code must be on this page.', 'invoicing' ), |
|
111 | + 'name' => __('Checkout Page', 'invoicing'), |
|
112 | + 'desc' => __('This is the checkout page where buyers will complete their payments. The <b>[wpinv_checkout]</b> short code must be on this page.', 'invoicing'), |
|
113 | 113 | 'type' => 'select', |
114 | 114 | 'options' => $pages, |
115 | 115 | 'class' => 'wpi_select2', |
116 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
116 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
117 | 117 | 'help-tip' => true, |
118 | 118 | ), |
119 | 119 | 'success_page' => array( |
120 | 120 | 'id' => 'success_page', |
121 | - 'name' => __( 'Success Page', 'invoicing' ), |
|
122 | - 'desc' => __( 'This is the page buyers are sent to after completing their payments. The <b>[wpinv_receipt]</b> short code should be on this page.', 'invoicing' ), |
|
121 | + 'name' => __('Success Page', 'invoicing'), |
|
122 | + 'desc' => __('This is the page buyers are sent to after completing their payments. The <b>[wpinv_receipt]</b> short code should be on this page.', 'invoicing'), |
|
123 | 123 | 'type' => 'select', |
124 | 124 | 'options' => $pages, |
125 | 125 | 'class' => 'wpi_select2', |
126 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
126 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
127 | 127 | 'help-tip' => true, |
128 | 128 | ), |
129 | 129 | 'failure_page' => array( |
130 | 130 | 'id' => 'failure_page', |
131 | - 'name' => __( 'Failed Transaction Page', 'invoicing' ), |
|
132 | - 'desc' => __( 'This is the page buyers are sent to if their transaction is cancelled or fails.', 'invoicing' ), |
|
131 | + 'name' => __('Failed Transaction Page', 'invoicing'), |
|
132 | + 'desc' => __('This is the page buyers are sent to if their transaction is cancelled or fails.', 'invoicing'), |
|
133 | 133 | 'type' => 'select', |
134 | 134 | 'options' => $pages, |
135 | 135 | 'class' => 'wpi_select2', |
136 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
136 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
137 | 137 | 'help-tip' => true, |
138 | 138 | ), |
139 | 139 | 'invoice_history_page' => array( |
140 | 140 | 'id' => 'invoice_history_page', |
141 | - 'name' => __( 'Invoice History Page', 'invoicing' ), |
|
142 | - 'desc' => __( 'This page shows an invoice history for the current user. The <b>[wpinv_history]</b> short code should be on this page.', 'invoicing' ), |
|
141 | + 'name' => __('Invoice History Page', 'invoicing'), |
|
142 | + 'desc' => __('This page shows an invoice history for the current user. The <b>[wpinv_history]</b> short code should be on this page.', 'invoicing'), |
|
143 | 143 | 'type' => 'select', |
144 | 144 | 'options' => $pages, |
145 | 145 | 'class' => 'wpi_select2', |
146 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
146 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
147 | 147 | 'help-tip' => true, |
148 | 148 | ), |
149 | 149 | 'invoice_subscription_page' => array( |
150 | 150 | 'id' => 'invoice_subscription_page', |
151 | - 'name' => __( 'Invoice Subscriptions Page', 'invoicing' ), |
|
152 | - 'desc' => __( 'This page shows subscriptions history for the current user. The <b>[wpinv_subscriptions]</b> short code should be on this page.', 'invoicing' ), |
|
151 | + 'name' => __('Invoice Subscriptions Page', 'invoicing'), |
|
152 | + 'desc' => __('This page shows subscriptions history for the current user. The <b>[wpinv_subscriptions]</b> short code should be on this page.', 'invoicing'), |
|
153 | 153 | 'type' => 'select', |
154 | 154 | 'options' => $pages, |
155 | 155 | 'class' => 'wpi_select2', |
156 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
156 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
157 | 157 | 'help-tip' => true, |
158 | 158 | ), |
159 | 159 | ), |
160 | 160 | 'currency_section' => array( |
161 | 161 | 'currency_settings' => array( |
162 | 162 | 'id' => 'currency_settings', |
163 | - 'name' => '<h3>' . __( 'Currency Settings', 'invoicing' ) . '</h3>', |
|
163 | + 'name' => '<h3>' . __('Currency Settings', 'invoicing') . '</h3>', |
|
164 | 164 | 'desc' => '', |
165 | 165 | 'type' => 'header', |
166 | 166 | ), |
167 | 167 | 'currency' => array( |
168 | 168 | 'id' => 'currency', |
169 | - 'name' => __( 'Currency', 'invoicing' ), |
|
170 | - 'desc' => __( 'Choose your currency. Note that some payment gateways have currency restrictions.', 'invoicing' ), |
|
169 | + 'name' => __('Currency', 'invoicing'), |
|
170 | + 'desc' => __('Choose your currency. Note that some payment gateways have currency restrictions.', 'invoicing'), |
|
171 | 171 | 'type' => 'select', |
172 | 172 | 'class' => 'wpi_select2', |
173 | 173 | 'options' => $currency_code_options, |
174 | 174 | ), |
175 | 175 | 'currency_position' => array( |
176 | 176 | 'id' => 'currency_position', |
177 | - 'name' => __( 'Currency Position', 'invoicing' ), |
|
178 | - 'desc' => __( 'Choose the location of the currency sign.', 'invoicing' ), |
|
177 | + 'name' => __('Currency Position', 'invoicing'), |
|
178 | + 'desc' => __('Choose the location of the currency sign.', 'invoicing'), |
|
179 | 179 | 'type' => 'select', |
180 | 180 | 'class' => 'wpi_select2', |
181 | 181 | 'options' => array( |
182 | - 'left' => __( 'Left', 'invoicing' ) . ' (' . $currency_symbol . wpinv_format_amount( '99.99' ) . ')', |
|
183 | - 'right' => __( 'Right', 'invoicing' ) . ' ('. wpinv_format_amount( '99.99' ) . $currency_symbol . ')', |
|
184 | - 'left_space' => __( 'Left with space', 'invoicing' ) . ' (' . $currency_symbol . ' ' . wpinv_format_amount( '99.99' ) . ')', |
|
185 | - 'right_space' => __( 'Right with space', 'invoicing' ) . ' (' . wpinv_format_amount( '99.99' ) . ' ' . $currency_symbol . ')' |
|
182 | + 'left' => __('Left', 'invoicing') . ' (' . $currency_symbol . wpinv_format_amount('99.99') . ')', |
|
183 | + 'right' => __('Right', 'invoicing') . ' (' . wpinv_format_amount('99.99') . $currency_symbol . ')', |
|
184 | + 'left_space' => __('Left with space', 'invoicing') . ' (' . $currency_symbol . ' ' . wpinv_format_amount('99.99') . ')', |
|
185 | + 'right_space' => __('Right with space', 'invoicing') . ' (' . wpinv_format_amount('99.99') . ' ' . $currency_symbol . ')' |
|
186 | 186 | ) |
187 | 187 | ), |
188 | 188 | 'thousands_separator' => array( |
189 | 189 | 'id' => 'thousands_separator', |
190 | - 'name' => __( 'Thousands Separator', 'invoicing' ), |
|
191 | - 'desc' => __( 'The symbol (usually , or .) to separate thousands', 'invoicing' ), |
|
190 | + 'name' => __('Thousands Separator', 'invoicing'), |
|
191 | + 'desc' => __('The symbol (usually , or .) to separate thousands', 'invoicing'), |
|
192 | 192 | 'type' => 'text', |
193 | 193 | 'size' => 'small', |
194 | 194 | 'std' => ',', |
195 | 195 | ), |
196 | 196 | 'decimal_separator' => array( |
197 | 197 | 'id' => 'decimal_separator', |
198 | - 'name' => __( 'Decimal Separator', 'invoicing' ), |
|
199 | - 'desc' => __( 'The symbol (usually , or .) to separate decimal points', 'invoicing' ), |
|
198 | + 'name' => __('Decimal Separator', 'invoicing'), |
|
199 | + 'desc' => __('The symbol (usually , or .) to separate decimal points', 'invoicing'), |
|
200 | 200 | 'type' => 'text', |
201 | 201 | 'size' => 'small', |
202 | 202 | 'std' => '.', |
203 | 203 | ), |
204 | 204 | 'decimals' => array( |
205 | 205 | 'id' => 'decimals', |
206 | - 'name' => __( 'Number of Decimals', 'invoicing' ), |
|
207 | - 'desc' => __( 'This sets the number of decimal points shown in displayed prices.', 'invoicing' ), |
|
206 | + 'name' => __('Number of Decimals', 'invoicing'), |
|
207 | + 'desc' => __('This sets the number of decimal points shown in displayed prices.', 'invoicing'), |
|
208 | 208 | 'type' => 'number', |
209 | 209 | 'size' => 'small', |
210 | 210 | 'std' => '2', |
@@ -216,21 +216,21 @@ discard block |
||
216 | 216 | 'labels' => array( |
217 | 217 | 'labels' => array( |
218 | 218 | 'id' => 'labels_settings', |
219 | - 'name' => '<h3>' . __( 'Invoice Labels', 'invoicing' ) . '</h3>', |
|
219 | + 'name' => '<h3>' . __('Invoice Labels', 'invoicing') . '</h3>', |
|
220 | 220 | 'desc' => '', |
221 | 221 | 'type' => 'header', |
222 | 222 | ), |
223 | 223 | 'vat_invoice_notice_label' => array( |
224 | 224 | 'id' => 'vat_invoice_notice_label', |
225 | - 'name' => __( 'Invoice Notice Label', 'invoicing' ), |
|
226 | - 'desc' => __( 'Use this to add an invoice notice section (label) to your invoices', 'invoicing' ), |
|
225 | + 'name' => __('Invoice Notice Label', 'invoicing'), |
|
226 | + 'desc' => __('Use this to add an invoice notice section (label) to your invoices', 'invoicing'), |
|
227 | 227 | 'type' => 'text', |
228 | 228 | 'size' => 'regular', |
229 | 229 | ), |
230 | 230 | 'vat_invoice_notice' => array( |
231 | 231 | 'id' => 'vat_invoice_notice', |
232 | - 'name' => __( 'Invoice notice', 'invoicing' ), |
|
233 | - 'desc' => __( 'Use this to add an invoice notice section (description) to your invoices', 'invoicing' ), |
|
232 | + 'name' => __('Invoice notice', 'invoicing'), |
|
233 | + 'desc' => __('Use this to add an invoice notice section (description) to your invoices', 'invoicing'), |
|
234 | 234 | 'type' => 'text', |
235 | 235 | 'size' => 'regular', |
236 | 236 | ), |
@@ -242,22 +242,22 @@ discard block |
||
242 | 242 | 'main' => array( |
243 | 243 | 'gateway_settings' => array( |
244 | 244 | 'id' => 'api_header', |
245 | - 'name' => '<h3>' . __( 'Gateway Settings', 'invoicing' ) . '</h3>', |
|
245 | + 'name' => '<h3>' . __('Gateway Settings', 'invoicing') . '</h3>', |
|
246 | 246 | 'desc' => '', |
247 | 247 | 'type' => 'header', |
248 | 248 | ), |
249 | 249 | 'gateways' => array( |
250 | 250 | 'id' => 'gateways', |
251 | - 'name' => __( 'Payment Gateways', 'invoicing' ), |
|
252 | - 'desc' => __( 'Choose the payment gateways you want to enable.', 'invoicing' ), |
|
251 | + 'name' => __('Payment Gateways', 'invoicing'), |
|
252 | + 'desc' => __('Choose the payment gateways you want to enable.', 'invoicing'), |
|
253 | 253 | 'type' => 'gateways', |
254 | - 'std' => array( 'manual'=>1 ), |
|
254 | + 'std' => array('manual'=>1), |
|
255 | 255 | 'options' => wpinv_get_payment_gateways(), |
256 | 256 | ), |
257 | 257 | 'default_gateway' => array( |
258 | 258 | 'id' => 'default_gateway', |
259 | - 'name' => __( 'Default Gateway', 'invoicing' ), |
|
260 | - 'desc' => __( 'This gateway will be loaded automatically with the checkout page.', 'invoicing' ), |
|
259 | + 'name' => __('Default Gateway', 'invoicing'), |
|
260 | + 'desc' => __('This gateway will be loaded automatically with the checkout page.', 'invoicing'), |
|
261 | 261 | 'type' => 'gateway_select', |
262 | 262 | 'std' => 'manual', |
263 | 263 | 'class' => 'wpi_select2', |
@@ -272,32 +272,32 @@ discard block |
||
272 | 272 | 'main' => array( |
273 | 273 | 'tax_settings' => array( |
274 | 274 | 'id' => 'tax_settings', |
275 | - 'name' => '<h3>' . __( 'Tax Settings', 'invoicing' ) . '</h3>', |
|
275 | + 'name' => '<h3>' . __('Tax Settings', 'invoicing') . '</h3>', |
|
276 | 276 | 'type' => 'header', |
277 | 277 | ), |
278 | 278 | |
279 | 279 | 'enable_taxes' => array( |
280 | 280 | 'id' => 'enable_taxes', |
281 | - 'name' => __( 'Enable Taxes', 'invoicing' ), |
|
282 | - 'desc' => __( 'Enable tax rates and calculations.', 'invoicing' ), |
|
281 | + 'name' => __('Enable Taxes', 'invoicing'), |
|
282 | + 'desc' => __('Enable tax rates and calculations.', 'invoicing'), |
|
283 | 283 | 'type' => 'checkbox', |
284 | 284 | 'std' => 0, |
285 | 285 | ), |
286 | 286 | |
287 | 287 | 'tax_subtotal_rounding' => array( |
288 | 288 | 'id' => 'tax_subtotal_rounding', |
289 | - 'name' => __( 'Rounding', 'invoicing' ), |
|
290 | - 'desc' => __( 'Round tax at subtotal level, instead of rounding per tax rate', 'invoicing' ), |
|
289 | + 'name' => __('Rounding', 'invoicing'), |
|
290 | + 'desc' => __('Round tax at subtotal level, instead of rounding per tax rate', 'invoicing'), |
|
291 | 291 | 'type' => 'checkbox', |
292 | 292 | 'std' => 1, |
293 | 293 | ), |
294 | 294 | |
295 | 295 | 'prices_include_tax' => array( |
296 | 296 | 'id' => 'prices_include_tax', |
297 | - 'name' => __( 'Prices entered with tax', 'invoicing' ), |
|
297 | + 'name' => __('Prices entered with tax', 'invoicing'), |
|
298 | 298 | 'options' => array( |
299 | - 'yes' => __( 'Yes, I will enter prices inclusive of tax', 'invoicing' ), |
|
300 | - 'no' => __( 'No, I will enter prices exclusive of tax', 'invoicing' ), |
|
299 | + 'yes' => __('Yes, I will enter prices inclusive of tax', 'invoicing'), |
|
300 | + 'no' => __('No, I will enter prices exclusive of tax', 'invoicing'), |
|
301 | 301 | ), |
302 | 302 | 'type' => 'select', |
303 | 303 | 'std' => 'no', |
@@ -305,10 +305,10 @@ discard block |
||
305 | 305 | |
306 | 306 | 'tax_base' => array( |
307 | 307 | 'id' => 'tax_base', |
308 | - 'name' => __( 'Calculate tax based on', 'invoicing' ), |
|
308 | + 'name' => __('Calculate tax based on', 'invoicing'), |
|
309 | 309 | 'options' => array( |
310 | - 'billing' => __( 'Customer billing address', 'invoicing' ), |
|
311 | - 'base' => __( 'Shop base address', 'invoicing' ), |
|
310 | + 'billing' => __('Customer billing address', 'invoicing'), |
|
311 | + 'base' => __('Shop base address', 'invoicing'), |
|
312 | 312 | ), |
313 | 313 | 'type' => 'select', |
314 | 314 | 'std' => 'billing', |
@@ -316,10 +316,10 @@ discard block |
||
316 | 316 | |
317 | 317 | 'tax_display_totals' => array( |
318 | 318 | 'id' => 'tax_display_totals', |
319 | - 'name' => __( 'Display tax totals', 'invoicing' ), |
|
319 | + 'name' => __('Display tax totals', 'invoicing'), |
|
320 | 320 | 'options' => array( |
321 | - 'single' => __( 'As a single total', 'invoicing' ), |
|
322 | - 'individual' => __( 'As individual tax rates', 'invoicing' ), |
|
321 | + 'single' => __('As a single total', 'invoicing'), |
|
322 | + 'individual' => __('As individual tax rates', 'invoicing'), |
|
323 | 323 | ), |
324 | 324 | 'type' => 'select', |
325 | 325 | 'std' => 'individual', |
@@ -327,8 +327,8 @@ discard block |
||
327 | 327 | |
328 | 328 | 'tax_rate' => array( |
329 | 329 | 'id' => 'tax_rate', |
330 | - 'name' => __( 'Fallback Tax Rate', 'invoicing' ), |
|
331 | - 'desc' => __( 'Enter a percentage, such as 6.5. Customers not in a specific rate will be charged this rate.', 'invoicing' ), |
|
330 | + 'name' => __('Fallback Tax Rate', 'invoicing'), |
|
331 | + 'desc' => __('Enter a percentage, such as 6.5. Customers not in a specific rate will be charged this rate.', 'invoicing'), |
|
332 | 332 | 'type' => 'number', |
333 | 333 | 'size' => 'small', |
334 | 334 | 'min' => '0', |
@@ -340,8 +340,8 @@ discard block |
||
340 | 340 | 'rates' => array( |
341 | 341 | 'tax_rates' => array( |
342 | 342 | 'id' => 'tax_rates', |
343 | - 'name' => '<h3>' . __( 'Tax Rates', 'invoicing' ) . '</h3>', |
|
344 | - 'desc' => __( 'Enter tax rates for specific regions.', 'invoicing' ), |
|
343 | + 'name' => '<h3>' . __('Tax Rates', 'invoicing') . '</h3>', |
|
344 | + 'desc' => __('Enter tax rates for specific regions.', 'invoicing'), |
|
345 | 345 | 'type' => 'tax_rates', |
346 | 346 | ), |
347 | 347 | ), |
@@ -350,45 +350,45 @@ discard block |
||
350 | 350 | |
351 | 351 | 'vat_company_name' => array( |
352 | 352 | 'id' => 'vat_company_name', |
353 | - 'name' => __( 'Company Name', 'invoicing' ), |
|
354 | - 'desc' => wp_sprintf(__( 'Verify your company name and VAT number on the %sEU VIES System.%s', 'invoicing' ), '<a href="http://ec.europa.eu/taxation_customs/vies/" target="_blank">', '</a>' ), |
|
353 | + 'name' => __('Company Name', 'invoicing'), |
|
354 | + 'desc' => wp_sprintf(__('Verify your company name and VAT number on the %sEU VIES System.%s', 'invoicing'), '<a href="http://ec.europa.eu/taxation_customs/vies/" target="_blank">', '</a>'), |
|
355 | 355 | 'type' => 'text', |
356 | 356 | 'size' => 'regular', |
357 | 357 | ), |
358 | 358 | |
359 | 359 | 'vat_number' => array( |
360 | 360 | 'id' => 'vat_number', |
361 | - 'name' => __( 'VAT Number', 'invoicing' ), |
|
362 | - 'desc' => __( 'Enter your VAT number including the country identifier, eg: GB123456789', 'invoicing' ), |
|
361 | + 'name' => __('VAT Number', 'invoicing'), |
|
362 | + 'desc' => __('Enter your VAT number including the country identifier, eg: GB123456789', 'invoicing'), |
|
363 | 363 | 'type' => 'text', |
364 | 364 | 'size' => 'regular', |
365 | 365 | ), |
366 | 366 | |
367 | 367 | 'vat_prevent_b2c_purchase' => array( |
368 | 368 | 'id' => 'vat_prevent_b2c_purchase', |
369 | - 'name' => __( 'Prevent B2C Sales', 'invoicing' ), |
|
370 | - 'desc' => __( 'Require everyone in the EU to provide a VAT number.', 'invoicing' ), |
|
369 | + 'name' => __('Prevent B2C Sales', 'invoicing'), |
|
370 | + 'desc' => __('Require everyone in the EU to provide a VAT number.', 'invoicing'), |
|
371 | 371 | 'type' => 'checkbox' |
372 | 372 | ), |
373 | 373 | |
374 | 374 | 'validate_vat_number' => array( |
375 | 375 | 'id' => 'validate_vat_number', |
376 | - 'name' => __( 'Validate VAT Number', 'invoicing' ), |
|
377 | - 'desc' => __( 'Validate VAT numbers with VIES.', 'invoicing' ), |
|
376 | + 'name' => __('Validate VAT Number', 'invoicing'), |
|
377 | + 'desc' => __('Validate VAT numbers with VIES.', 'invoicing'), |
|
378 | 378 | 'type' => 'checkbox' |
379 | 379 | ), |
380 | 380 | |
381 | 381 | 'vat_same_country_rule' => array( |
382 | 382 | 'id' => 'vat_same_country_rule', |
383 | - 'name' => __( 'Same Country Rule', 'invoicing' ), |
|
384 | - 'desc' => __( 'What should happen if a customer is from the same country as your business?', 'invoicing' ), |
|
383 | + 'name' => __('Same Country Rule', 'invoicing'), |
|
384 | + 'desc' => __('What should happen if a customer is from the same country as your business?', 'invoicing'), |
|
385 | 385 | 'type' => 'select', |
386 | 386 | 'options' => array( |
387 | - 'no' => __( 'Do not charge tax', 'invoicing' ), |
|
388 | - 'always' => __( 'Charge tax unless vat number is validated', 'invoicing' ), |
|
389 | - 'vat_too' => __( 'Charge tax even if vat number is validated', 'invoicing' ) |
|
387 | + 'no' => __('Do not charge tax', 'invoicing'), |
|
388 | + 'always' => __('Charge tax unless vat number is validated', 'invoicing'), |
|
389 | + 'vat_too' => __('Charge tax even if vat number is validated', 'invoicing') |
|
390 | 390 | ), |
391 | - 'placeholder' => __( 'Select an option', 'invoicing' ), |
|
391 | + 'placeholder' => __('Select an option', 'invoicing'), |
|
392 | 392 | 'std' => 'vat_too', |
393 | 393 | ), |
394 | 394 | |
@@ -402,59 +402,59 @@ discard block |
||
402 | 402 | 'main' => array( |
403 | 403 | 'email_settings_header' => array( |
404 | 404 | 'id' => 'email_settings_header', |
405 | - 'name' => '<h3>' . __( 'Email Sender Options', 'invoicing' ) . '</h3>', |
|
405 | + 'name' => '<h3>' . __('Email Sender Options', 'invoicing') . '</h3>', |
|
406 | 406 | 'type' => 'header', |
407 | 407 | ), |
408 | 408 | 'email_from_name' => array( |
409 | 409 | 'id' => 'email_from_name', |
410 | - 'name' => __( 'From Name', 'invoicing' ), |
|
411 | - 'desc' => __( 'Enter the sender\'s name appears in outgoing invoice emails. This should be your site name.', 'invoicing' ), |
|
412 | - 'std' => esc_attr( get_bloginfo( 'name', 'display' ) ), |
|
410 | + 'name' => __('From Name', 'invoicing'), |
|
411 | + 'desc' => __('Enter the sender\'s name appears in outgoing invoice emails. This should be your site name.', 'invoicing'), |
|
412 | + 'std' => esc_attr(get_bloginfo('name', 'display')), |
|
413 | 413 | 'type' => 'text', |
414 | 414 | ), |
415 | 415 | 'email_from' => array( |
416 | 416 | 'id' => 'email_from', |
417 | - 'name' => __( 'From Email', 'invoicing' ), |
|
418 | - 'desc' => sprintf (__( 'Email address to send invoice emails from. This will act as the "from" and "reply-to" address. %s If emails are not being sent it may be that your hosting prevents emails being sent if the email domains do not match.%s', 'invoicing' ), $alert_wrapper_start, $alert_wrapper_close), |
|
419 | - 'std' => get_option( 'admin_email' ), |
|
417 | + 'name' => __('From Email', 'invoicing'), |
|
418 | + 'desc' => sprintf(__('Email address to send invoice emails from. This will act as the "from" and "reply-to" address. %s If emails are not being sent it may be that your hosting prevents emails being sent if the email domains do not match.%s', 'invoicing'), $alert_wrapper_start, $alert_wrapper_close), |
|
419 | + 'std' => get_option('admin_email'), |
|
420 | 420 | 'type' => 'text', |
421 | 421 | ), |
422 | 422 | 'admin_email' => array( |
423 | 423 | 'id' => 'admin_email', |
424 | - 'name' => __( 'Admin Email', 'invoicing' ), |
|
425 | - 'desc' => __( 'Where should we send admin notifications?', 'invoicing' ), |
|
426 | - 'std' => get_option( 'admin_email' ), |
|
424 | + 'name' => __('Admin Email', 'invoicing'), |
|
425 | + 'desc' => __('Where should we send admin notifications?', 'invoicing'), |
|
426 | + 'std' => get_option('admin_email'), |
|
427 | 427 | 'type' => 'text', |
428 | 428 | ), |
429 | 429 | 'overdue_settings_header' => array( |
430 | 430 | 'id' => 'overdue_settings_header', |
431 | - 'name' => '<h3>' . __( 'Due Date Settings', 'invoicing' ) . '</h3>', |
|
431 | + 'name' => '<h3>' . __('Due Date Settings', 'invoicing') . '</h3>', |
|
432 | 432 | 'type' => 'header', |
433 | 433 | ), |
434 | 434 | 'overdue_active' => array( |
435 | 435 | 'id' => 'overdue_active', |
436 | - 'name' => __( 'Enable Due Date', 'invoicing' ), |
|
437 | - 'desc' => __( 'Check this to enable due date option for invoices.', 'invoicing' ), |
|
436 | + 'name' => __('Enable Due Date', 'invoicing'), |
|
437 | + 'desc' => __('Check this to enable due date option for invoices.', 'invoicing'), |
|
438 | 438 | 'type' => 'checkbox', |
439 | 439 | 'std' => false, |
440 | 440 | ), |
441 | 441 | 'email_template_header' => array( |
442 | 442 | 'id' => 'email_template_header', |
443 | - 'name' => '<h3>' . __( 'Email Template', 'invoicing' ) . '</h3>', |
|
443 | + 'name' => '<h3>' . __('Email Template', 'invoicing') . '</h3>', |
|
444 | 444 | 'type' => 'header', |
445 | 445 | ), |
446 | 446 | 'email_header_image' => array( |
447 | 447 | 'id' => 'email_header_image', |
448 | - 'name' => __( 'Header Image', 'invoicing' ), |
|
449 | - 'desc' => __( 'URL to an image you want to show in the email header. Upload images using the media uploader (Admin > Media).', 'invoicing' ), |
|
448 | + 'name' => __('Header Image', 'invoicing'), |
|
449 | + 'desc' => __('URL to an image you want to show in the email header. Upload images using the media uploader (Admin > Media).', 'invoicing'), |
|
450 | 450 | 'std' => '', |
451 | 451 | 'type' => 'text', |
452 | 452 | ), |
453 | 453 | 'email_footer_text' => array( |
454 | 454 | 'id' => 'email_footer_text', |
455 | - 'name' => __( 'Footer Text', 'invoicing' ), |
|
456 | - 'desc' => __( 'The text to appear in the footer of all invoice emails.', 'invoicing' ), |
|
457 | - 'std' => get_bloginfo( 'name', 'display' ) . ' - ' . __( 'Powered by GetPaid', 'invoicing' ), |
|
455 | + 'name' => __('Footer Text', 'invoicing'), |
|
456 | + 'desc' => __('The text to appear in the footer of all invoice emails.', 'invoicing'), |
|
457 | + 'std' => get_bloginfo('name', 'display') . ' - ' . __('Powered by GetPaid', 'invoicing'), |
|
458 | 458 | 'type' => 'textarea', |
459 | 459 | 'class' => 'regular-text', |
460 | 460 | 'rows' => 2, |
@@ -462,29 +462,29 @@ discard block |
||
462 | 462 | ), |
463 | 463 | 'email_base_color' => array( |
464 | 464 | 'id' => 'email_base_color', |
465 | - 'name' => __( 'Base Color', 'invoicing' ), |
|
466 | - 'desc' => __( 'The base color for invoice email template. Default <code>#557da2</code>.', 'invoicing' ), |
|
465 | + 'name' => __('Base Color', 'invoicing'), |
|
466 | + 'desc' => __('The base color for invoice email template. Default <code>#557da2</code>.', 'invoicing'), |
|
467 | 467 | 'std' => '#557da2', |
468 | 468 | 'type' => 'color', |
469 | 469 | ), |
470 | 470 | 'email_background_color' => array( |
471 | 471 | 'id' => 'email_background_color', |
472 | - 'name' => __( 'Background Color', 'invoicing' ), |
|
473 | - 'desc' => __( 'The background color of email template. Default <code>#f5f5f5</code>.', 'invoicing' ), |
|
472 | + 'name' => __('Background Color', 'invoicing'), |
|
473 | + 'desc' => __('The background color of email template. Default <code>#f5f5f5</code>.', 'invoicing'), |
|
474 | 474 | 'std' => '#f5f5f5', |
475 | 475 | 'type' => 'color', |
476 | 476 | ), |
477 | 477 | 'email_body_background_color' => array( |
478 | 478 | 'id' => 'email_body_background_color', |
479 | - 'name' => __( 'Body Background Color', 'invoicing' ), |
|
480 | - 'desc' => __( 'The main body background color of email template. Default <code>#fdfdfd</code>.', 'invoicing' ), |
|
479 | + 'name' => __('Body Background Color', 'invoicing'), |
|
480 | + 'desc' => __('The main body background color of email template. Default <code>#fdfdfd</code>.', 'invoicing'), |
|
481 | 481 | 'std' => '#fdfdfd', |
482 | 482 | 'type' => 'color', |
483 | 483 | ), |
484 | 484 | 'email_text_color' => array( |
485 | 485 | 'id' => 'email_text_color', |
486 | - 'name' => __( 'Body Text Color', 'invoicing' ), |
|
487 | - 'desc' => __( 'The main body text color. Default <code>#505050</code>.', 'invoicing' ), |
|
486 | + 'name' => __('Body Text Color', 'invoicing'), |
|
487 | + 'desc' => __('The main body text color. Default <code>#505050</code>.', 'invoicing'), |
|
488 | 488 | 'std' => '#505050', |
489 | 489 | 'type' => 'color', |
490 | 490 | ), |
@@ -499,7 +499,7 @@ discard block |
||
499 | 499 | ), |
500 | 500 | |
501 | 501 | // Integrations. |
502 | - 'integrations' => wp_list_pluck( getpaid_get_integration_settings(), 'settings', 'id' ), |
|
502 | + 'integrations' => wp_list_pluck(getpaid_get_integration_settings(), 'settings', 'id'), |
|
503 | 503 | |
504 | 504 | /** Privacy Settings */ |
505 | 505 | 'privacy' => apply_filters('wpinv_settings_privacy', |
@@ -507,17 +507,17 @@ discard block |
||
507 | 507 | 'main' => array( |
508 | 508 | 'invoicing_privacy_policy_settings' => array( |
509 | 509 | 'id' => 'invoicing_privacy_policy_settings', |
510 | - 'name' => '<h3>' . __( 'Privacy Policy', 'invoicing' ) . '</h3>', |
|
510 | + 'name' => '<h3>' . __('Privacy Policy', 'invoicing') . '</h3>', |
|
511 | 511 | 'type' => 'header', |
512 | 512 | ), |
513 | 513 | 'privacy_page' => array( |
514 | 514 | 'id' => 'privacy_page', |
515 | - 'name' => __( 'Privacy Page', 'invoicing' ), |
|
516 | - 'desc' => __( 'If no privacy policy page set in Settings->Privacy default settings, this page will be used on checkout page.', 'invoicing' ), |
|
515 | + 'name' => __('Privacy Page', 'invoicing'), |
|
516 | + 'desc' => __('If no privacy policy page set in Settings->Privacy default settings, this page will be used on checkout page.', 'invoicing'), |
|
517 | 517 | 'type' => 'select', |
518 | - 'options' => wpinv_get_pages( true, __( 'Select a page', 'invoicing' )), |
|
518 | + 'options' => wpinv_get_pages(true, __('Select a page', 'invoicing')), |
|
519 | 519 | 'class' => 'wpi_select2', |
520 | - 'placeholder' => __( 'Select a page', 'invoicing' ), |
|
520 | + 'placeholder' => __('Select a page', 'invoicing'), |
|
521 | 521 | ), |
522 | 522 | ), |
523 | 523 | ) |
@@ -528,19 +528,19 @@ discard block |
||
528 | 528 | 'main' => array( |
529 | 529 | 'invoice_number_format_settings' => array( |
530 | 530 | 'id' => 'invoice_number_format_settings', |
531 | - 'name' => '<h3>' . __( 'Invoice Number', 'invoicing' ) . '</h3>', |
|
531 | + 'name' => '<h3>' . __('Invoice Number', 'invoicing') . '</h3>', |
|
532 | 532 | 'type' => 'header', |
533 | 533 | ), |
534 | 534 | 'sequential_invoice_number' => array( |
535 | 535 | 'id' => 'sequential_invoice_number', |
536 | - 'name' => __( 'Sequential Invoice Numbers', 'invoicing' ), |
|
537 | - 'desc' => __('Check this box to enable sequential invoice numbers.', 'invoicing' ) . $reset_number, |
|
536 | + 'name' => __('Sequential Invoice Numbers', 'invoicing'), |
|
537 | + 'desc' => __('Check this box to enable sequential invoice numbers.', 'invoicing') . $reset_number, |
|
538 | 538 | 'type' => 'checkbox', |
539 | 539 | ), |
540 | 540 | 'invoice_sequence_start' => array( |
541 | 541 | 'id' => 'invoice_sequence_start', |
542 | - 'name' => __( 'Sequential Starting Number', 'invoicing' ), |
|
543 | - 'desc' => __( 'The number at which the invoice number sequence should begin.', 'invoicing' ) . $last_number, |
|
542 | + 'name' => __('Sequential Starting Number', 'invoicing'), |
|
543 | + 'desc' => __('The number at which the invoice number sequence should begin.', 'invoicing') . $last_number, |
|
544 | 544 | 'type' => 'number', |
545 | 545 | 'size' => 'small', |
546 | 546 | 'std' => '1', |
@@ -548,8 +548,8 @@ discard block |
||
548 | 548 | ), |
549 | 549 | 'invoice_number_padd' => array( |
550 | 550 | 'id' => 'invoice_number_padd', |
551 | - 'name' => __( 'Minimum Digits', 'invoicing' ), |
|
552 | - 'desc' => __( 'If the invoice number has less digits than this number, it is left padded with 0s. Ex: invoice number 108 will padded to 00108 if digits set to 5. The default 0 means no padding.', 'invoicing' ), |
|
551 | + 'name' => __('Minimum Digits', 'invoicing'), |
|
552 | + 'desc' => __('If the invoice number has less digits than this number, it is left padded with 0s. Ex: invoice number 108 will padded to 00108 if digits set to 5. The default 0 means no padding.', 'invoicing'), |
|
553 | 553 | 'type' => 'select', |
554 | 554 | 'options' => $invoice_number_padd_options, |
555 | 555 | 'std' => 5, |
@@ -557,8 +557,8 @@ discard block |
||
557 | 557 | ), |
558 | 558 | 'invoice_number_prefix' => array( |
559 | 559 | 'id' => 'invoice_number_prefix', |
560 | - 'name' => __( 'Invoice Number Prefix', 'invoicing' ), |
|
561 | - 'desc' => __( 'Prefix for all invoice numbers. Ex: INV-', 'invoicing' ), |
|
560 | + 'name' => __('Invoice Number Prefix', 'invoicing'), |
|
561 | + 'desc' => __('Prefix for all invoice numbers. Ex: INV-', 'invoicing'), |
|
562 | 562 | 'type' => 'text', |
563 | 563 | 'size' => 'regular', |
564 | 564 | 'std' => 'INV-', |
@@ -566,41 +566,41 @@ discard block |
||
566 | 566 | ), |
567 | 567 | 'invoice_number_postfix' => array( |
568 | 568 | 'id' => 'invoice_number_postfix', |
569 | - 'name' => __( 'Invoice Number Postfix', 'invoicing' ), |
|
570 | - 'desc' => __( 'Postfix for all invoice numbers.', 'invoicing' ), |
|
569 | + 'name' => __('Invoice Number Postfix', 'invoicing'), |
|
570 | + 'desc' => __('Postfix for all invoice numbers.', 'invoicing'), |
|
571 | 571 | 'type' => 'text', |
572 | 572 | 'size' => 'regular', |
573 | 573 | 'std' => '' |
574 | 574 | ), |
575 | 575 | 'checkout_settings' => array( |
576 | 576 | 'id' => 'checkout_settings', |
577 | - 'name' => '<h3>' . __( 'Checkout Settings', 'invoicing' ) . '</h3>', |
|
577 | + 'name' => '<h3>' . __('Checkout Settings', 'invoicing') . '</h3>', |
|
578 | 578 | 'type' => 'header', |
579 | 579 | ), |
580 | 580 | 'login_to_checkout' => array( |
581 | 581 | 'id' => 'login_to_checkout', |
582 | - 'name' => __( 'Require Login To Checkout', 'invoicing' ), |
|
583 | - 'desc' => __( 'If ticked then user needs to be logged in to view or pay invoice, can only view or pay their own invoice. If unticked then anyone can view or pay the invoice.', 'invoicing' ), |
|
582 | + 'name' => __('Require Login To Checkout', 'invoicing'), |
|
583 | + 'desc' => __('If ticked then user needs to be logged in to view or pay invoice, can only view or pay their own invoice. If unticked then anyone can view or pay the invoice.', 'invoicing'), |
|
584 | 584 | 'type' => 'checkbox', |
585 | 585 | ), |
586 | 586 | |
587 | 587 | 'maxmind_license_key' => array( |
588 | 588 | 'id' => 'maxmind_license_key', |
589 | - 'name' => __( 'MaxMind License Key', 'invoicing' ), |
|
589 | + 'name' => __('MaxMind License Key', 'invoicing'), |
|
590 | 590 | 'type' => 'text', |
591 | 591 | 'size' => 'regular', |
592 | - 'desc' => __( "Enter you license key if you would like to use MaxMind to automatically detect a customer's country.", 'invoicing' ) . ' <a href="https://support.maxmind.com/account-faq/license-keys/how-do-i-generate-a-license-key/">' . __( 'How to generate a free license key.', 'invoicing' ) . '</a>', |
|
592 | + 'desc' => __("Enter you license key if you would like to use MaxMind to automatically detect a customer's country.", 'invoicing') . ' <a href="https://support.maxmind.com/account-faq/license-keys/how-do-i-generate-a-license-key/">' . __('How to generate a free license key.', 'invoicing') . '</a>', |
|
593 | 593 | ), |
594 | 594 | |
595 | 595 | 'uninstall_settings' => array( |
596 | 596 | 'id' => 'uninstall_settings', |
597 | - 'name' => '<h3>' . __( 'Uninstall Settings', 'invoicing' ) . '</h3>', |
|
597 | + 'name' => '<h3>' . __('Uninstall Settings', 'invoicing') . '</h3>', |
|
598 | 598 | 'type' => 'header', |
599 | 599 | ), |
600 | 600 | 'remove_data_on_unistall' => array( |
601 | 601 | 'id' => 'remove_data_on_unistall', |
602 | - 'name' => __( 'Remove Data on Uninstall?', 'invoicing' ), |
|
603 | - 'desc' => __( 'Check this box if you would like Invoicing plugin to completely remove all of its data when the plugin is deleted/uninstalled.', 'invoicing' ), |
|
602 | + 'name' => __('Remove Data on Uninstall?', 'invoicing'), |
|
603 | + 'desc' => __('Check this box if you would like Invoicing plugin to completely remove all of its data when the plugin is deleted/uninstalled.', 'invoicing'), |
|
604 | 604 | 'type' => 'checkbox', |
605 | 605 | 'std' => '' |
606 | 606 | ), |
@@ -609,13 +609,13 @@ discard block |
||
609 | 609 | 'custom-css' => array( |
610 | 610 | 'css_settings' => array( |
611 | 611 | 'id' => 'css_settings', |
612 | - 'name' => '<h3>' . __( 'Custom CSS', 'invoicing' ) . '</h3>', |
|
612 | + 'name' => '<h3>' . __('Custom CSS', 'invoicing') . '</h3>', |
|
613 | 613 | 'type' => 'header', |
614 | 614 | ), |
615 | 615 | 'template_custom_css' => array( |
616 | 616 | 'id' => 'template_custom_css', |
617 | - 'name' => __( 'Invoice Template CSS', 'invoicing' ), |
|
618 | - 'desc' => __( 'Add CSS to modify appearance of the print invoice page.', 'invoicing' ), |
|
617 | + 'name' => __('Invoice Template CSS', 'invoicing'), |
|
618 | + 'desc' => __('Add CSS to modify appearance of the print invoice page.', 'invoicing'), |
|
619 | 619 | 'type' => 'textarea', |
620 | 620 | 'class'=> 'regular-text', |
621 | 621 | 'rows' => 10, |
@@ -629,8 +629,8 @@ discard block |
||
629 | 629 | 'main' => array( |
630 | 630 | 'tool_settings' => array( |
631 | 631 | 'id' => 'tool_settings', |
632 | - 'name' => '<h3>' . __( 'Diagnostic Tools', 'invoicing' ) . '</h3>', |
|
633 | - 'desc' => __( 'Invoicing diagnostic tools', 'invoicing' ), |
|
632 | + 'name' => '<h3>' . __('Diagnostic Tools', 'invoicing') . '</h3>', |
|
633 | + 'desc' => __('Invoicing diagnostic tools', 'invoicing'), |
|
634 | 634 | 'type' => 'tools', |
635 | 635 | ), |
636 | 636 | ), |