Sydney Toolbox - Version 1.0

Version Description

Download this release

Release Info

Developer vladff
Plugin Icon wp plugin Sydney Toolbox
Version 1.0
Comparing to
See all releases

Version 1.0

LICENSE.txt ADDED
@@ -0,0 +1,339 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ GNU GENERAL PUBLIC LICENSE
2
+ Version 2, June 1991
3
+
4
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
5
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
6
+ Everyone is permitted to copy and distribute verbatim copies
7
+ of this license document, but changing it is not allowed.
8
+
9
+ Preamble
10
+
11
+ The licenses for most software are designed to take away your
12
+ freedom to share and change it. By contrast, the GNU General Public
13
+ License is intended to guarantee your freedom to share and change free
14
+ software--to make sure the software is free for all its users. This
15
+ General Public License applies to most of the Free Software
16
+ Foundation's software and to any other program whose authors commit to
17
+ using it. (Some other Free Software Foundation software is covered by
18
+ the GNU Lesser General Public License instead.) You can apply it to
19
+ your programs, too.
20
+
21
+ When we speak of free software, we are referring to freedom, not
22
+ price. Our General Public Licenses are designed to make sure that you
23
+ have the freedom to distribute copies of free software (and charge for
24
+ this service if you wish), that you receive source code or can get it
25
+ if you want it, that you can change the software or use pieces of it
26
+ in new free programs; and that you know you can do these things.
27
+
28
+ To protect your rights, we need to make restrictions that forbid
29
+ anyone to deny you these rights or to ask you to surrender the rights.
30
+ These restrictions translate to certain responsibilities for you if you
31
+ distribute copies of the software, or if you modify it.
32
+
33
+ For example, if you distribute copies of such a program, whether
34
+ gratis or for a fee, you must give the recipients all the rights that
35
+ you have. You must make sure that they, too, receive or can get the
36
+ source code. And you must show them these terms so they know their
37
+ rights.
38
+
39
+ We protect your rights with two steps: (1) copyright the software, and
40
+ (2) offer you this license which gives you legal permission to copy,
41
+ distribute and/or modify the software.
42
+
43
+ Also, for each author's protection and ours, we want to make certain
44
+ that everyone understands that there is no warranty for this free
45
+ software. If the software is modified by someone else and passed on, we
46
+ want its recipients to know that what they have is not the original, so
47
+ that any problems introduced by others will not reflect on the original
48
+ authors' reputations.
49
+
50
+ Finally, any free program is threatened constantly by software
51
+ patents. We wish to avoid the danger that redistributors of a free
52
+ program will individually obtain patent licenses, in effect making the
53
+ program proprietary. To prevent this, we have made it clear that any
54
+ patent must be licensed for everyone's free use or not licensed at all.
55
+
56
+ The precise terms and conditions for copying, distribution and
57
+ modification follow.
58
+
59
+ GNU GENERAL PUBLIC LICENSE
60
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
61
+
62
+ 0. This License applies to any program or other work which contains
63
+ a notice placed by the copyright holder saying it may be distributed
64
+ under the terms of this General Public License. The "Program", below,
65
+ refers to any such program or work, and a "work based on the Program"
66
+ means either the Program or any derivative work under copyright law:
67
+ that is to say, a work containing the Program or a portion of it,
68
+ either verbatim or with modifications and/or translated into another
69
+ language. (Hereinafter, translation is included without limitation in
70
+ the term "modification".) Each licensee is addressed as "you".
71
+
72
+ Activities other than copying, distribution and modification are not
73
+ covered by this License; they are outside its scope. The act of
74
+ running the Program is not restricted, and the output from the Program
75
+ is covered only if its contents constitute a work based on the
76
+ Program (independent of having been made by running the Program).
77
+ Whether that is true depends on what the Program does.
78
+
79
+ 1. You may copy and distribute verbatim copies of the Program's
80
+ source code as you receive it, in any medium, provided that you
81
+ conspicuously and appropriately publish on each copy an appropriate
82
+ copyright notice and disclaimer of warranty; keep intact all the
83
+ notices that refer to this License and to the absence of any warranty;
84
+ and give any other recipients of the Program a copy of this License
85
+ along with the Program.
86
+
87
+ You may charge a fee for the physical act of transferring a copy, and
88
+ you may at your option offer warranty protection in exchange for a fee.
89
+
90
+ 2. You may modify your copy or copies of the Program or any portion
91
+ of it, thus forming a work based on the Program, and copy and
92
+ distribute such modifications or work under the terms of Section 1
93
+ above, provided that you also meet all of these conditions:
94
+
95
+ a) You must cause the modified files to carry prominent notices
96
+ stating that you changed the files and the date of any change.
97
+
98
+ b) You must cause any work that you distribute or publish, that in
99
+ whole or in part contains or is derived from the Program or any
100
+ part thereof, to be licensed as a whole at no charge to all third
101
+ parties under the terms of this License.
102
+
103
+ c) If the modified program normally reads commands interactively
104
+ when run, you must cause it, when started running for such
105
+ interactive use in the most ordinary way, to print or display an
106
+ announcement including an appropriate copyright notice and a
107
+ notice that there is no warranty (or else, saying that you provide
108
+ a warranty) and that users may redistribute the program under
109
+ these conditions, and telling the user how to view a copy of this
110
+ License. (Exception: if the Program itself is interactive but
111
+ does not normally print such an announcement, your work based on
112
+ the Program is not required to print an announcement.)
113
+
114
+ These requirements apply to the modified work as a whole. If
115
+ identifiable sections of that work are not derived from the Program,
116
+ and can be reasonably considered independent and separate works in
117
+ themselves, then this License, and its terms, do not apply to those
118
+ sections when you distribute them as separate works. But when you
119
+ distribute the same sections as part of a whole which is a work based
120
+ on the Program, the distribution of the whole must be on the terms of
121
+ this License, whose permissions for other licensees extend to the
122
+ entire whole, and thus to each and every part regardless of who wrote it.
123
+
124
+ Thus, it is not the intent of this section to claim rights or contest
125
+ your rights to work written entirely by you; rather, the intent is to
126
+ exercise the right to control the distribution of derivative or
127
+ collective works based on the Program.
128
+
129
+ In addition, mere aggregation of another work not based on the Program
130
+ with the Program (or with a work based on the Program) on a volume of
131
+ a storage or distribution medium does not bring the other work under
132
+ the scope of this License.
133
+
134
+ 3. You may copy and distribute the Program (or a work based on it,
135
+ under Section 2) in object code or executable form under the terms of
136
+ Sections 1 and 2 above provided that you also do one of the following:
137
+
138
+ a) Accompany it with the complete corresponding machine-readable
139
+ source code, which must be distributed under the terms of Sections
140
+ 1 and 2 above on a medium customarily used for software interchange; or,
141
+
142
+ b) Accompany it with a written offer, valid for at least three
143
+ years, to give any third party, for a charge no more than your
144
+ cost of physically performing source distribution, a complete
145
+ machine-readable copy of the corresponding source code, to be
146
+ distributed under the terms of Sections 1 and 2 above on a medium
147
+ customarily used for software interchange; or,
148
+
149
+ c) Accompany it with the information you received as to the offer
150
+ to distribute corresponding source code. (This alternative is
151
+ allowed only for noncommercial distribution and only if you
152
+ received the program in object code or executable form with such
153
+ an offer, in accord with Subsection b above.)
154
+
155
+ The source code for a work means the preferred form of the work for
156
+ making modifications to it. For an executable work, complete source
157
+ code means all the source code for all modules it contains, plus any
158
+ associated interface definition files, plus the scripts used to
159
+ control compilation and installation of the executable. However, as a
160
+ special exception, the source code distributed need not include
161
+ anything that is normally distributed (in either source or binary
162
+ form) with the major components (compiler, kernel, and so on) of the
163
+ operating system on which the executable runs, unless that component
164
+ itself accompanies the executable.
165
+
166
+ If distribution of executable or object code is made by offering
167
+ access to copy from a designated place, then offering equivalent
168
+ access to copy the source code from the same place counts as
169
+ distribution of the source code, even though third parties are not
170
+ compelled to copy the source along with the object code.
171
+
172
+ 4. You may not copy, modify, sublicense, or distribute the Program
173
+ except as expressly provided under this License. Any attempt
174
+ otherwise to copy, modify, sublicense or distribute the Program is
175
+ void, and will automatically terminate your rights under this License.
176
+ However, parties who have received copies, or rights, from you under
177
+ this License will not have their licenses terminated so long as such
178
+ parties remain in full compliance.
179
+
180
+ 5. You are not required to accept this License, since you have not
181
+ signed it. However, nothing else grants you permission to modify or
182
+ distribute the Program or its derivative works. These actions are
183
+ prohibited by law if you do not accept this License. Therefore, by
184
+ modifying or distributing the Program (or any work based on the
185
+ Program), you indicate your acceptance of this License to do so, and
186
+ all its terms and conditions for copying, distributing or modifying
187
+ the Program or works based on it.
188
+
189
+ 6. Each time you redistribute the Program (or any work based on the
190
+ Program), the recipient automatically receives a license from the
191
+ original licensor to copy, distribute or modify the Program subject to
192
+ these terms and conditions. You may not impose any further
193
+ restrictions on the recipients' exercise of the rights granted herein.
194
+ You are not responsible for enforcing compliance by third parties to
195
+ this License.
196
+
197
+ 7. If, as a consequence of a court judgment or allegation of patent
198
+ infringement or for any other reason (not limited to patent issues),
199
+ conditions are imposed on you (whether by court order, agreement or
200
+ otherwise) that contradict the conditions of this License, they do not
201
+ excuse you from the conditions of this License. If you cannot
202
+ distribute so as to satisfy simultaneously your obligations under this
203
+ License and any other pertinent obligations, then as a consequence you
204
+ may not distribute the Program at all. For example, if a patent
205
+ license would not permit royalty-free redistribution of the Program by
206
+ all those who receive copies directly or indirectly through you, then
207
+ the only way you could satisfy both it and this License would be to
208
+ refrain entirely from distribution of the Program.
209
+
210
+ If any portion of this section is held invalid or unenforceable under
211
+ any particular circumstance, the balance of the section is intended to
212
+ apply and the section as a whole is intended to apply in other
213
+ circumstances.
214
+
215
+ It is not the purpose of this section to induce you to infringe any
216
+ patents or other property right claims or to contest validity of any
217
+ such claims; this section has the sole purpose of protecting the
218
+ integrity of the free software distribution system, which is
219
+ implemented by public license practices. Many people have made
220
+ generous contributions to the wide range of software distributed
221
+ through that system in reliance on consistent application of that
222
+ system; it is up to the author/donor to decide if he or she is willing
223
+ to distribute software through any other system and a licensee cannot
224
+ impose that choice.
225
+
226
+ This section is intended to make thoroughly clear what is believed to
227
+ be a consequence of the rest of this License.
228
+
229
+ 8. If the distribution and/or use of the Program is restricted in
230
+ certain countries either by patents or by copyrighted interfaces, the
231
+ original copyright holder who places the Program under this License
232
+ may add an explicit geographical distribution limitation excluding
233
+ those countries, so that distribution is permitted only in or among
234
+ countries not thus excluded. In such case, this License incorporates
235
+ the limitation as if written in the body of this License.
236
+
237
+ 9. The Free Software Foundation may publish revised and/or new versions
238
+ of the General Public License from time to time. Such new versions will
239
+ be similar in spirit to the present version, but may differ in detail to
240
+ address new problems or concerns.
241
+
242
+ Each version is given a distinguishing version number. If the Program
243
+ specifies a version number of this License which applies to it and "any
244
+ later version", you have the option of following the terms and conditions
245
+ either of that version or of any later version published by the Free
246
+ Software Foundation. If the Program does not specify a version number of
247
+ this License, you may choose any version ever published by the Free Software
248
+ Foundation.
249
+
250
+ 10. If you wish to incorporate parts of the Program into other free
251
+ programs whose distribution conditions are different, write to the author
252
+ to ask for permission. For software which is copyrighted by the Free
253
+ Software Foundation, write to the Free Software Foundation; we sometimes
254
+ make exceptions for this. Our decision will be guided by the two goals
255
+ of preserving the free status of all derivatives of our free software and
256
+ of promoting the sharing and reuse of software generally.
257
+
258
+ NO WARRANTY
259
+
260
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
261
+ FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
262
+ OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
263
+ PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
264
+ OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
265
+ MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
266
+ TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
267
+ PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
268
+ REPAIR OR CORRECTION.
269
+
270
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
271
+ WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
272
+ REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
273
+ INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
274
+ OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
275
+ TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
276
+ YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
277
+ PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
278
+ POSSIBILITY OF SUCH DAMAGES.
279
+
280
+ END OF TERMS AND CONDITIONS
281
+
282
+ How to Apply These Terms to Your New Programs
283
+
284
+ If you develop a new program, and you want it to be of the greatest
285
+ possible use to the public, the best way to achieve this is to make it
286
+ free software which everyone can redistribute and change under these terms.
287
+
288
+ To do so, attach the following notices to the program. It is safest
289
+ to attach them to the start of each source file to most effectively
290
+ convey the exclusion of warranty; and each file should have at least
291
+ the "copyright" line and a pointer to where the full notice is found.
292
+
293
+ <one line to give the program's name and a brief idea of what it does.>
294
+ Copyright (C) <year> <name of author>
295
+
296
+ This program is free software; you can redistribute it and/or modify
297
+ it under the terms of the GNU General Public License as published by
298
+ the Free Software Foundation; either version 2 of the License, or
299
+ (at your option) any later version.
300
+
301
+ This program is distributed in the hope that it will be useful,
302
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
303
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
304
+ GNU General Public License for more details.
305
+
306
+ You should have received a copy of the GNU General Public License along
307
+ with this program; if not, write to the Free Software Foundation, Inc.,
308
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
309
+
310
+ Also add information on how to contact you by electronic and paper mail.
311
+
312
+ If the program is interactive, make it output a short notice like this
313
+ when it starts in an interactive mode:
314
+
315
+ Gnomovision version 69, Copyright (C) year name of author
316
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
317
+ This is free software, and you are welcome to redistribute it
318
+ under certain conditions; type `show c' for details.
319
+
320
+ The hypothetical commands `show w' and `show c' should show the appropriate
321
+ parts of the General Public License. Of course, the commands you use may
322
+ be called something other than `show w' and `show c'; they could even be
323
+ mouse-clicks or menu items--whatever suits your program.
324
+
325
+ You should also get your employer (if you work as a programmer) or your
326
+ school, if any, to sign a "copyright disclaimer" for the program, if
327
+ necessary. Here is a sample; alter the names:
328
+
329
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
330
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
331
+
332
+ <signature of Ty Coon>, 1 April 1989
333
+ Ty Coon, President of Vice
334
+
335
+ This General Public License does not permit incorporating your program into
336
+ proprietary programs. If your program is a subroutine library, you may
337
+ consider it more useful to permit linking proprietary applications with the
338
+ library. If this is what you want to do, use the GNU Lesser General
339
+ Public License instead of this License.
README.txt ADDED
@@ -0,0 +1,32 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === Plugin Name ===
2
+ Contributors: athemes, vladff
3
+ Tags: sydney, custom post types, custom fields
4
+ Requires at least: 4.0
5
+ Tested up to: 4.4
6
+ Stable tag: 1.0.0
7
+ License: GPLv2 or later
8
+ License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
+
10
+ Registers custom post types and custom fields for the Sydney theme
11
+
12
+ == Description ==
13
+
14
+ **The Sydney Toolbox plugin is meant to be used only with the Sydney WordPress theme.**
15
+
16
+ This plugin registers custom post types and custom fields that are needed in the [Sydney theme](http://wordpress.org/themes/sydney/)
17
+
18
+ == Installation ==
19
+
20
+ 1. Go to Plugins > Add New and search for Sydney Toolbox. Install and activate it.
21
+ 2. That's it. No configuration needed.
22
+
23
+ == Frequently Asked Questions ==
24
+
25
+ None yet.
26
+
27
+ == Screenshots ==
28
+
29
+ == Changelog ==
30
+
31
+ = 1.0.0 =
32
+ * Initial version
inc/metaboxes/clients-metabox.php ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Clients custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_clients_metabox() {
14
+ new Sydney_Toolbox_Clients();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_clients_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_clients_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Clients {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ }
28
+
29
+ public function add_meta_box( $post_type ) {
30
+ global $post;
31
+ add_meta_box(
32
+ 'st_clients_metabox'
33
+ ,__( 'Client info', 'sydney_toolbox' )
34
+ ,array( $this, 'render_meta_box_content' )
35
+ ,'clients'
36
+ ,'advanced'
37
+ ,'high'
38
+ );
39
+ }
40
+
41
+ public function save( $post_id ) {
42
+
43
+ if ( ! isset( $_POST['sydney_toolbox_clients_nonce'] ) )
44
+ return $post_id;
45
+
46
+ $nonce = $_POST['sydney_toolbox_clients_nonce'];
47
+
48
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_clients' ) )
49
+ return $post_id;
50
+
51
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
52
+ return $post_id;
53
+
54
+ if ( 'clients' == $_POST['post_type'] ) {
55
+
56
+ if ( ! current_user_can( 'edit_page', $post_id ) )
57
+ return $post_id;
58
+
59
+ } else {
60
+
61
+ if ( ! current_user_can( 'edit_post', $post_id ) )
62
+ return $post_id;
63
+ }
64
+
65
+ $link = isset( $_POST['sydney_toolbox_clients_info'] ) ? esc_url_raw($_POST['sydney_toolbox_clients_info']) : false;
66
+ update_post_meta( $post_id, 'wpcf-client-link', $link );
67
+
68
+ }
69
+
70
+ public function render_meta_box_content( $post ) {
71
+ wp_nonce_field( 'sydney_toolbox_clients', 'sydney_toolbox_clients_nonce' );
72
+
73
+ $link = get_post_meta( $post->ID, 'wpcf-client-link', true );
74
+
75
+ ?>
76
+ <p><strong><label for="sydney_toolbox_clients_info"><?php _e( 'Client link', 'sydney_toolbox' ); ?></label></strong></p>
77
+ <p><em><?php _e('Add a link for the client\'s website here [optional]', 'sdyney_toolbox'); ?></em></p>
78
+ <p><input type="text" class="widefat" id="sydney_toolbox_clients_info" name="sydney_toolbox_clients_info" value="<?php echo esc_url($link); ?>"></p>
79
+
80
+ <?php
81
+ }
82
+ }
inc/metaboxes/employees-metabox.php ADDED
@@ -0,0 +1,103 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Employees custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_employees_metabox() {
14
+ new Sydney_Toolbox_Employees();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_employees_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_employees_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Employees {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ }
28
+
29
+ public function add_meta_box( $post_type ) {
30
+ global $post;
31
+ add_meta_box(
32
+ 'st_employees_metabox'
33
+ ,__( 'Employee info', 'sydney_toolbox' )
34
+ ,array( $this, 'render_meta_box_content' )
35
+ ,'employees'
36
+ ,'advanced'
37
+ ,'high'
38
+ );
39
+ }
40
+
41
+ public function save( $post_id ) {
42
+
43
+ if ( ! isset( $_POST['sydney_toolbox_employees_nonce'] ) )
44
+ return $post_id;
45
+
46
+ $nonce = $_POST['sydney_toolbox_employees_nonce'];
47
+
48
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_employees' ) )
49
+ return $post_id;
50
+
51
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
52
+ return $post_id;
53
+
54
+ if ( 'employees' == $_POST['post_type'] ) {
55
+
56
+ if ( ! current_user_can( 'edit_page', $post_id ) )
57
+ return $post_id;
58
+
59
+ } else {
60
+
61
+ if ( ! current_user_can( 'edit_post', $post_id ) )
62
+ return $post_id;
63
+ }
64
+
65
+
66
+ $position = isset( $_POST['sydney_toolbox_emp_position'] ) ? sanitize_text_field($_POST['sydney_toolbox_emp_position']) : false;
67
+ $facebook = isset( $_POST['sydney_toolbox_emp_facebook'] ) ? esc_url_raw($_POST['sydney_toolbox_emp_facebook']) : false;
68
+ $twitter = isset( $_POST['sydney_toolbox_emp_twitter'] ) ? esc_url_raw($_POST['sydney_toolbox_emp_twitter']) : false;
69
+ $google = isset( $_POST['sydney_toolbox_emp_google'] ) ? esc_url_raw($_POST['sydney_toolbox_emp_google']) : false;
70
+ $link = isset( $_POST['sydney_toolbox_emp_link'] ) ? esc_url_raw($_POST['sydney_toolbox_emp_link']) : false;
71
+
72
+ update_post_meta( $post_id, 'wpcf-position', $position );
73
+ update_post_meta( $post_id, 'wpcf-facebook', $facebook );
74
+ update_post_meta( $post_id, 'wpcf-twitter', $twitter );
75
+ update_post_meta( $post_id, 'wpcf-google-plus', $google );
76
+ update_post_meta( $post_id, 'wpcf-custom-link', $link );
77
+ }
78
+
79
+ public function render_meta_box_content( $post ) {
80
+ wp_nonce_field( 'sydney_toolbox_employees', 'sydney_toolbox_employees_nonce' );
81
+
82
+ $position = get_post_meta( $post->ID, 'wpcf-position', true );
83
+ $facebook = get_post_meta( $post->ID, 'wpcf-facebook', true );
84
+ $twitter = get_post_meta( $post->ID, 'wpcf-twitter', true );
85
+ $google = get_post_meta( $post->ID, 'wpcf-google-plus', true );
86
+ $link = get_post_meta( $post->ID, 'wpcf-custom-link', true );
87
+
88
+ ?>
89
+ <p><strong><label for="sydney_toolbox_emp_position"><?php _e( 'Employee position', 'sydney_toolbox' ); ?></label></strong></p>
90
+ <p><input type="text" class="widefat" id="sydney_toolbox_emp_position" name="sydney_toolbox_emp_position" value="<?php echo esc_html($position); ?>"></p>
91
+ <p><strong><label for="sydney_toolbox_emp_facebook"><?php _e( 'Employee Facebook', 'sydney_toolbox' ); ?></label></strong></p>
92
+ <p><input type="text" class="widefat" id="sydney_toolbox_emp_facebook" name="sydney_toolbox_emp_facebook" value="<?php echo esc_url($facebook); ?>"></p>
93
+ <p><strong><label for="sydney_toolbox_emp_twitter"><?php _e( 'Employee Twitter', 'sydney_toolbox' ); ?></label></strong></p>
94
+ <p><input type="text" class="widefat" id="sydney_toolbox_emp_twitter" name="sydney_toolbox_emp_twitter" value="<?php echo esc_url($twitter); ?>"></p>
95
+ <p><strong><label for="sydney_toolbox_emp_google"><?php _e( 'Employee Google', 'sydney_toolbox' ); ?></label></strong></p>
96
+ <p><input type="text" class="widefat" id="sydney_toolbox_emp_google" name="sydney_toolbox_emp_google" value="<?php echo esc_url($google); ?>"></p>
97
+ <p><strong><label for="sydney_toolbox_emp_link"><?php _e( 'Employee Link', 'sydney_toolbox' ); ?></label></strong></p>
98
+ <p><em><?php _e('Add a link here if you want the employee name to link somewhere.', 'sdyney_toolbox'); ?></em></p>
99
+ <p><input type="text" class="widefat" id="sydney_toolbox_emp_link" name="sydney_toolbox_emp_link" value="<?php echo esc_url($link); ?>"></p>
100
+
101
+ <?php
102
+ }
103
+ }
inc/metaboxes/projects-metabox.php ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Projects custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_projects_metabox() {
14
+ new Sydney_Toolbox_Projects();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_projects_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_projects_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Projects {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ }
28
+
29
+ public function add_meta_box( $post_type ) {
30
+ global $post;
31
+ add_meta_box(
32
+ 'st_projects_metabox'
33
+ ,__( 'Project info', 'sydney_toolbox' )
34
+ ,array( $this, 'render_meta_box_content' )
35
+ ,'projects'
36
+ ,'advanced'
37
+ ,'high'
38
+ );
39
+ }
40
+
41
+ public function save( $post_id ) {
42
+
43
+ if ( ! isset( $_POST['sydney_toolbox_projects_nonce'] ) )
44
+ return $post_id;
45
+
46
+ $nonce = $_POST['sydney_toolbox_projects_nonce'];
47
+
48
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_projects' ) )
49
+ return $post_id;
50
+
51
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
52
+ return $post_id;
53
+
54
+ if ( 'projects' == $_POST['post_type'] ) {
55
+
56
+ if ( ! current_user_can( 'edit_page', $post_id ) )
57
+ return $post_id;
58
+
59
+ } else {
60
+
61
+ if ( ! current_user_can( 'edit_post', $post_id ) )
62
+ return $post_id;
63
+ }
64
+
65
+ $link = isset( $_POST['sydney_toolbox_projects_info'] ) ? esc_url_raw($_POST['sydney_toolbox_projects_info']) : false;
66
+ update_post_meta( $post_id, 'wpcf-project-link', $link );
67
+
68
+ }
69
+
70
+ public function render_meta_box_content( $post ) {
71
+ wp_nonce_field( 'sydney_toolbox_projects', 'sydney_toolbox_projects_nonce' );
72
+
73
+ $link = get_post_meta( $post->ID, 'wpcf-project-link', true );
74
+
75
+ ?>
76
+ <p><strong><label for="sydney_toolbox_projects_info"><?php _e( 'Project link', 'sydney_toolbox' ); ?></label></strong></p>
77
+ <p><em><?php _e('Add an URL here to make this project link to another page (internal or external). Leave it empty and it will default to its own page.', 'sdyney_toolbox'); ?></em></p>
78
+ <p><input type="text" class="widefat" id="sydney_toolbox_projects_info" name="sydney_toolbox_projects_info" value="<?php echo esc_url($link); ?>"></p>
79
+
80
+ <?php
81
+ }
82
+ }
inc/metaboxes/services-metabox.php ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Services custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_services_metabox() {
14
+ new Sydney_Toolbox_Services();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_services_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_services_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Services {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ }
28
+
29
+ public function add_meta_box( $post_type ) {
30
+ global $post;
31
+ add_meta_box(
32
+ 'st_services_metabox'
33
+ ,__( 'Service info', 'sydney_toolbox' )
34
+ ,array( $this, 'render_meta_box_content' )
35
+ ,'services'
36
+ ,'advanced'
37
+ ,'high'
38
+ );
39
+ }
40
+
41
+ public function save( $post_id ) {
42
+
43
+ if ( ! isset( $_POST['sydney_toolbox_services_nonce'] ) )
44
+ return $post_id;
45
+
46
+ $nonce = $_POST['sydney_toolbox_services_nonce'];
47
+
48
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_services' ) )
49
+ return $post_id;
50
+
51
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
52
+ return $post_id;
53
+
54
+ if ( 'services' == $_POST['post_type'] ) {
55
+
56
+ if ( ! current_user_can( 'edit_page', $post_id ) )
57
+ return $post_id;
58
+
59
+ } else {
60
+
61
+ if ( ! current_user_can( 'edit_post', $post_id ) )
62
+ return $post_id;
63
+ }
64
+
65
+ $icon = isset( $_POST['sydney_toolbox_service_icon'] ) ? sanitize_text_field($_POST['sydney_toolbox_service_icon']) : false;
66
+ $link = isset( $_POST['sydney_toolbox_service_link'] ) ? esc_url_raw($_POST['sydney_toolbox_service_link']) : false;
67
+
68
+ update_post_meta( $post_id, 'wpcf-service-icon', $icon );
69
+ update_post_meta( $post_id, 'wpcf-service-link', $link );
70
+ }
71
+
72
+ public function render_meta_box_content( $post ) {
73
+ wp_nonce_field( 'sydney_toolbox_services', 'sydney_toolbox_services_nonce' );
74
+ $icon = get_post_meta( $post->ID, 'wpcf-service-icon', true ); //Types generated fields compatibility
75
+ $link = get_post_meta( $post->ID, 'wpcf-service-link', true );
76
+ ?>
77
+ <p><strong><label for="sydney_toolbox_service_icon"><?php _e( 'Service icon', 'sydney_toolbox' ); ?></label></strong></p>
78
+ <p><em><?php echo __('Example: <strong>fa-android</strong>. Full list of icons is <a href="http://fortawesome.github.io/Font-Awesome/cheatsheet/" target="_blank">here</a>'); ?></em></p>
79
+ <p><input type="text" class="widefat" id="sydney_toolbox_service_icon" name="sydney_toolbox_service_icon" value="<?php echo esc_html($icon); ?>"></p>
80
+ <p><strong><label for="sydney_toolbox_service_link"><?php _e( 'Service link', 'sydney_toolbox' ); ?></label></strong></p>
81
+ <p><em><?php echo __('You can link your service to a page of your choice by entering the URL in this field'); ?></em></p>
82
+ <p><input type="text" class="widefat" id="sydney_toolbox_service_link" name="sydney_toolbox_service_link" value="<?php echo esc_url($link); ?>"></p>
83
+ <?php
84
+ }
85
+ }
inc/metaboxes/singles-metabox.php ADDED
@@ -0,0 +1,118 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the single posts/pages
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_singles_options_metabox() {
14
+ new Sydney_Toolbox_Singles_Options();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_singles_options_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_singles_options_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Singles_Options {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ add_action( 'admin_enqueue_scripts', array( $this, 'color_picker' ) );
28
+ }
29
+
30
+ public function add_meta_box( $post_type ) {
31
+ global $post;
32
+ $post_types = array('post', 'page', 'services', 'employees', 'testimonials', 'projects', 'timeline-events');
33
+ if ( in_array( $post_type, $post_types )) {
34
+ add_meta_box(
35
+ 'st_singles_metabox'
36
+ ,__( 'Post/page options', 'sydney_toolbox' )
37
+ ,array( $this, 'render_meta_box_content' )
38
+ ,$post_type
39
+ ,'advanced'
40
+ ,'high'
41
+ );
42
+ }
43
+ }
44
+
45
+ public function save( $post_id ) {
46
+
47
+ if ( ! isset( $_POST['sydney_toolbox_singles_options_nonce'] ) )
48
+ return $post_id;
49
+
50
+ $nonce = $_POST['sydney_toolbox_singles_options_nonce'];
51
+
52
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_singles_options' ) )
53
+ return $post_id;
54
+
55
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
56
+ return $post_id;
57
+
58
+ if ( 'page' == $_POST['post_type'] ) {
59
+
60
+ if ( ! current_user_can( 'edit_page', $post_id ) )
61
+ return $post_id;
62
+
63
+ } else {
64
+
65
+ if ( ! current_user_can( 'edit_post', $post_id ) )
66
+ return $post_id;
67
+ }
68
+
69
+ $background_image = isset( $_POST['sydney_toolbox_background_image'] ) ? esc_url_raw($_POST['sydney_toolbox_background_image']) : false;
70
+ $background_color = isset( $_POST['sydney_toolbox_background_color'] ) ? sanitize_text_field($_POST['sydney_toolbox_background_color']) : false;
71
+ $title = isset( $_POST['sydney_toolbox_hide_title'] ) ? (bool)($_POST['sydney_toolbox_hide_title']) : '';
72
+ $opacity = isset( $_POST['sydney_toolbox_opacity'] ) ? sanitize_text_field($_POST['sydney_toolbox_opacity']) : false;
73
+
74
+ update_post_meta( $post_id, 'wpcf-single-background-image', $background_image );
75
+ update_post_meta( $post_id, 'wpcf-single-background-color', $background_color );
76
+ update_post_meta( $post_id, 'wpcf-single-hide-title', $title );
77
+ update_post_meta( $post_id, 'wpcf-single-content-opacity', $opacity );
78
+ }
79
+
80
+ public function render_meta_box_content( $post ) {
81
+ wp_nonce_field( 'sydney_toolbox_singles_options', 'sydney_toolbox_singles_options_nonce' );
82
+
83
+ $background_image = get_post_meta( $post->ID, 'wpcf-single-background-image', true );
84
+ $background_color = get_post_meta( $post->ID, 'wpcf-single-background-color', true );
85
+ $title = get_post_meta( $post->ID, 'wpcf-single-hide-title', true );
86
+ $opacity = get_post_meta( $post->ID, 'wpcf-single-content-opacity', true );
87
+ ?>
88
+
89
+ <p><em><?php echo __('Here you can control the options just for this page/post.'); ?></em></p>
90
+
91
+ <p><strong><label for="sydney_toolbox_background_image"><?php _e( 'Background image URL', 'sydney_toolbox' ); ?></label></strong></p>
92
+ <p><em><?php echo __('If you want to use this option, make sure you leave the next background color option empty.'); ?></em></p>
93
+ <p><input type="text" class="widefat" id="sydney_toolbox_background_image" name="sydney_toolbox_background_image" value="<?php echo esc_html($background_image); ?>"></p>
94
+ <p><strong><label for="sydney_toolbox_background_color"><?php _e( 'Background color', 'sydney_toolbox' ); ?></label></strong></p>
95
+ <p><input type="text" class="color-field" id="sydney_toolbox_background_color" name="sydney_toolbox_background_color" value="<?php echo esc_html($background_color); ?>"></p>
96
+ <p><input type="checkbox" id="sydney_toolbox_hide_title" class="checkbox" name="sydney_toolbox_hide_title" <?php checked( $title ); ?> /></p>
97
+ <p><label for="sydney_toolbox_hide_title"><?php _e( 'Check this box to hide the title', 'sydney_toolbox' ); ?></label></p>
98
+ <p><strong><label for="sydney_toolbox_opacity"><?php _e( 'Content wrapper opacity', 'sydney_toolbox' ); ?></label></strong></p>
99
+ <p><em><?php echo __('Enter a value for the opacity of the white content background. Values from 0 to 1 (example 0.4)'); ?></em></p>
100
+ <p><input type="text" class="widefat" id="sydney_toolbox_opacity" name="sydney_toolbox_opacity" value="<?php echo esc_html($opacity); ?>"></p>
101
+
102
+ <script>
103
+ (function( $ ) {
104
+ $(function() {
105
+ $('.color-field').wpColorPicker();
106
+ });
107
+ })( jQuery );
108
+ </script>
109
+
110
+ <?php
111
+ }
112
+
113
+ public function color_picker() {
114
+ wp_enqueue_style( 'wp-color-picker');
115
+ wp_enqueue_script( 'wp-color-picker');
116
+ }
117
+
118
+ }
inc/metaboxes/testimonials-metabox.php ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Testimonials custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_testimonials_metabox() {
14
+ new Sydney_Toolbox_Testimonials();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_testimonials_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_testimonials_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Testimonials {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ }
28
+
29
+ public function add_meta_box( $post_type ) {
30
+ global $post;
31
+ add_meta_box(
32
+ 'st_testimonials_metabox'
33
+ ,__( 'Client info', 'sydney_toolbox' )
34
+ ,array( $this, 'render_meta_box_content' )
35
+ ,'testimonials'
36
+ ,'advanced'
37
+ ,'high'
38
+ );
39
+ }
40
+
41
+ public function save( $post_id ) {
42
+
43
+ if ( ! isset( $_POST['sydney_toolbox_testimonials_nonce'] ) )
44
+ return $post_id;
45
+
46
+ $nonce = $_POST['sydney_toolbox_testimonials_nonce'];
47
+
48
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_testimonials' ) )
49
+ return $post_id;
50
+
51
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
52
+ return $post_id;
53
+
54
+ if ( 'testimonials' == $_POST['post_type'] ) {
55
+
56
+ if ( ! current_user_can( 'edit_page', $post_id ) )
57
+ return $post_id;
58
+
59
+ } else {
60
+
61
+ if ( ! current_user_can( 'edit_post', $post_id ) )
62
+ return $post_id;
63
+ }
64
+
65
+
66
+ $position = isset( $_POST['sydney_toolbox_client_info'] ) ? sanitize_text_field($_POST['sydney_toolbox_client_info']) : false;
67
+
68
+ update_post_meta( $post_id, 'wpcf-client-function', $position );
69
+
70
+ }
71
+
72
+ public function render_meta_box_content( $post ) {
73
+ wp_nonce_field( 'sydney_toolbox_testimonials', 'sydney_toolbox_testimonials_nonce' );
74
+
75
+ $position = get_post_meta( $post->ID, 'wpcf-client-function', true );
76
+
77
+ ?>
78
+ <p><strong><label for="sydney_toolbox_client_info"><?php _e( 'Client function/Company name', 'sydney_toolbox' ); ?></label></strong></p>
79
+ <p><em><?php _e('Enter your client\'s function/company name', 'sdyney_toolbox'); ?></em></p>
80
+ <p><input type="text" class="widefat" id="sydney_toolbox_client_info" name="sydney_toolbox_client_info" value="<?php echo esc_html($position); ?>"></p>
81
+
82
+ <?php
83
+ }
84
+ }
inc/metaboxes/timeline-metabox.php ADDED
@@ -0,0 +1,115 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Metabox for the Timeline Events custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ function sydney_toolbox_timeline_events_metabox() {
14
+ new Sydney_Toolbox_Timeline_Events();
15
+ }
16
+
17
+ if ( is_admin() ) {
18
+ add_action( 'load-post.php', 'sydney_toolbox_timeline_events_metabox' );
19
+ add_action( 'load-post-new.php', 'sydney_toolbox_timeline_events_metabox' );
20
+ }
21
+
22
+ class Sydney_Toolbox_Timeline_Events {
23
+
24
+ public function __construct() {
25
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_box' ) );
26
+ add_action( 'save_post', array( $this, 'save' ) );
27
+ add_action( 'admin_enqueue_scripts', array( $this, 'color_picker' ) );
28
+ }
29
+
30
+ public function add_meta_box( $post_type ) {
31
+ global $post;
32
+ add_meta_box(
33
+ 'st_timeline_metabox'
34
+ ,__( 'Timeline info', 'sydney_toolbox' )
35
+ ,array( $this, 'render_meta_box_content' )
36
+ ,'timeline-events'
37
+ ,'advanced'
38
+ ,'high'
39
+ );
40
+ }
41
+
42
+ public function save( $post_id ) {
43
+
44
+ if ( ! isset( $_POST['sydney_toolbox_timeline_events_nonce'] ) )
45
+ return $post_id;
46
+
47
+ $nonce = $_POST['sydney_toolbox_timeline_events_nonce'];
48
+
49
+ if ( ! wp_verify_nonce( $nonce, 'sydney_toolbox_timeline_events' ) )
50
+ return $post_id;
51
+
52
+ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )
53
+ return $post_id;
54
+
55
+ if ( 'timeline-events' == $_POST['post_type'] ) {
56
+
57
+ if ( ! current_user_can( 'edit_page', $post_id ) )
58
+ return $post_id;
59
+
60
+ } else {
61
+
62
+ if ( ! current_user_can( 'edit_post', $post_id ) )
63
+ return $post_id;
64
+ }
65
+
66
+ $date = isset( $_POST['sydney_toolbox_event_date'] ) ? sanitize_text_field($_POST['sydney_toolbox_event_date']) : false;
67
+ $icon = isset( $_POST['sydney_toolbox_event_icon'] ) ? sanitize_text_field($_POST['sydney_toolbox_event_icon']) : false;
68
+ $color = isset( $_POST['sydney_toolbox_event_color'] ) ? strip_tags($_POST['sydney_toolbox_event_color']) : '';
69
+ $link = isset( $_POST['sydney_toolbox_event_link'] ) ? esc_url_raw($_POST['sydney_toolbox_event_link']) : false;
70
+
71
+ update_post_meta( $post_id, 'wpcf-event-date', $date );
72
+ update_post_meta( $post_id, 'wpcf-event-icon', $icon );
73
+ update_post_meta( $post_id, 'wpcf-event-icon-color', $color );
74
+ update_post_meta( $post_id, 'wpcf-event-url', $link );
75
+ }
76
+
77
+ public function render_meta_box_content( $post ) {
78
+ wp_nonce_field( 'sydney_toolbox_timeline_events', 'sydney_toolbox_timeline_events_nonce' );
79
+
80
+ $date = get_post_meta( $post->ID, 'wpcf-event-date', true );
81
+ $icon = get_post_meta( $post->ID, 'wpcf-event-icon', true );
82
+ $color = get_post_meta( $post->ID, 'wpcf-event-icon-color', true );
83
+ $link = get_post_meta( $post->ID, 'wpcf-event-url', true );
84
+ ?>
85
+
86
+ <p><strong><label for="sydney_toolbox_event_date"><?php _e( 'Event icon', 'sydney_toolbox' ); ?></label></strong></p>
87
+ <p><em><?php echo __('Add the date when this timeline event happened.'); ?></em></p>
88
+ <p><input type="text" class="widefat" id="sydney_toolbox_event_date" name="sydney_toolbox_event_date" value="<?php echo esc_html($date); ?>"></p>
89
+ <p><strong><label for="sydney_toolbox_event_icon"><?php _e( 'Event icon', 'sydney_toolbox' ); ?></label></strong></p>
90
+ <p><em><?php echo __('Example: <strong>fa-android</strong>. Full list of icons is <a href="http://fortawesome.github.io/Font-Awesome/cheatsheet/" target="_blank">here</a>'); ?></em></p>
91
+ <p><input type="text" class="widefat" id="sydney_toolbox_event_icon" name="sydney_toolbox_event_icon" value="<?php echo esc_html($icon); ?>"></p>
92
+ <p><strong><label for="sydney_toolbox_event_color"><?php _e( 'Event color', 'sydney_toolbox' ); ?></label></strong></p>
93
+ <p><em><?php echo __('Select a color for the event icon.'); ?></em></p>
94
+ <p><input type="text" class="color-field" id="sydney_toolbox_event_color" name="sydney_toolbox_event_color" value="<?php echo esc_url($color); ?>"></p>
95
+ <p><strong><label for="sydney_toolbox_event_link"><?php _e( 'Event link', 'sydney_toolbox' ); ?></label></strong></p>
96
+ <p><em><?php echo __('You can link your event to a page of your choice by entering the URL in this field'); ?></em></p>
97
+ <p><input type="text" class="widefat" id="sydney_toolbox_event_link" name="sydney_toolbox_event_link" value="<?php echo esc_url($link); ?>"></p>
98
+
99
+ <script>
100
+ (function( $ ) {
101
+ $(function() {
102
+ $('.color-field').wpColorPicker();
103
+ });
104
+ })( jQuery );
105
+ </script>
106
+
107
+ <?php
108
+ }
109
+
110
+ public function color_picker() {
111
+ wp_enqueue_style( 'wp-color-picker');
112
+ wp_enqueue_script( 'wp-color-picker');
113
+ }
114
+
115
+ }
inc/post-type-clients.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Clients custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Clients custom post type
14
+ function sydney_toolbox_register_clients() {
15
+
16
+ $slug = apply_filters( 'sydney_clients_rewrite_slug', 'clients' );
17
+
18
+ $labels = array(
19
+ 'name' => _x( 'Clients', 'Post Type General Name', 'sydney_toolbox' ),
20
+ 'singular_name' => _x( 'Client', 'Post Type Singular Name', 'sydney_toolbox' ),
21
+ 'menu_name' => __( 'Clients', 'sydney_toolbox' ),
22
+ 'name_admin_bar' => __( 'Clients', 'sydney_toolbox' ),
23
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
24
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
25
+ 'all_items' => __( 'All Clients', 'sydney_toolbox' ),
26
+ 'add_new_item' => __( 'Add New Client', 'sydney_toolbox' ),
27
+ 'add_new' => __( 'Add New Client', 'sydney_toolbox' ),
28
+ 'new_item' => __( 'New Client', 'sydney_toolbox' ),
29
+ 'edit_item' => __( 'Edit Client', 'sydney_toolbox' ),
30
+ 'update_item' => __( 'Update Client', 'sydney_toolbox' ),
31
+ 'view_item' => __( 'View Client', 'sydney_toolbox' ),
32
+ 'search_items' => __( 'Search Client', 'sydney_toolbox' ),
33
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
34
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
35
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
36
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
37
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
38
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
39
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
40
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
41
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
42
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
43
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
44
+ );
45
+ $args = array(
46
+ 'label' => __( 'Client', 'sydney_toolbox' ),
47
+ 'description' => __( 'A post type for your clients', 'sydney_toolbox' ),
48
+ 'labels' => $labels,
49
+ 'supports' => array( 'title', 'thumbnail', ),
50
+ 'taxonomies' => array( 'category' ),
51
+ 'hierarchical' => false,
52
+ 'public' => true,
53
+ 'show_ui' => true,
54
+ 'show_in_menu' => true,
55
+ 'menu_position' => 26,
56
+ 'menu_icon' => 'dashicons-groups',
57
+ 'show_in_admin_bar' => true,
58
+ 'show_in_nav_menus' => true,
59
+ 'can_export' => true,
60
+ 'has_archive' => true,
61
+ 'exclude_from_search' => false,
62
+ 'publicly_queryable' => true,
63
+ 'capability_type' => 'page',
64
+ 'rewrite' => array( 'slug' => $slug ),
65
+ );
66
+ register_post_type( 'clients', $args );
67
+
68
+ }
69
+ add_action( 'init', 'sydney_toolbox_register_clients', 0 );
inc/post-type-employees.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Employees custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Employees custom post type
14
+ function sydney_toolbox_register_employees() {
15
+
16
+ $slug = apply_filters( 'sydney_employees_rewrite_slug', 'employees' );
17
+
18
+ $labels = array(
19
+ 'name' => _x( 'Employees', 'Post Type General Name', 'sydney_toolbox' ),
20
+ 'singular_name' => _x( 'Employee', 'Post Type Singular Name', 'sydney_toolbox' ),
21
+ 'menu_name' => __( 'Employees', 'sydney_toolbox' ),
22
+ 'name_admin_bar' => __( 'Employees', 'sydney_toolbox' ),
23
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
24
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
25
+ 'all_items' => __( 'All Employees', 'sydney_toolbox' ),
26
+ 'add_new_item' => __( 'Add New Employee', 'sydney_toolbox' ),
27
+ 'add_new' => __( 'Add New Employee', 'sydney_toolbox' ),
28
+ 'new_item' => __( 'New Employee', 'sydney_toolbox' ),
29
+ 'edit_item' => __( 'Edit Employee', 'sydney_toolbox' ),
30
+ 'update_item' => __( 'Update Employee', 'sydney_toolbox' ),
31
+ 'view_item' => __( 'View Employee', 'sydney_toolbox' ),
32
+ 'search_items' => __( 'Search Employee', 'sydney_toolbox' ),
33
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
34
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
35
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
36
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
37
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
38
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
39
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
40
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
41
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
42
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
43
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
44
+ );
45
+ $args = array(
46
+ 'label' => __( 'Employee', 'sydney_toolbox' ),
47
+ 'description' => __( 'A post type for your employees', 'sydney_toolbox' ),
48
+ 'labels' => $labels,
49
+ 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail' ),
50
+ 'taxonomies' => array( 'category' ),
51
+ 'hierarchical' => false,
52
+ 'public' => true,
53
+ 'show_ui' => true,
54
+ 'show_in_menu' => true,
55
+ 'menu_position' => 26,
56
+ 'menu_icon' => 'dashicons-businessman',
57
+ 'show_in_admin_bar' => true,
58
+ 'show_in_nav_menus' => true,
59
+ 'can_export' => true,
60
+ 'has_archive' => true,
61
+ 'exclude_from_search' => false,
62
+ 'publicly_queryable' => true,
63
+ 'capability_type' => 'page',
64
+ 'rewrite' => array( 'slug' => $slug ),
65
+ );
66
+ register_post_type( 'employees', $args );
67
+
68
+ }
69
+ add_action( 'init', 'sydney_toolbox_register_employees', 0 );
inc/post-type-projects.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Projects custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Projects custom post type
14
+ function sydney_toolbox_register_projects() {
15
+
16
+ $slug = apply_filters( 'sydney_projects_rewrite_slug', 'projects' );
17
+
18
+ $labels = array(
19
+ 'name' => _x( 'Projects', 'Post Type General Name', 'sydney_toolbox' ),
20
+ 'singular_name' => _x( 'Project', 'Post Type Singular Name', 'sydney_toolbox' ),
21
+ 'menu_name' => __( 'Projects', 'sydney_toolbox' ),
22
+ 'name_admin_bar' => __( 'Projects', 'sydney_toolbox' ),
23
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
24
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
25
+ 'all_items' => __( 'All Projects', 'sydney_toolbox' ),
26
+ 'add_new_item' => __( 'Add New Project', 'sydney_toolbox' ),
27
+ 'add_new' => __( 'Add New Project', 'sydney_toolbox' ),
28
+ 'new_item' => __( 'New Project', 'sydney_toolbox' ),
29
+ 'edit_item' => __( 'Edit Project', 'sydney_toolbox' ),
30
+ 'update_item' => __( 'Update Project', 'sydney_toolbox' ),
31
+ 'view_item' => __( 'View Project', 'sydney_toolbox' ),
32
+ 'search_items' => __( 'Search Project', 'sydney_toolbox' ),
33
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
34
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
35
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
36
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
37
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
38
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
39
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
40
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
41
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
42
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
43
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
44
+ );
45
+ $args = array(
46
+ 'label' => __( 'Project', 'sydney_toolbox' ),
47
+ 'description' => __( 'A post type for your projects', 'sydney_toolbox' ),
48
+ 'labels' => $labels,
49
+ 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail' ),
50
+ 'taxonomies' => array( 'category' ),
51
+ 'hierarchical' => false,
52
+ 'public' => true,
53
+ 'show_ui' => true,
54
+ 'show_in_menu' => true,
55
+ 'menu_position' => 26,
56
+ 'menu_icon' => 'dashicons-desktop',
57
+ 'show_in_admin_bar' => true,
58
+ 'show_in_nav_menus' => true,
59
+ 'can_export' => true,
60
+ 'has_archive' => true,
61
+ 'exclude_from_search' => false,
62
+ 'publicly_queryable' => true,
63
+ 'capability_type' => 'page',
64
+ 'rewrite' => array( 'slug' => $slug ),
65
+ );
66
+ register_post_type( 'projects', $args );
67
+
68
+ }
69
+ add_action( 'init', 'sydney_toolbox_register_projects', 0 );
inc/post-type-services.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Services custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Services custom post type
14
+ function sydney_toolbox_register_services() {
15
+
16
+ $slug = apply_filters( 'sydney_services_rewrite_slug', 'services' );
17
+
18
+ $labels = array(
19
+ 'name' => _x( 'Services', 'Post Type General Name', 'sydney_toolbox' ),
20
+ 'singular_name' => _x( 'Service', 'Post Type Singular Name', 'sydney_toolbox' ),
21
+ 'menu_name' => __( 'Services', 'sydney_toolbox' ),
22
+ 'name_admin_bar' => __( 'Services', 'sydney_toolbox' ),
23
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
24
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
25
+ 'all_items' => __( 'All Services', 'sydney_toolbox' ),
26
+ 'add_new_item' => __( 'Add New Service', 'sydney_toolbox' ),
27
+ 'add_new' => __( 'Add New Service', 'sydney_toolbox' ),
28
+ 'new_item' => __( 'New Service', 'sydney_toolbox' ),
29
+ 'edit_item' => __( 'Edit Service', 'sydney_toolbox' ),
30
+ 'update_item' => __( 'Update Service', 'sydney_toolbox' ),
31
+ 'view_item' => __( 'View Service', 'sydney_toolbox' ),
32
+ 'search_items' => __( 'Search Service', 'sydney_toolbox' ),
33
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
34
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
35
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
36
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
37
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
38
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
39
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
40
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
41
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
42
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
43
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
44
+ );
45
+ $args = array(
46
+ 'label' => __( 'Service', 'sydney_toolbox' ),
47
+ 'description' => __( 'A post type for your services', 'sydney_toolbox' ),
48
+ 'labels' => $labels,
49
+ 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail' ),
50
+ 'taxonomies' => array( 'category' ),
51
+ 'hierarchical' => false,
52
+ 'public' => true,
53
+ 'show_ui' => true,
54
+ 'show_in_menu' => true,
55
+ 'menu_position' => 26,
56
+ 'menu_icon' => 'dashicons-portfolio',
57
+ 'show_in_admin_bar' => true,
58
+ 'show_in_nav_menus' => true,
59
+ 'can_export' => true,
60
+ 'has_archive' => true,
61
+ 'exclude_from_search' => false,
62
+ 'publicly_queryable' => true,
63
+ 'capability_type' => 'page',
64
+ 'rewrite' => array( 'slug' => $slug ),
65
+ );
66
+ register_post_type( 'services', $args );
67
+
68
+ }
69
+ add_action( 'init', 'sydney_toolbox_register_services', 0 );
inc/post-type-testimonials.php ADDED
@@ -0,0 +1,69 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Testimonials custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Testimonials custom post type
14
+ function sydney_toolbox_register_testimonials() {
15
+
16
+ $slug = apply_filters( 'sydney_testimonials_rewrite_slug', 'testimonials' );
17
+
18
+ $labels = array(
19
+ 'name' => _x( 'Testimonials', 'Post Type General Name', 'sydney_toolbox' ),
20
+ 'singular_name' => _x( 'Testimonial', 'Post Type Singular Name', 'sydney_toolbox' ),
21
+ 'menu_name' => __( 'Testimonials', 'sydney_toolbox' ),
22
+ 'name_admin_bar' => __( 'Testimonials', 'sydney_toolbox' ),
23
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
24
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
25
+ 'all_items' => __( 'All Testimonials', 'sydney_toolbox' ),
26
+ 'add_new_item' => __( 'Add New Testimonial', 'sydney_toolbox' ),
27
+ 'add_new' => __( 'Add New Testimonial', 'sydney_toolbox' ),
28
+ 'new_item' => __( 'New Testimonial', 'sydney_toolbox' ),
29
+ 'edit_item' => __( 'Edit Testimonial', 'sydney_toolbox' ),
30
+ 'update_item' => __( 'Update Testimonial', 'sydney_toolbox' ),
31
+ 'view_item' => __( 'View Testimonial', 'sydney_toolbox' ),
32
+ 'search_items' => __( 'Search Testimonial', 'sydney_toolbox' ),
33
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
34
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
35
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
36
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
37
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
38
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
39
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
40
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
41
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
42
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
43
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
44
+ );
45
+ $args = array(
46
+ 'label' => __( 'Testimonial', 'sydney_toolbox' ),
47
+ 'description' => __( 'A post type for your testimonials', 'sydney_toolbox' ),
48
+ 'labels' => $labels,
49
+ 'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail' ),
50
+ 'taxonomies' => array( 'category' ),
51
+ 'hierarchical' => false,
52
+ 'public' => true,
53
+ 'show_ui' => true,
54
+ 'show_in_menu' => true,
55
+ 'menu_position' => 26,
56
+ 'menu_icon' => 'dashicons-heart',
57
+ 'show_in_admin_bar' => true,
58
+ 'show_in_nav_menus' => true,
59
+ 'can_export' => true,
60
+ 'has_archive' => true,
61
+ 'exclude_from_search' => false,
62
+ 'publicly_queryable' => true,
63
+ 'capability_type' => 'page',
64
+ 'rewrite' => array( 'slug' => $slug ),
65
+ );
66
+ register_post_type( 'testimonials', $args );
67
+
68
+ }
69
+ add_action( 'init', 'sydney_toolbox_register_testimonials', 0 );
inc/post-type-timeline.php ADDED
@@ -0,0 +1,74 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * This file registers the Timeline Events custom post type
5
+ *
6
+ * @package Sydney_Toolbox
7
+ * @link http://athemes.com
8
+ * Author: aThemes
9
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
10
+ */
11
+
12
+
13
+ // Register the Timeline Events custom post type
14
+ function sydney_toolbox_register_timeline_events() {
15
+
16
+ $slug = apply_filters( 'sydney_timeline_events_rewrite_slug', 'timeline-events' );
17
+
18
+ $theme = wp_get_theme();
19
+ $parent = wp_get_theme()->parent();
20
+ if ( ($theme != 'Sydney Pro' ) && ($parent != 'Sydney Pro') )
21
+ return;
22
+
23
+ $labels = array(
24
+ 'name' => _x( 'Timeline Events', 'Post Type General Name', 'sydney_toolbox' ),
25
+ 'singular_name' => _x( 'Event', 'Post Type Singular Name', 'sydney_toolbox' ),
26
+ 'menu_name' => __( 'Timeline Events', 'sydney_toolbox' ),
27
+ 'name_admin_bar' => __( 'Timeline Events', 'sydney_toolbox' ),
28
+ 'archives' => __( 'Item Archives', 'sydney_toolbox' ),
29
+ 'parent_item_colon' => __( 'Parent Item:', 'sydney_toolbox' ),
30
+ 'all_items' => __( 'All Timeline Events', 'sydney_toolbox' ),
31
+ 'add_new_item' => __( 'Add New Event', 'sydney_toolbox' ),
32
+ 'add_new' => __( 'Add New Event', 'sydney_toolbox' ),
33
+ 'new_item' => __( 'New Event', 'sydney_toolbox' ),
34
+ 'edit_item' => __( 'Edit Event', 'sydney_toolbox' ),
35
+ 'update_item' => __( 'Update Event', 'sydney_toolbox' ),
36
+ 'view_item' => __( 'View Event', 'sydney_toolbox' ),
37
+ 'search_items' => __( 'Search Event', 'sydney_toolbox' ),
38
+ 'not_found' => __( 'Not found', 'sydney_toolbox' ),
39
+ 'not_found_in_trash' => __( 'Not found in Trash', 'sydney_toolbox' ),
40
+ 'featured_image' => __( 'Featured Image', 'sydney_toolbox' ),
41
+ 'set_featured_image' => __( 'Set featured image', 'sydney_toolbox' ),
42
+ 'remove_featured_image' => __( 'Remove featured image', 'sydney_toolbox' ),
43
+ 'use_featured_image' => __( 'Use as featured image', 'sydney_toolbox' ),
44
+ 'insert_into_item' => __( 'Insert into item', 'sydney_toolbox' ),
45
+ 'uploaded_to_this_item' => __( 'Uploaded to this item', 'sydney_toolbox' ),
46
+ 'items_list' => __( 'Items list', 'sydney_toolbox' ),
47
+ 'items_list_navigation' => __( 'Items list navigation', 'sydney_toolbox' ),
48
+ 'filter_items_list' => __( 'Filter items list', 'sydney_toolbox' ),
49
+ );
50
+ $args = array(
51
+ 'label' => __( 'Event', 'sydney_toolbox' ),
52
+ 'description' => __( 'A post type for your timeline events', 'sydney_toolbox' ),
53
+ 'labels' => $labels,
54
+ 'supports' => array( 'title', 'editor', 'excerpt', ),
55
+ 'taxonomies' => array( 'category' ),
56
+ 'hierarchical' => false,
57
+ 'public' => true,
58
+ 'show_ui' => true,
59
+ 'show_in_menu' => true,
60
+ 'menu_position' => 26,
61
+ 'menu_icon' => 'dashicons-layout',
62
+ 'show_in_admin_bar' => true,
63
+ 'show_in_nav_menus' => true,
64
+ 'can_export' => true,
65
+ 'has_archive' => true,
66
+ 'exclude_from_search' => false,
67
+ 'publicly_queryable' => true,
68
+ 'capability_type' => 'page',
69
+ 'rewrite' => array( 'slug' => $slug ),
70
+ );
71
+ register_post_type( 'timeline-events', $args );
72
+
73
+ }
74
+ add_action( 'init', 'sydney_toolbox_register_timeline_events', 0 );
index.php ADDED
@@ -0,0 +1 @@
 
1
+ <?php // Silence is golden
languages/sydney-toolbox.pot ADDED
@@ -0,0 +1,548 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ msgid ""
2
+ msgstr ""
3
+ "Project-Id-Version: Sydney Toolbox\n"
4
+ "POT-Creation-Date: 2016-03-14 11:56+0200\n"
5
+ "PO-Revision-Date: 2016-03-14 11:56+0200\n"
6
+ "Last-Translator: \n"
7
+ "Language-Team: \n"
8
+ "Language: en_US\n"
9
+ "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=UTF-8\n"
11
+ "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 1.6.3\n"
13
+ "X-Poedit-Basepath: .\n"
14
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
+ "X-Poedit-KeywordsList: __;_e\n"
16
+ "X-Poedit-SearchPath-0: D:\\wamp\\www\\wordpress\\wp-content\\plugins\\sydney-"
17
+ "toolbox\n"
18
+
19
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/sydney-toolbox.php:97
20
+ msgid ""
21
+ "Please note that the <strong>Sydney Toolbox</strong> plugin is meant to be "
22
+ "used only with the <a href=\"http://wordpress.org/themes/sydney/\" target="
23
+ "\"_blank\">Sydney theme</a></p>"
24
+ msgstr ""
25
+
26
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:19
27
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:20
28
+ msgid "Clients"
29
+ msgstr ""
30
+
31
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:21
32
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:21
33
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:21
34
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:21
35
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:21
36
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:26
37
+ msgid "Item Archives"
38
+ msgstr ""
39
+
40
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:22
41
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:22
42
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:22
43
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:22
44
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:22
45
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:27
46
+ msgid "Parent Item:"
47
+ msgstr ""
48
+
49
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:23
50
+ msgid "All Clients"
51
+ msgstr ""
52
+
53
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:24
54
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:25
55
+ msgid "Add New Client"
56
+ msgstr ""
57
+
58
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:26
59
+ msgid "New Client"
60
+ msgstr ""
61
+
62
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:27
63
+ msgid "Edit Client"
64
+ msgstr ""
65
+
66
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:28
67
+ msgid "Update Client"
68
+ msgstr ""
69
+
70
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:29
71
+ msgid "View Client"
72
+ msgstr ""
73
+
74
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:30
75
+ msgid "Search Client"
76
+ msgstr ""
77
+
78
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:31
79
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:31
80
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:31
81
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:31
82
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:31
83
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:36
84
+ msgid "Not found"
85
+ msgstr ""
86
+
87
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:32
88
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:32
89
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:32
90
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:32
91
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:32
92
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:37
93
+ msgid "Not found in Trash"
94
+ msgstr ""
95
+
96
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:33
97
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:33
98
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:33
99
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:33
100
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:33
101
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:38
102
+ msgid "Featured Image"
103
+ msgstr ""
104
+
105
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:34
106
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:34
107
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:34
108
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:34
109
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:34
110
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:39
111
+ msgid "Set featured image"
112
+ msgstr ""
113
+
114
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:35
115
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:35
116
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:35
117
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:35
118
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:35
119
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:40
120
+ msgid "Remove featured image"
121
+ msgstr ""
122
+
123
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:36
124
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:36
125
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:36
126
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:36
127
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:36
128
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:41
129
+ msgid "Use as featured image"
130
+ msgstr ""
131
+
132
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:37
133
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:37
134
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:37
135
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:37
136
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:37
137
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:42
138
+ msgid "Insert into item"
139
+ msgstr ""
140
+
141
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:38
142
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:38
143
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:38
144
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:38
145
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:38
146
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:43
147
+ msgid "Uploaded to this item"
148
+ msgstr ""
149
+
150
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:39
151
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:39
152
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:39
153
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:39
154
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:39
155
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:44
156
+ msgid "Items list"
157
+ msgstr ""
158
+
159
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:40
160
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:40
161
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:40
162
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:40
163
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:40
164
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:45
165
+ msgid "Items list navigation"
166
+ msgstr ""
167
+
168
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:41
169
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:41
170
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:41
171
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:41
172
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:41
173
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:46
174
+ msgid "Filter items list"
175
+ msgstr ""
176
+
177
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:44
178
+ msgid "Client"
179
+ msgstr ""
180
+
181
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-clients.php:45
182
+ msgid "A post type for your clients"
183
+ msgstr ""
184
+
185
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:19
186
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:20
187
+ msgid "Employees"
188
+ msgstr ""
189
+
190
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:23
191
+ msgid "All Employees"
192
+ msgstr ""
193
+
194
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:24
195
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:25
196
+ msgid "Add New Employee"
197
+ msgstr ""
198
+
199
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:26
200
+ msgid "New Employee"
201
+ msgstr ""
202
+
203
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:27
204
+ msgid "Edit Employee"
205
+ msgstr ""
206
+
207
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:28
208
+ msgid "Update Employee"
209
+ msgstr ""
210
+
211
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:29
212
+ msgid "View Employee"
213
+ msgstr ""
214
+
215
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:30
216
+ msgid "Search Employee"
217
+ msgstr ""
218
+
219
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:44
220
+ msgid "Employee"
221
+ msgstr ""
222
+
223
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-employees.php:45
224
+ msgid "A post type for your employees"
225
+ msgstr ""
226
+
227
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:19
228
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:20
229
+ msgid "Projects"
230
+ msgstr ""
231
+
232
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:23
233
+ msgid "All Projects"
234
+ msgstr ""
235
+
236
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:24
237
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:25
238
+ msgid "Add New Project"
239
+ msgstr ""
240
+
241
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:26
242
+ msgid "New Project"
243
+ msgstr ""
244
+
245
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:27
246
+ msgid "Edit Project"
247
+ msgstr ""
248
+
249
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:28
250
+ msgid "Update Project"
251
+ msgstr ""
252
+
253
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:29
254
+ msgid "View Project"
255
+ msgstr ""
256
+
257
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:30
258
+ msgid "Search Project"
259
+ msgstr ""
260
+
261
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:44
262
+ msgid "Project"
263
+ msgstr ""
264
+
265
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-projects.php:45
266
+ msgid "A post type for your projects"
267
+ msgstr ""
268
+
269
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:19
270
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:20
271
+ msgid "Services"
272
+ msgstr ""
273
+
274
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:23
275
+ msgid "All Services"
276
+ msgstr ""
277
+
278
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:24
279
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:25
280
+ msgid "Add New Service"
281
+ msgstr ""
282
+
283
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:26
284
+ msgid "New Service"
285
+ msgstr ""
286
+
287
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:27
288
+ msgid "Edit Service"
289
+ msgstr ""
290
+
291
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:28
292
+ msgid "Update Service"
293
+ msgstr ""
294
+
295
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:29
296
+ msgid "View Service"
297
+ msgstr ""
298
+
299
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:30
300
+ msgid "Search Service"
301
+ msgstr ""
302
+
303
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:44
304
+ msgid "Service"
305
+ msgstr ""
306
+
307
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-services.php:45
308
+ msgid "A post type for your services"
309
+ msgstr ""
310
+
311
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:19
312
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:20
313
+ msgid "Testimonials"
314
+ msgstr ""
315
+
316
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:23
317
+ msgid "All Testimonials"
318
+ msgstr ""
319
+
320
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:24
321
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:25
322
+ msgid "Add New Testimonial"
323
+ msgstr ""
324
+
325
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:26
326
+ msgid "New Testimonial"
327
+ msgstr ""
328
+
329
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:27
330
+ msgid "Edit Testimonial"
331
+ msgstr ""
332
+
333
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:28
334
+ msgid "Update Testimonial"
335
+ msgstr ""
336
+
337
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:29
338
+ msgid "View Testimonial"
339
+ msgstr ""
340
+
341
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:30
342
+ msgid "Search Testimonial"
343
+ msgstr ""
344
+
345
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:44
346
+ msgid "Testimonial"
347
+ msgstr ""
348
+
349
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-testimonials.php:45
350
+ msgid "A post type for your testimonials"
351
+ msgstr ""
352
+
353
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:24
354
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:25
355
+ msgid "Timeline Events"
356
+ msgstr ""
357
+
358
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:28
359
+ msgid "All Timeline Events"
360
+ msgstr ""
361
+
362
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:29
363
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:30
364
+ msgid "Add New Event"
365
+ msgstr ""
366
+
367
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:31
368
+ msgid "New Event"
369
+ msgstr ""
370
+
371
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:32
372
+ msgid "Edit Event"
373
+ msgstr ""
374
+
375
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:33
376
+ msgid "Update Event"
377
+ msgstr ""
378
+
379
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:34
380
+ msgid "View Event"
381
+ msgstr ""
382
+
383
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:35
384
+ msgid "Search Event"
385
+ msgstr ""
386
+
387
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:49
388
+ msgid "Event"
389
+ msgstr ""
390
+
391
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/post-type-timeline.php:50
392
+ msgid "A post type for your timeline events"
393
+ msgstr ""
394
+
395
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/clients-metabox.php:33
396
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/testimonials-metabox.php:33
397
+ msgid "Client info"
398
+ msgstr ""
399
+
400
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/clients-metabox.php:76
401
+ msgid "Client link"
402
+ msgstr ""
403
+
404
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/clients-metabox.php:77
405
+ msgid "Add a link for the client's website here [optional]"
406
+ msgstr ""
407
+
408
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:33
409
+ msgid "Employee info"
410
+ msgstr ""
411
+
412
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:89
413
+ msgid "Employee position"
414
+ msgstr ""
415
+
416
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:91
417
+ msgid "Employee Facebook"
418
+ msgstr ""
419
+
420
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:93
421
+ msgid "Employee Twitter"
422
+ msgstr ""
423
+
424
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:95
425
+ msgid "Employee Google"
426
+ msgstr ""
427
+
428
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:97
429
+ msgid "Employee Link"
430
+ msgstr ""
431
+
432
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/employees-metabox.php:98
433
+ msgid "Add a link here if you want the employee name to link somewhere."
434
+ msgstr ""
435
+
436
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/projects-metabox.php:33
437
+ msgid "Project info"
438
+ msgstr ""
439
+
440
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/projects-metabox.php:76
441
+ msgid "Project link"
442
+ msgstr ""
443
+
444
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/projects-metabox.php:77
445
+ msgid ""
446
+ "Add an URL here to make this project link to another page (internal or "
447
+ "external). Leave it empty and it will default to its own page."
448
+ msgstr ""
449
+
450
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/services-metabox.php:33
451
+ msgid "Service info"
452
+ msgstr ""
453
+
454
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/services-metabox.php:77
455
+ msgid "Service icon"
456
+ msgstr ""
457
+
458
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/services-metabox.php:78
459
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:90
460
+ msgid ""
461
+ "Example: <strong>fa-android</strong>. Full list of icons is <a href=\"http://"
462
+ "fortawesome.github.io/Font-Awesome/cheatsheet/\" target=\"_blank\">here</a>"
463
+ msgstr ""
464
+
465
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/services-metabox.php:80
466
+ msgid "Service link"
467
+ msgstr ""
468
+
469
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/services-metabox.php:81
470
+ msgid ""
471
+ "You can link your service to a page of your choice by entering the URL in "
472
+ "this field"
473
+ msgstr ""
474
+
475
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:36
476
+ msgid "Post/page options"
477
+ msgstr ""
478
+
479
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:89
480
+ msgid "Here you can control the options just for this page/post."
481
+ msgstr ""
482
+
483
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:91
484
+ msgid "Background image URL"
485
+ msgstr ""
486
+
487
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:92
488
+ msgid ""
489
+ "If you want to use this option, make sure you leave the next background "
490
+ "color option empty."
491
+ msgstr ""
492
+
493
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:94
494
+ msgid "Background color"
495
+ msgstr ""
496
+
497
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:97
498
+ msgid "Check this box to hide the title"
499
+ msgstr ""
500
+
501
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:98
502
+ msgid "Content wrapper opacity"
503
+ msgstr ""
504
+
505
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/singles-metabox.php:99
506
+ msgid ""
507
+ "Enter a value for the opacity of the white content background. Values from 0 "
508
+ "to 1 (example 0.4)"
509
+ msgstr ""
510
+
511
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/testimonials-metabox.php:78
512
+ msgid "Client function/Company name"
513
+ msgstr ""
514
+
515
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/testimonials-metabox.php:79
516
+ msgid "Enter your client's function/company name"
517
+ msgstr ""
518
+
519
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:34
520
+ msgid "Timeline info"
521
+ msgstr ""
522
+
523
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:86
524
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:89
525
+ msgid "Event icon"
526
+ msgstr ""
527
+
528
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:87
529
+ msgid "Add the date when this timeline event happened."
530
+ msgstr ""
531
+
532
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:92
533
+ msgid "Event color"
534
+ msgstr ""
535
+
536
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:93
537
+ msgid "Select a color for the event icon."
538
+ msgstr ""
539
+
540
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:95
541
+ msgid "Event link"
542
+ msgstr ""
543
+
544
+ #: D:\wamp\www\wordpress\wp-content\plugins\sydney-toolbox/inc/metaboxes/timeline-metabox.php:96
545
+ msgid ""
546
+ "You can link your event to a page of your choice by entering the URL in this "
547
+ "field"
548
+ msgstr ""
sydney-toolbox.php ADDED
@@ -0,0 +1,112 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ *
5
+ * @link http://athemes.com
6
+ * @since 1.0.0
7
+ * @package Sydney_Toolbox
8
+ *
9
+ * @wordpress-plugin
10
+ * Plugin Name: Sydney Toolbox
11
+ * Plugin URI: http://athemes.com/plugins/sydney-toolbox
12
+ * Description: Registers custom post types and custom fields for the Sydney theme
13
+ * Version: 1.0
14
+ * Author: aThemes
15
+ * Author URI: http://athemes.com
16
+ * License: GPL-2.0+
17
+ * License URI: http://www.gnu.org/licenses/gpl-2.0.txt
18
+ * Text Domain: sydney-toolbox
19
+ * Domain Path: /languages
20
+ */
21
+
22
+ // If this file is called directly, abort.
23
+ if ( ! defined( 'WPINC' ) ) {
24
+ die;
25
+ }
26
+
27
+ /**
28
+ * Set up and initialize
29
+ */
30
+ class Sydney_Toolbox {
31
+
32
+ private static $instance;
33
+
34
+ /**
35
+ * Actions setup
36
+ */
37
+ public function __construct() {
38
+
39
+ add_action( 'plugins_loaded', array( $this, 'constants' ), 2 );
40
+ add_action( 'plugins_loaded', array( $this, 'i18n' ), 3 );
41
+ add_action( 'plugins_loaded', array( $this, 'includes' ), 4 );
42
+ add_action( 'admin_notices', array( $this, 'admin_notice' ), 4 );
43
+ }
44
+
45
+ /**
46
+ * Constants
47
+ */
48
+ function constants() {
49
+
50
+ define( 'ST_DIR', trailingslashit( plugin_dir_path( __FILE__ ) ) );
51
+ define( 'ST_URI', trailingslashit( plugin_dir_url( __FILE__ ) ) );
52
+ }
53
+
54
+ /**
55
+ * Includes
56
+ */
57
+ function includes() {
58
+
59
+ //Post types
60
+ require_once( ST_DIR . 'inc/post-type-services.php' );
61
+ require_once( ST_DIR . 'inc/post-type-employees.php' );
62
+ require_once( ST_DIR . 'inc/post-type-testimonials.php' );
63
+ require_once( ST_DIR . 'inc/post-type-clients.php' );
64
+ require_once( ST_DIR . 'inc/post-type-projects.php' );
65
+ require_once( ST_DIR . 'inc/post-type-timeline.php' );
66
+ //Metaboxes
67
+ require_once( ST_DIR . 'inc/metaboxes/services-metabox.php' );
68
+ require_once( ST_DIR . 'inc/metaboxes/employees-metabox.php' );
69
+ require_once( ST_DIR . 'inc/metaboxes/testimonials-metabox.php' );
70
+ require_once( ST_DIR . 'inc/metaboxes/clients-metabox.php' );
71
+ require_once( ST_DIR . 'inc/metaboxes/projects-metabox.php' );
72
+ require_once( ST_DIR . 'inc/metaboxes/timeline-metabox.php' );
73
+ require_once( ST_DIR . 'inc/metaboxes/singles-metabox.php' );
74
+ }
75
+
76
+ /**
77
+ * Translations
78
+ */
79
+ function i18n() {
80
+ load_plugin_textdomain( 'sydney-toolbox', false, 'sydney-toolbox/languages' );
81
+ }
82
+
83
+ /**
84
+ * Admin notice
85
+ */
86
+ function admin_notice() {
87
+ $theme = wp_get_theme();
88
+ $parent = wp_get_theme()->parent();
89
+ if ( ($theme != 'Sydney' ) && ($theme != 'Sydney Pro' ) && ($parent != 'Sydney') && ($parent != 'Sydney Pro') ) {
90
+ echo '<div class="error">';
91
+ echo '<p>' . __('Please note that the <strong>Sydney Toolbox</strong> plugin is meant to be used only with the <a href="http://wordpress.org/themes/sydney/" target="_blank">Sydney theme</a></p>', 'sydney-toolbox');
92
+ echo '</div>';
93
+ }
94
+ }
95
+
96
+ /**
97
+ * Returns the instance.
98
+ */
99
+ public static function get_instance() {
100
+
101
+ if ( !self::$instance )
102
+ self::$instance = new self;
103
+
104
+ return self::$instance;
105
+ }
106
+ }
107
+
108
+ function sydney_toolbox_plugin() {
109
+ if ( !function_exists('wpcf_init') ) //Make sure the Types plugin isn't active
110
+ return Sydney_Toolbox::get_instance();
111
+ }
112
+ add_action('plugins_loaded', 'sydney_toolbox_plugin', 1);