WP Job Manager - Version 1.0.0

Version Description

  • First stable release.
Download this release

Release Info

Developer mikejolley
Plugin Icon 128x128 WP Job Manager
Version 1.0.0
Comparing to
See all releases

Version 1.0.0

Files changed (68) hide show
  1. assets/css/admin.css +1 -0
  2. assets/css/admin.less +209 -0
  3. assets/css/frontend.css +1 -0
  4. assets/css/frontend.less +728 -0
  5. assets/css/menu.css +1 -0
  6. assets/css/menu.less +41 -0
  7. assets/css/mixins.less +92 -0
  8. assets/font/genericons-regular-webfont.eot +0 -0
  9. assets/font/genericons-regular-webfont.svg +95 -0
  10. assets/font/genericons-regular-webfont.ttf +0 -0
  11. assets/font/genericons-regular-webfont.woff +0 -0
  12. assets/images/ajax-loader.gif +0 -0
  13. assets/images/briefcase-menu.png +0 -0
  14. assets/images/briefcase.png +0 -0
  15. assets/images/company.png +0 -0
  16. assets/images/featured_head.png +0 -0
  17. assets/images/icons/approve.png +0 -0
  18. assets/images/icons/delete.png +0 -0
  19. assets/images/icons/edit.png +0 -0
  20. assets/images/icons/view.png +0 -0
  21. assets/images/on.png +0 -0
  22. assets/js/admin.js +9 -0
  23. assets/js/admin.min.js +1 -0
  24. assets/js/ajax-filters.js +127 -0
  25. assets/js/ajax-filters.min.js +1 -0
  26. assets/js/job-application.js +24 -0
  27. assets/js/job-application.min.js +1 -0
  28. assets/js/job-dashboard.js +12 -0
  29. assets/js/job-dashboard.min.js +1 -0
  30. assets/js/jquery-tiptip/jquery.tipTip.js +191 -0
  31. assets/js/jquery-tiptip/jquery.tipTip.min.js +20 -0
  32. includes/abstracts/abstract-wp-job-manager-form.php +70 -0
  33. includes/admin/class-wp-job-manager-admin.php +63 -0
  34. includes/admin/class-wp-job-manager-category-walker.php +48 -0
  35. includes/admin/class-wp-job-manager-cpt.php +387 -0
  36. includes/admin/class-wp-job-manager-settings.php +226 -0
  37. includes/admin/class-wp-job-manager-writepanels.php +238 -0
  38. includes/class-wp-job-manager-ajax.php +185 -0
  39. includes/class-wp-job-manager-api.php +78 -0
  40. includes/class-wp-job-manager-forms.php +70 -0
  41. includes/class-wp-job-manager-install.php +79 -0
  42. includes/class-wp-job-manager-post-types.php +329 -0
  43. includes/class-wp-job-manager-shortcodes.php +324 -0
  44. includes/class-wp-job-manager-widgets.php +232 -0
  45. includes/forms/class-wp-job-manager-form-edit-job.php +110 -0
  46. includes/forms/class-wp-job-manager-form-submit-job.php +546 -0
  47. languages/job_manager-pt_PT.mo +0 -0
  48. languages/job_manager-pt_PT.po +813 -0
  49. languages/job_manager.pot +800 -0
  50. readme.txt +76 -0
  51. templates/account-signin.php +45 -0
  52. templates/content-job_listing.php +19 -0
  53. templates/content-single-job_listing.php +37 -0
  54. templates/content-summary-job_listing.php +17 -0
  55. templates/content-widget-job_listing.php +12 -0
  56. templates/form-fields/file-field.php +11 -0
  57. templates/form-fields/job-description-field.php +14 -0
  58. templates/form-fields/select-field.php +5 -0
  59. templates/form-fields/text-field.php +2 -0
  60. templates/job-application.php +34 -0
  61. templates/job-dashboard.php +64 -0
  62. templates/job-filters.php +49 -0
  63. templates/job-submit.php +61 -0
  64. templates/job-submitted.php +12 -0
  65. uninstall.php +3 -0
  66. wp-job-manager-functions.php +148 -0
  67. wp-job-manager-template.php +495 -0
  68. wp-job-manager.php +96 -0
assets/css/admin.css ADDED
@@ -0,0 +1 @@
 
1
+ .clearfix{zoom:1}.clearfix:before,.clearfix:after{content:"";display:table}.clearfix:after{clear:both}.clear{clear:both}.nobr{white-space:nowrap}.widefat .column-filled{text-align:center}.widefat .column-company{width:25%}.widefat td.column-company{padding-left:50px!important;height:40px;position:relative}.widefat td.column-company img{width:32px;height:32px;position:absolute;left:7px;top:4px;-webkit-border-radius:50%;border-radius:50%;box-shadow:0 1px 0 1px rgba(0,0,0,0.1);-webkit-box-shadow:0 1px 0 1px rgba(0,0,0,0.1);-moz-box-shadow:0 1px 0 1px rgba(0,0,0,0.1);border:1px solid #fff}.widefat td.column-company strong{display:block;margin-bottom:.2em}.widefat td.column-company .tagline{display:block;padding-top:2px;color:#bbb}.widefat td.column-company a.company_twitter{float:right;margin-left:1em}.widefat .column-job_posted strong{display:block;margin-bottom:.2em}.widefat .column-job_posted span{display:block;padding-top:2px}.widefat .column-job_listing_type{text-align:center;width:6em;word-wrap:normal!important}.widefat .column-job_listing_type .job-type{color:#fff;padding:4px 0 3px;line-height:1em;font-size:11px;font-weight:bold;-webkit-border-radius:2px;border-radius:2px;text-shadow:0 1px 0 rgba(0,0,0,0.2);display:block;background-color:#f08d3c;border-bottom:2px solid #e77212}.widefat .column-job_listing_type .full-time{background-color:#90da36;border-bottom:2px solid #76bb22}.widefat .column-job_listing_type .part-time{background-color:#f08d3c;border-bottom:2px solid #e77212}.widefat .column-job_listing_type .temporary{background-color:#d93674;border-bottom:2px solid #b9235c}.widefat .column-job_listing_type .freelance{background-color:#39c;border-bottom:2px solid #297aa3}.widefat .column-job_listing_type .internship{background-color:#6033cc;border-bottom:2px solid #4d29a3}.widefat .column-position{width:20%}.widefat .column-position strong{display:block;margin-bottom:.2em}.widefat .column-position .location{display:block;padding-top:2px;color:#bbb}.widefat .column-job_actions{width:120px;text-align:right}.widefat .column-job_actions a.button{display:inline-block;margin:0 0 2px 4px;cursor:pointer;padding:3px 4px;height:auto}.widefat .column-job_actions a.button img{display:block;width:12px;height:auto}.wp_job_manager_meta_data p{overflow:hidden;margin:0 0 1em;padding:0 0 0 20%;position:relative;line-height:2em}.wp_job_manager_meta_data label{width:20%;position:absolute;left:0;vertical-align:middle}.wp_job_manager_meta_data input{width:50%;margin:1px 0;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;vertical-align:middle}.wp_job_manager_meta_data input.checkbox{width:auto;margin:4px 2px}#tiptip_holder{display:none;position:absolute;top:0;left:0;z-index:99999}#tiptip_holder.tip_top{padding-bottom:5px}#tiptip_holder.tip_bottom{padding-top:5px}#tiptip_holder.tip_right{padding-left:5px}#tiptip_holder.tip_left{padding-right:5px}#tiptip_content{font-size:11px;color:#fff;padding:4px 8px;background:#464646;border-radius:3px;-webkit-border-radius:3px;-moz-border-radius:3px;box-shadow:1px 1px 3px rgba(0,0,0,0.1);-webkit-box-shadow:1px 1px 3px rgba(0,0,0,0.1);-moz-box-shadow:1px 1px 3px rgba(0,0,0,0.1);text-align:center}#tiptip_content code{background:#999;padding:1px}#tiptip_arrow,#tiptip_arrow_inner{position:absolute;border-color:transparent;border-style:solid;border-width:6px;height:0;width:0}#tiptip_holder.tip_top #tiptip_arrow_inner{margin-top:-7px;margin-left:-6px;border-top-color:#464646}#tiptip_holder.tip_bottom #tiptip_arrow_inner{margin-top:-5px;margin-left:-6px;border-bottom-color:#464646}#tiptip_holder.tip_right #tiptip_arrow_inner{margin-top:-6px;margin-left:-5px;border-right-color:#464646}#tiptip_holder.tip_left #tiptip_arrow_inner{margin-top:-6px;margin-left:-7px;border-left-color:#464646}
assets/css/admin.less ADDED
@@ -0,0 +1,209 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @import "mixins";
2
+
3
+ .widefat {
4
+ .column-filled {
5
+ text-align: center;
6
+ }
7
+ .column-company {
8
+ width: 25%;
9
+ }
10
+ td.column-company {
11
+ padding-left: 50px !important;
12
+ height: 40px;
13
+ position: relative;
14
+ img {
15
+ width: 32px;
16
+ height: 32px;
17
+ position: absolute;
18
+ left: 7px;
19
+ top: 4px;
20
+ .border_radius( 50% );
21
+ .box_shadow( 0, 1px, 0, 1px, rgba( 0,0,0,0.1 ) );
22
+ border: 1px solid #fff;
23
+ }
24
+ strong {
25
+ display: block;
26
+ margin-bottom: .2em;
27
+ }
28
+ .tagline {
29
+ display: block;
30
+ padding-top: 2px;
31
+ color: #bbbbbb;
32
+ }
33
+ a.company_twitter {
34
+ float: right;
35
+ margin-left: 1em;
36
+ }
37
+ }
38
+ .column-job_posted {
39
+ strong {
40
+ display: block;
41
+ margin-bottom: .2em;
42
+ }
43
+ span {
44
+ display: block;
45
+ padding-top: 2px
46
+ }
47
+ }
48
+ .column-job_listing_type {
49
+ text-align: center;
50
+ width: 6em;
51
+ word-wrap: normal !important;
52
+ .job-type {
53
+ color: #fff;
54
+ padding: 4px 0 3px;
55
+ line-height: 1em;
56
+ font-size: 11px;
57
+ font-weight: bold;
58
+ .border_radius( 2px );
59
+ text-shadow: 0 1px 0 rgba( 0, 0, 0, 0.2 );
60
+ display:block;
61
+ background-color: @part-time;
62
+ border-bottom: 2px solid darken( @part-time, 10% );
63
+ }
64
+ .full-time {
65
+ background-color: @full-time;
66
+ border-bottom: 2px solid darken( @full-time, 10% );
67
+ }
68
+ .part-time {
69
+ background-color: @part-time;
70
+ border-bottom: 2px solid darken( @part-time, 10% );
71
+ }
72
+ .temporary {
73
+ background-color: @temporary;
74
+ border-bottom: 2px solid darken( @temporary, 10% );
75
+ }
76
+ .freelance {
77
+ background-color: @freelance;
78
+ border-bottom: 2px solid darken( @freelance, 10% );
79
+ }
80
+ .internship {
81
+ background-color: @internship;
82
+ border-bottom: 2px solid darken( @internship, 10% );
83
+ }
84
+ }
85
+ .column-position {
86
+ width: 20%;
87
+ strong {
88
+ display: block;
89
+ margin-bottom: .2em;
90
+ }
91
+ .location {
92
+ display: block;
93
+ padding-top: 2px;
94
+ color: #bbbbbb;
95
+ }
96
+ }
97
+ .column-job_actions {
98
+ width:120px;
99
+ text-align: right;
100
+ a.button {
101
+ display: inline-block;
102
+ margin: 0 0 2px 4px;
103
+ cursor: pointer;
104
+ padding:3px 4px;
105
+ height:auto;
106
+ img {
107
+ display: block;
108
+ width:12px;
109
+ height:auto;
110
+ }
111
+ }
112
+ }
113
+ }
114
+ .wp_job_manager_meta_data {
115
+ p {
116
+ overflow: hidden;
117
+ margin: 0 0 1em;
118
+ padding: 0 0 0 20%;
119
+ position: relative;
120
+ line-height: 2em;
121
+ }
122
+ label {
123
+ width: 20%;
124
+ position: absolute;
125
+ left: 0;
126
+ vertical-align: middle;
127
+ }
128
+ input {
129
+ width: 50%;
130
+ margin: 1px 0;
131
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
132
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
133
+ box-sizing: border-box; /* Opera/IE 8+ */
134
+ vertical-align: middle;
135
+ }
136
+ input.checkbox {
137
+ width: auto;
138
+ margin: 4px 2px;
139
+ }
140
+ }
141
+
142
+ /* TipTip CSS - Version 1.2 */
143
+ #tiptip_holder {
144
+ display: none;
145
+ position: absolute;
146
+ top: 0;
147
+ left: 0;
148
+ z-index: 99999;
149
+ }
150
+ #tiptip_holder.tip_top {
151
+ padding-bottom: 5px;
152
+ }
153
+ #tiptip_holder.tip_bottom {
154
+ padding-top: 5px;
155
+ }
156
+ #tiptip_holder.tip_right {
157
+ padding-left: 5px;
158
+ }
159
+ #tiptip_holder.tip_left {
160
+ padding-right: 5px;
161
+ }
162
+ #tiptip_content {
163
+ font-size: 11px;
164
+ color: #fff;
165
+ padding: 4px 8px;
166
+ background:#464646;
167
+ border-radius: 3px;
168
+ -webkit-border-radius: 3px;
169
+ -moz-border-radius: 3px;
170
+ box-shadow: 1px 1px 3px rgba(0,0,0,0.10);
171
+ -webkit-box-shadow: 1px 1px 3px rgba(0,0,0,0.10);
172
+ -moz-box-shadow: 1px 1px 3px rgba(0,0,0,0.10);
173
+ text-align: center;
174
+ code {
175
+ background: #999;
176
+ padding: 1px;
177
+ }
178
+ }
179
+ #tiptip_arrow, #tiptip_arrow_inner {
180
+ position: absolute;
181
+ border-color: transparent;
182
+ border-style: solid;
183
+ border-width: 6px;
184
+ height: 0;
185
+ width: 0;
186
+ }
187
+ #tiptip_holder.tip_top #tiptip_arrow_inner {
188
+ margin-top: -7px;
189
+ margin-left: -6px;
190
+ border-top-color: #464646;
191
+ }
192
+
193
+ #tiptip_holder.tip_bottom #tiptip_arrow_inner {
194
+ margin-top: -5px;
195
+ margin-left: -6px;
196
+ border-bottom-color: #464646;
197
+ }
198
+
199
+ #tiptip_holder.tip_right #tiptip_arrow_inner {
200
+ margin-top: -6px;
201
+ margin-left: -5px;
202
+ border-right-color: #464646;
203
+ }
204
+
205
+ #tiptip_holder.tip_left #tiptip_arrow_inner {
206
+ margin-top: -6px;
207
+ margin-left: -7px;
208
+ border-left-color: #464646;
209
+ }
assets/css/frontend.css ADDED
@@ -0,0 +1 @@
 
1
+ .clearfix{zoom:1}.clearfix:before,.clearfix:after{content:"";display:table}.clearfix:after{clear:both}.clear{clear:both}.nobr{white-space:nowrap}@font-face{font-family:'Genericons';src:url('../font/genericons-regular-webfont.eot');src:url('../font/genericons-regular-webfont.eot?#iefix') format('embedded-opentype'),url('../font/genericons-regular-webfont.woff') format('woff'),url('../font/genericons-regular-webfont.ttf') format('truetype'),url('../font/genericons-regular-webfont.svg#genericonsregular') format('svg');font-weight:normal;font-style:normal}.display-icon{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline}.job-manager-message,.job-manager-error,.job-manager-info{padding:1em 1em 1em 3.5em;margin:0 0 2em;position:relative;-webkit-border-radius:4px;border-radius:4px;background:#fff;background:-webkit-gradient(linear,left top,left bottom,from(#fff),to(#fff));background:-webkit-linear-gradient(#fff,#fff);background:-moz-linear-gradient(center top,#fff 0,#fff 100%);background:-moz-gradient(center top,#fff 0,#fff 100%);color:#666;text-shadow:0 1px 0 #fff;list-style:none outside;zoom:1;width:auto;-webkit-box-shadow:inset 0 -2px 6px rgba(0,0,0,0.05),inset 0 -2px 30px rgba(0,0,0,0.015),inset 0 1px 0 #fff,0 1px 2px rgba(0,0,0,0.3);box-shadow:inset 0 -2px 6px rgba(0,0,0,0.05),inset 0 -2px 30px rgba(0,0,0,0.015),inset 0 1px 0 #fff,0 1px 2px rgba(0,0,0,0.3)}.job-manager-message:before,.job-manager-error:before,.job-manager-info:before,.job-manager-message:after,.job-manager-error:after,.job-manager-info:after{content:"";display:table}.job-manager-message:after,.job-manager-error:after,.job-manager-info:after{clear:both}.job-manager-message:before,.job-manager-error:before,.job-manager-info:before{content:"";height:1.5em;width:1.5em;display:block;position:absolute;top:0;left:1em;font-family:sans-serif;font-size:1em;line-height:1.5;text-align:center;color:#fff;text-shadow:0 1px 0 rgba(0,0,0,0.2);padding-top:1em;-webkit-border-bottom-left-radius:4px;-webkit-border-bottom-right-radius:4px;border-bottom-left-radius:4px;border-bottom-right-radius:4px;box-shadow:inset 0 -1px 0 0 rgba(0,0,0,0.1);-webkit-box-shadow:inset 0 -1px 0 0 rgba(0,0,0,0.1);-moz-box-shadow:inset 0 -1px 0 0 rgba(0,0,0,0.1)}.job-manager-message li,.job-manager-error li,.job-manager-info li{list-style:none outside;padding-left:0;margin-left:0}.job-manager-message.job-manager-message,.job-manager-error.job-manager-message,.job-manager-info.job-manager-message{border-top:3px solid #8fae1b}.job-manager-message.job-manager-message:before,.job-manager-error.job-manager-message:before,.job-manager-info.job-manager-message:before{background-color:#8fae1b;content:"\2713"}.job-manager-message.job-manager-info,.job-manager-error.job-manager-info,.job-manager-info.job-manager-info{border-top:3px solid #1e85be}.job-manager-message.job-manager-info:before,.job-manager-error.job-manager-info:before,.job-manager-info.job-manager-info:before{background-color:#1e85be;content:"i";font-family:Times,Georgia,serif;font-style:italic}.job-manager-message.job-manager-error,.job-manager-error.job-manager-error,.job-manager-info.job-manager-error{border-top:3px solid #b81c23}.job-manager-message.job-manager-error:before,.job-manager-error.job-manager-error:before,.job-manager-info.job-manager-error:before{background-color:#b81c23;content:"\00d7";font-weight:700}.job-manager-form fieldset{margin:0 0 1em 0;padding:0 0 1em 0;line-height:2em;border-bottom:1px solid #eee;overflow:hidden}.job-manager-form fieldset label{display:block;margin:0;width:29%;float:left;vertical-align:middle}.job-manager-form fieldset label small{opacity:.75;font-size:.83em}.job-manager-form fieldset div.field{width:70%;float:right;vertical-align:middle}.job-manager-form fieldset .account-sign-in .button{margin-right:.5em}.job-manager-form fieldset .account-sign-in .button:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f427'}.job-manager-form fieldset abbr.required{color:red;font-weight:bold;border:0}.job-manager-form fieldset input.input-text,.job-manager-form fieldset textarea,.job-manager-form fieldset select{margin:0;vertical-align:middle;width:100%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.job-manager-form fieldset small.description{opacity:.75;font-size:.83em;margin:1.2em 0 0 0;display:block;line-height:1.2em}.job-manager-form fieldset .uploaded_image{line-height:64px;font-style:italic;margin:0 0 1em 0}.job-manager-form fieldset .uploaded_image img{height:64px;vertical-align:middle;margin:0 1em 0 0}.job-manager-form .submit-job{padding:1em 0}ul.job_listings{padding:0;margin:0!important;border-top:1px solid #eee}ul.job_listings.loading{background:url(../images/ajax-loader.gif) no-repeat center}ul.job_listings li.job_listing,ul.job_listings li.no_job_listings_found{list-style:none outside;padding:0;margin:0;border-bottom:1px solid #eee}ul.job_listings li.job_listing.job_position_filled a,ul.job_listings li.no_job_listings_found.job_position_filled a{opacity:.25}ul.job_listings li.job_listing.no_job_listings_found,ul.job_listings li.no_job_listings_found.no_job_listings_found{padding:1em;border-bottom:1px solid #eee}ul.job_listings li.job_listing a,ul.job_listings li.no_job_listings_found a{display:block;padding:1em 1em 1em 2em;overflow:hidden;zoom:1;position:relative;line-height:3em;font-size:1em;text-decoration:none}ul.job_listings li.job_listing a:hover,ul.job_listings li.no_job_listings_found a:hover,ul.job_listings li.job_listing a:focus,ul.job_listings li.no_job_listings_found a:focus{background-color:#fcfcfc}ul.job_listings li.job_listing a img,ul.job_listings li.no_job_listings_found a img{width:42px;height:42px;position:absolute;left:1em;float:left;margin-right:1em;vertical-align:middle;box-shadow:none}ul.job_listings li.job_listing a div.position,ul.job_listings li.no_job_listings_found a div.position,ul.job_listings li.job_listing a div.location,ul.job_listings li.no_job_listings_found a div.location,ul.job_listings li.job_listing a ul.meta,ul.job_listings li.no_job_listings_found a ul.meta{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}ul.job_listings li.job_listing a div.position,ul.job_listings li.no_job_listings_found a div.position{float:left;width:60%;padding:0 0 0 42px;line-height:1.5em}ul.job_listings li.job_listing a div.position h3,ul.job_listings li.no_job_listings_found a div.position h3{margin:0;padding:0;font-size:1em;line-height:1.5em}ul.job_listings li.job_listing a div.position .company,ul.job_listings li.no_job_listings_found a div.position .company{color:#999;font-size:.75em}ul.job_listings li.job_listing a div.position .company .tagline,ul.job_listings li.no_job_listings_found a div.position .company .tagline{margin-left:.5em}ul.job_listings li.job_listing a div.location,ul.job_listings li.no_job_listings_found a div.location{float:left;text-align:left;width:20%;padding:0 0 0 1em;color:#999;font-size:.75em}ul.job_listings li.job_listing a .meta,ul.job_listings li.no_job_listings_found a .meta{float:right;text-align:right;width:20%;padding:0 0 0 1em;margin:0;line-height:1.5em;color:#999;list-style:none outside}ul.job_listings li.job_listing a .meta li,ul.job_listings li.no_job_listings_found a .meta li{list-style:none outside;display:block;font-size:.75em;margin:0}ul.job_listings li.job_listing a .meta .job-type,ul.job_listings li.no_job_listings_found a .meta .job-type{font-weight:bold}.widget ul.job_listings li.job_listing a{padding:1em 0}.widget ul.job_listings li.job_listing .position{float:none;width:auto;padding:0}.widget ul.job_listings li.job_listing ul.meta{float:none;width:auto;padding:0;margin:0;text-align:left}.widget ul.job_listings li.job_listing ul.meta li{float:none;display:inline;padding:0;margin:0 .5em 0 0;font-weight:normal}.widget ul.job_listings li.job_listing ul.meta li:after{padding:0 0 0 .5em;content:"\2023"}.widget ul.job_listings li.job_listing ul.meta li:last-child:after{content:''}.job-manager .full-time,.job_listing .full-time,.job-types .full-time{color:#90da36}.job-manager .part-time,.job_listing .part-time,.job-types .part-time{color:#f08d3c}.job-manager .temporary,.job_listing .temporary,.job-types .temporary{color:#d93674}.job-manager .freelance,.job_listing .freelance,.job-types .freelance{color:#39c}.job-manager .internship,.job_listing .internship,.job-types .internship{color:#6033cc}.single_job_listing .company{position:relative;border:1px solid #eee;padding:1em 1em 1em 42px;margin:0 0 2em;display:block;clear:both;min-height:42px}.single_job_listing .company img{width:42px;height:42px;position:absolute;left:1em;float:left;vertical-align:middle;box-shadow:none}.single_job_listing .company .name{margin:0;padding:0 0 0 2em}.single_job_listing .company .name a{float:right;margin-left:1em}.single_job_listing .company .tagline{display:block;margin:0;padding:0 0 0 2em;font-style:italic;color:#999}.single_job_listing .company .website:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f107'}.single_job_listing .company .company_twitter:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f202'}.single_job_listing .meta{list-style:none outside;padding:0;margin:0 0 1.5em;overflow:hidden;zoom:1}.single_job_listing .meta li{margin:0 1em 0 0;padding:.5em;float:left;line-height:1em;color:#999}.single_job_listing .meta .job-type{color:#fff;background-color:#f08d3c}.single_job_listing .meta .full-time{background-color:#90da36}.single_job_listing .meta .part-time{background-color:#f08d3c}.single_job_listing .meta .temporary{background-color:#d93674}.single_job_listing .meta .freelance{background-color:#39c}.single_job_listing .meta .internship{background-color:#6033cc}.single_job_listing .meta .position-filled{color:#b81c23}.single_job_listing .meta .location:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f417'}.single_job_listing .meta .date-posted:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f307'}.single_job_listing .meta .position-filled:before{display:inline-block;width:16px;height:16px;-webkit-font-smoothing:antialiased;font-family:'Genericons';text-decoration:none;font-weight:normal;font-style:normal;vertical-align:top;font-size:16px;margin:0 2px 0 0;*overflow:auto;*zoom:1;*display:inline;content:'\f424'}.single_job_listing .application{overflow:hidden;zoom:1;padding-left:20px;margin:0 0 1em}.single_job_listing .application .application_button,.single_job_listing .application .application_details{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.single_job_listing .application .application_button{text-align:center;font-size:1.2em;line-height:1em;width:33.3%;float:left;margin:0 0 0 -20px;padding:.8333333333333334em}.single_job_listing .application .application_details{float:right;width:66.6%;border:1px solid #eee;padding:.75em 1em 0;margin:0;line-height:1.5em;display:block;position:relative}.single_job_listing .application .application_details p{margin:0 0 .75em}.single_job_listing .application .application_details:before{content:"";position:absolute;margin:0 0 0 -10px;left:0;top:1em;width:0;height:0;border-top:10px solid transparent;border-bottom:10px solid transparent;border-right:10px solid #eee}.single_job_listing .application .application_details:after{content:"";position:absolute;margin:1px 0 0 -9px;top:1em;left:0;width:0;height:0;border-top:9px solid transparent;border-bottom:9px solid transparent;border-right:9px solid #fff}.job_filters{background:#eee;zoom:1}.job_filters:before,.job_filters:after{content:"";display:table}.job_filters:after{clear:both}.job_filters .search_jobs{padding:1em;zoom:1}.job_filters .search_jobs:before,.job_filters .search_jobs:after{content:"";display:table}.job_filters .search_jobs:after{clear:both}.job_filters .search_jobs div{width:50%;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.job_filters .search_jobs div label{display:none}.job_filters .search_jobs div.search_keywords{float:left;padding-right:.5em}.job_filters .search_jobs div.search_location{float:right;padding-left:.5em}.job_filters .search_jobs div.search_categories{padding-top:.5em;clear:both;width:100%}.job_filters .search_jobs input,.job_filters .search_jobs select{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;width:100%}.job_filters .job_types{list-style:none outside;margin:0;padding:0;font-size:.83em;background:#f9f9f9;border-top:1px solid #e5e5e5;zoom:1}.job_filters .job_types:before,.job_filters .job_types:after{content:"";display:table}.job_filters .job_types:after{clear:both}.job_filters .job_types li{margin:0;padding:.5em 1em;float:left;border-right:1px solid #eee}.job_filters .job_types li:last-child{border-right:0}.job_filters .showing_jobs{padding:.5em 1em;display:none;font-size:.83em;background:#f9f9f9;border-top:1px solid #e5e5e5}.job_filters .showing_jobs .reset,.job_filters .showing_jobs .rss_link{float:right}.job_filters .showing_jobs .rss_link{padding-right:10px}.load_more_jobs{text-align:center;display:block;padding:1em 1em 1em 2em;border-bottom:1px solid #eee;font-weight:bold}.load_more_jobs.loading{background:url(../images/ajax-loader.gif) no-repeat center}.load_more_jobs.loading strong{visibility:hidden}.load_more_jobs:hover,.load_more_jobs:focus{background-color:#fcfcfc}.job_listing_preview{padding:0 1em 1em;border:5px solid #eee}.job_listing_preview_title,.entry-content .job_listing_preview_title{padding:.5em 1em;margin-bottom:0;vertical-align:middle;position:relative;background:#eee}.job_listing_preview_title .button,.entry-content .job_listing_preview_title .button{float:right}.job_summary_shortcode{border:1px solid #ccc;-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px;text-align:center;position:relative;box-shadow:0 2px 4px rgba(0,0,0,0.1),inset 0 1px 0 rgba(255,255,255,0.4);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.job_summary_shortcode.aligncenter{display:block;margin:2em auto 2em}.job_summary_shortcode.alignleft{float:left;margin:0 2em 2em 0}.job_summary_shortcode.alignright{float:right;margin:0 0 2em 2em}.job_summary_shortcode a{text-decoration:none;color:inherit}.job_summary_shortcode img{margin:0;padding:0;display:block;width:100%;-moz-border-radius:0;-webkit-border-radius:0;-moz-border-top-left-radius:3px;-moz-border-top-right-radius:3px;-webkit-border-top-left-radius:3px;-webkit-border-top-right-radius:3px;border-radius:0;border-top-left-radius:3px;border-top-right-radius:3px;box-shadow:inset 0 1px 0 rgba(255,255,255,0.4)}.job_summary_shortcode .job_summary_content{padding:0 1em}.job_summary_shortcode .meta{font-style:italic;color:#777}.job_summary_shortcode .job-type{-moz-border-radius:1em;-webkit-border-radius:1em;border-radius:1em;color:#fff;text-shadow:0 1px 0 rgba(255,255,255,0.5);box-shadow:0 2px 4px rgba(0,0,0,0.1),inset 0 1px 0 rgba(255,255,255,0.4);position:absolute;top:0;right:0;padding:.5em;height:1em;width:auto;min-width:1em;font-size:1em;text-align:center;vertical-align:middle;line-height:1em;margin:-0.5em -0.5em 0 0}.job_summary_shortcode .job-type.full-time{background-color:#90da36}.job_summary_shortcode .job-type.part-time{background-color:#f08d3c}.job_summary_shortcode .job-type.temporary{background-color:#d93674}.job_summary_shortcode .job-type.freelance{background-color:#39c}.job_summary_shortcode .job-type.internship{background-color:#6033cc}#job-manager-job-dashboard table ul.job-dashboard-actions{margin:0;padding:0;visibility:hidden;font-size:.92em}#job-manager-job-dashboard table ul.job-dashboard-actions li{float:none;display:inline;padding:0;margin:0 .5em 0 0;font-weight:normal;list-style:none outside}#job-manager-job-dashboard table ul.job-dashboard-actions li:after{padding:0 0 0 .5em;content:"\2023"}#job-manager-job-dashboard table ul.job-dashboard-actions li:last-child:after{content:''}#job-manager-job-dashboard table ul.job-dashboard-actions li .job-dashboard-action-delete{color:red}#job-manager-job-dashboard table tr:hover ul.job-dashboard-actions,#job-manager-job-dashboard table tr:focus ul.job-dashboard-actions{visibility:visible}#job-manager-job-dashboard table .filled,#job-manager-job-dashboard table .expires{text-align:center}
assets/css/frontend.less ADDED
@@ -0,0 +1,728 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @import "mixins";
2
+
3
+ @primary: #999999; /* Primary colour for buttons (alt) */
4
+ @primarytext: desaturate(lighten(@primary,50%),18%); /* Text on primary colour bg */
5
+
6
+ @secondary: desaturate(lighten(@primary,40%),18%); /* Secondary buttons */
7
+ @secondarytext: desaturate(darken(@secondary,60%),18%); /* Text on secondary colour bg */
8
+
9
+ @highlight: spin( @primary, 150 ); /* Prices, In stock labels, sales flash */
10
+ @highlightext: desaturate(lighten(@highlight,50%),18%); /* Text on highlight colour bg */
11
+
12
+ @contentbg: #fff; /* Content BG - Tabs (active state) */
13
+ @subtext: #777; /* small, breadcrumbs etc */
14
+
15
+ @font-face {
16
+ font-family: 'Genericons';
17
+ src: url('../font/genericons-regular-webfont.eot');
18
+ src: url('../font/genericons-regular-webfont.eot?#iefix') format('embedded-opentype'),
19
+ url('../font/genericons-regular-webfont.woff') format('woff'),
20
+ url('../font/genericons-regular-webfont.ttf') format('truetype'),
21
+ url('../font/genericons-regular-webfont.svg#genericonsregular') format('svg');
22
+ font-weight: normal;
23
+ font-style: normal;
24
+ }
25
+
26
+ .display-icon {
27
+ display: inline-block;
28
+ width: 16px;
29
+ height: 16px;
30
+ -webkit-font-smoothing: antialiased;
31
+ font-size: 16px;
32
+ font-family: 'Genericons';
33
+ text-decoration: none;
34
+ font-weight: normal;
35
+ font-style: normal;
36
+ vertical-align: top;
37
+ font-size: 16px;
38
+ margin: 0 2px 0 0;
39
+
40
+ *overflow: auto;
41
+ *zoom: 1;
42
+ *display: inline;
43
+ }
44
+
45
+ /* =Global styles/layout
46
+ -------------------------------------------------------------- */
47
+ .job-manager-message, .job-manager-error, .job-manager-info {
48
+ padding: 1em 1em 1em 3.5em;
49
+ margin: 0 0 2em;
50
+ position: relative;
51
+ .border_radius(4px);
52
+ .vertical_gradient( lighten( @secondary, 2 ), @secondary );
53
+ color: @secondarytext;
54
+ .text_shadow( 0, 1px, 0, lighten( @secondary, 4 ) );
55
+ list-style:none outside;
56
+ .clearfix();
57
+ width: auto;
58
+ -webkit-box-shadow:
59
+ inset 0 -2px 6px rgba(0,0,0,0.05),
60
+ inset 0 -2px 30px rgba(0,0,0,0.015),
61
+ inset 0 1px 0 #fff,
62
+ 0 1px 2px rgba(0,0,0,0.3);
63
+ box-shadow:
64
+ inset 0 -2px 6px rgba(0,0,0,0.05),
65
+ inset 0 -2px 30px rgba(0,0,0,0.015),
66
+ inset 0 1px 0 #fff,
67
+ 0 1px 2px rgba(0,0,0,0.3);
68
+
69
+ &:before {
70
+ content: "";
71
+ height: 1.5em;
72
+ width: 1.5em;
73
+ display:block;
74
+ position:absolute;
75
+ top: 0;
76
+ left: 1em;
77
+ font-family: sans-serif;
78
+ font-size:1em;
79
+ line-height: 1.5;
80
+ text-align: center;
81
+ color: #fff;
82
+ text-shadow:0 1px 0 rgba(0,0,0,0.2);
83
+ padding-top:1em;
84
+ .border_radius_bottom(4px);
85
+ .inset_box_shadow(0,-1px,0,0,rgba(0,0,0,0.1));
86
+ }
87
+ li {
88
+ list-style:none outside;
89
+ padding-left:0;
90
+ margin-left:0;
91
+ }
92
+ &.job-manager-message {
93
+ border-top:3px solid #8fae1b;
94
+ &:before {
95
+ background-color:#8fae1b;
96
+ content: "\2713";
97
+ }
98
+ }
99
+ &.job-manager-info {
100
+ border-top:3px solid #1e85be;
101
+ &:before {
102
+ background-color:#1e85be;
103
+ content: "i";
104
+ font-family: Times, Georgia, serif;
105
+ font-style: italic;
106
+ }
107
+ }
108
+ &.job-manager-error {
109
+ border-top:3px solid #b81c23;
110
+ &:before {
111
+ background-color:#b81c23;
112
+ content: "\00d7";
113
+ font-weight: 700;
114
+ }
115
+ }
116
+ }
117
+
118
+
119
+
120
+ .job-manager-form {
121
+ fieldset {
122
+ margin: 0 0 1em 0;
123
+ padding: 0 0 1em 0;
124
+ line-height: 2em;
125
+ border-bottom: 1px solid #eee;
126
+ overflow: hidden;
127
+ label {
128
+ display: block;
129
+ margin: 0;
130
+ width: 29%;
131
+ float: left;
132
+ vertical-align: middle;
133
+ small {
134
+ opacity: .75;
135
+ font-size: 0.83em;
136
+ }
137
+ }
138
+ div.field {
139
+ width: 70%;
140
+ float: right;
141
+ vertical-align: middle;
142
+ }
143
+ .account-sign-in {
144
+ .button {
145
+ margin-right: .5em;
146
+ &:before {
147
+ .display-icon;
148
+ content: '\f427';
149
+ }
150
+ }
151
+ }
152
+ abbr.required {
153
+ color: red;
154
+ font-weight: bold;
155
+ border: 0;
156
+ }
157
+ input.input-text, textarea, select {
158
+ margin: 0;
159
+ vertical-align: middle;
160
+ width: 100%;
161
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
162
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
163
+ box-sizing: border-box; /* Opera/IE 8+ */
164
+ }
165
+ small.description {
166
+ opacity: .75;
167
+ font-size: 0.83em;
168
+ margin: 1.2em 0 0 0;
169
+ display: block;
170
+ line-height: 1.2em;
171
+ }
172
+ .uploaded_image {
173
+ line-height: 64px;
174
+ font-style: italic;
175
+ margin: 0 0 1em 0;
176
+ img {
177
+ height: 64px;
178
+ vertical-align: middle;
179
+ margin: 0 1em 0 0;
180
+ }
181
+ }
182
+ }
183
+ .submit-job {
184
+ padding: 1em 0;
185
+ }
186
+
187
+ }
188
+ ul.job_listings {
189
+ padding: 0;
190
+ margin: 0 !important;
191
+ border-top: 1px solid #eee;
192
+
193
+ &.loading {
194
+ background: url(../images/ajax-loader.gif) no-repeat center;
195
+ }
196
+ li.job_listing, li.no_job_listings_found {
197
+ list-style: none outside;
198
+ padding: 0;
199
+ margin: 0;
200
+ border-bottom: 1px solid #eee;
201
+
202
+ &.job_position_filled {
203
+ a {
204
+ opacity: 0.25;
205
+ }
206
+ }
207
+ &.no_job_listings_found {
208
+ padding: 1em;
209
+ border-bottom: 1px solid #eee;
210
+ }
211
+ a {
212
+ display: block;
213
+ padding: 1em 1em 1em 2em;
214
+ overflow: hidden;
215
+ zoom: 1;
216
+ position: relative;
217
+ line-height: 3em;
218
+ font-size: 1em;
219
+ text-decoration: none;
220
+
221
+ &:hover, &:focus {
222
+ background-color: #fcfcfc;
223
+ }
224
+ img {
225
+ width: 42px;
226
+ height: 42px;
227
+ position: absolute;
228
+ left: 1em;
229
+ float: left;
230
+ margin-right: 1em;
231
+ vertical-align: middle;
232
+ box-shadow: none;
233
+ }
234
+ div.position, div.location, ul.meta {
235
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
236
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
237
+ box-sizing: border-box; /* Opera/IE 8+ */
238
+ }
239
+ div.position {
240
+ float: left;
241
+ width: 60%;
242
+ padding: 0 0 0 42px;
243
+ line-height: 1.5em;
244
+ h3 {
245
+ margin: 0;
246
+ padding: 0;
247
+ font-size: 1em;
248
+ line-height: 1.5em;
249
+ }
250
+ .company {
251
+ color: #999;
252
+ font-size: 0.75em;
253
+ .tagline {
254
+ margin-left: .5em;
255
+ }
256
+ }
257
+ }
258
+ div.location {
259
+ float: left;
260
+ text-align: left;
261
+ width: 20%;
262
+ padding: 0 0 0 1em;
263
+ color: #999;
264
+ font-size: 0.75em;
265
+ }
266
+ .meta {
267
+ float: right;
268
+ text-align: right;
269
+ width: 20%;
270
+ padding: 0 0 0 1em;
271
+ margin: 0;
272
+ line-height: 1.5em;
273
+ color: #999;
274
+ list-style: none outside;
275
+ li {
276
+ list-style: none outside;
277
+ display: block;
278
+ font-size: 0.75em;
279
+ margin: 0;
280
+ }
281
+ .job-type {
282
+ font-weight: bold;
283
+ }
284
+ }
285
+ }
286
+ }
287
+ }
288
+ .widget {
289
+ ul.job_listings {
290
+ li.job_listing {
291
+ a {
292
+ padding: 1em 0;
293
+ }
294
+ .position {
295
+ float: none;
296
+ width: auto;
297
+ padding: 0;
298
+ }
299
+ ul.meta {
300
+ float: none;
301
+ width: auto;
302
+ padding: 0;
303
+ margin: 0;
304
+ text-align: left;
305
+ li {
306
+ float: none;
307
+ display: inline;
308
+ padding: 0;
309
+ margin: 0 .5em 0 0;
310
+ font-weight: normal;
311
+
312
+ &:after {
313
+ padding: 0 0 0 .5em;
314
+ content: "\2023";
315
+ }
316
+ &:last-child:after {
317
+ content: '';
318
+ }
319
+ }
320
+ }
321
+ }
322
+ }
323
+ }
324
+ .job-manager, .job_listing, .job-types {
325
+ .full-time {
326
+ color: @full-time;
327
+ }
328
+ .part-time {
329
+ color: @part-time;
330
+ }
331
+ .temporary {
332
+ color: @temporary;
333
+ }
334
+ .freelance {
335
+ color: @freelance;
336
+ }
337
+ .internship {
338
+ color: @internship;
339
+ }
340
+ }
341
+ .single_job_listing {
342
+ .company {
343
+ position: relative;
344
+ border: 1px solid #eee;
345
+ padding: 1em 1em 1em 42px;
346
+ margin: 0 0 2em;
347
+ display: block;
348
+ clear: both;
349
+ min-height: 42px;
350
+
351
+ img {
352
+ width: 42px;
353
+ height: 42px;
354
+ position: absolute;
355
+ left: 1em;
356
+ float: left;
357
+ vertical-align: middle;
358
+ box-shadow: none;
359
+ }
360
+ .name {
361
+ margin: 0;
362
+ padding: 0 0 0 2em;
363
+ a {
364
+ float: right;
365
+ margin-left: 1em;
366
+ }
367
+ }
368
+ .tagline {
369
+ display: block;
370
+ margin: 0;
371
+ padding: 0 0 0 2em;
372
+ font-style: italic;
373
+ color: #999;
374
+ }
375
+ .website:before {
376
+ .display-icon;
377
+ content: '\f107';
378
+ }
379
+ .company_twitter:before {
380
+ .display-icon;
381
+ content: '\f202';
382
+ }
383
+ }
384
+ .meta {
385
+ list-style: none outside;
386
+ padding: 0;
387
+ margin: 0 0 1.5em;
388
+ overflow: hidden;
389
+ zoom: 1;
390
+ li {
391
+ margin: 0 1em 0 0;
392
+ padding: .5em;
393
+ float: left;
394
+ line-height: 1em;
395
+ color: #999;
396
+ }
397
+ .job-type {
398
+ color: #fff;
399
+ background-color: @part-time;
400
+ }
401
+ .full-time {
402
+ background-color: @full-time;
403
+ }
404
+ .part-time {
405
+ background-color: @part-time;
406
+ }
407
+ .temporary {
408
+ background-color: @temporary;
409
+ }
410
+ .freelance {
411
+ background-color: @freelance;
412
+ }
413
+ .internship {
414
+ background-color: @internship;
415
+ }
416
+ .position-filled {
417
+ color: #b81c23;
418
+ }
419
+ .location:before {
420
+ .display-icon;
421
+ content: '\f417';
422
+ }
423
+ .date-posted:before {
424
+ .display-icon;
425
+ content: '\f307';
426
+ }
427
+ .position-filled:before {
428
+ .display-icon;
429
+ content: '\f424';
430
+ }
431
+ }
432
+ .application {
433
+ overflow: hidden;
434
+ zoom: 1;
435
+ padding-left: 20px;
436
+ margin: 0 0 1em;
437
+
438
+ .application_button, .application_details {
439
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
440
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
441
+ box-sizing: border-box; /* Opera/IE 8+ */
442
+ }
443
+
444
+ .application_button {
445
+ text-align: center;
446
+ font-size: 1.2em;
447
+ line-height: 1em;
448
+ width: 33.3%;
449
+ float: left;
450
+ margin: 0 0 0 -20px;
451
+ padding: 1/1.2em;
452
+ }
453
+ .application_details {
454
+ float: right;
455
+ width: 66.6%;
456
+ border: 1px solid #eee;
457
+ padding: .75em 1em 0;
458
+ margin: 0;
459
+ line-height: 1.5em;
460
+ display: block;
461
+ position: relative;
462
+
463
+ p {
464
+ margin: 0 0 .75em;
465
+ }
466
+
467
+ &:before {
468
+ content: "";
469
+ position: absolute;
470
+ margin: 0 0 0 -10px;
471
+ left: 0;
472
+ top: 1em;
473
+ width: 0;
474
+ height: 0;
475
+ border-top: 10px solid transparent;
476
+ border-bottom: 10px solid transparent;
477
+ border-right:10px solid #eee;
478
+ }
479
+ &:after {
480
+ content: "";
481
+ position: absolute;
482
+ margin: 1px 0 0 -9px;
483
+ top: 1em;
484
+ left: 0;
485
+ width: 0;
486
+ height: 0;
487
+ border-top: 9px solid transparent;
488
+ border-bottom: 9px solid transparent;
489
+ border-right: 9px solid #fff;
490
+ }
491
+ }
492
+ }
493
+ }
494
+ .job_filters {
495
+ background: #eee;
496
+ .clearfix;
497
+
498
+ .search_jobs {
499
+ padding: 1em;
500
+ .clearfix;
501
+ div {
502
+ width: 50%;
503
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
504
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
505
+ box-sizing: border-box; /* Opera/IE 8+ */
506
+
507
+ label {
508
+ display: none;
509
+ }
510
+ &.search_keywords {
511
+ float: left;
512
+ padding-right: .5em;
513
+ }
514
+ &.search_location {
515
+ float: right;
516
+ padding-left: .5em;
517
+ }
518
+ &.search_categories {
519
+ padding-top: .5em;
520
+ clear: both;
521
+ width: 100%;
522
+ }
523
+ }
524
+ input, select {
525
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
526
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
527
+ box-sizing: border-box; /* Opera/IE 8+ */
528
+ width: 100%;
529
+ }
530
+ }
531
+ .job_types {
532
+ list-style: none outside;
533
+ margin: 0;
534
+ padding: 0;
535
+ font-size: 0.83em;
536
+ background: #f9f9f9;
537
+ border-top: 1px solid #e5e5e5;
538
+ .clearfix;
539
+ li {
540
+ margin: 0;
541
+ padding: .5em 1em;
542
+ float: left;
543
+ border-right: 1px solid #eee;
544
+
545
+ &:last-child {
546
+ border-right: 0;
547
+ }
548
+ }
549
+ }
550
+
551
+ .showing_jobs {
552
+ padding: .5em 1em;
553
+ display: none;
554
+ font-size: 0.83em;
555
+ background: #f9f9f9;
556
+ border-top: 1px solid #e5e5e5;
557
+
558
+ .reset, .rss_link {
559
+ float: right;
560
+ }
561
+ .rss_link {
562
+ padding-right: 10px;
563
+ }
564
+ }
565
+ }
566
+ .load_more_jobs {
567
+ text-align: center;
568
+ display: block;
569
+ padding: 1em 1em 1em 2em;
570
+ border-bottom: 1px solid #eee;
571
+ font-weight: bold;
572
+ &.loading {
573
+ background: url(../images/ajax-loader.gif) no-repeat center;
574
+ strong {
575
+ visibility: hidden;
576
+ }
577
+ }
578
+ &:hover, &:focus {
579
+ background-color: #fcfcfc;
580
+ }
581
+ }
582
+ .job_listing_preview {
583
+ padding: 0 1em 1em;
584
+ border: 5px solid #eee;
585
+ }
586
+ .job_listing_preview_title, .entry-content .job_listing_preview_title {
587
+ padding: .5em 1em;
588
+ margin-bottom: 0;
589
+ vertical-align: middle;
590
+ position: relative;
591
+ background: #eee;
592
+ .button {
593
+ float: right;
594
+ }
595
+ }
596
+ .job_summary_shortcode {
597
+ border: 1px solid #ccc;
598
+ -moz-border-radius: 4px;
599
+ -webkit-border-radius: 4px;
600
+ border-radius: 4px;
601
+ text-align: center;
602
+ position: relative;
603
+ box-shadow: 0 2px 4px rgba(0,0,0,0.1),inset 0 1px 0 rgba(255,255,255,0.4);
604
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
605
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
606
+ box-sizing: border-box; /* Opera/IE 8+ */
607
+
608
+ &.aligncenter {
609
+ display: block;
610
+ margin: 2em auto 2em;
611
+ }
612
+
613
+ &.alignleft {
614
+ float: left;
615
+ margin: 0 2em 2em 0;
616
+ }
617
+
618
+ &.alignright {
619
+ float: right;
620
+ margin: 0 0 2em 2em;
621
+ }
622
+
623
+ a {
624
+ text-decoration: none;
625
+ color: inherit;
626
+ }
627
+
628
+ img {
629
+ margin: 0;
630
+ padding: 0;
631
+ display: block;
632
+ width: 100%;
633
+ -moz-border-radius: 0;
634
+ -webkit-border-radius: 0;
635
+ -moz-border-top-left-radius: 3px;
636
+ -moz-border-top-right-radius: 3px;
637
+ -webkit-border-top-left-radius: 3px;
638
+ -webkit-border-top-right-radius: 3px;
639
+ border-radius: 0;
640
+ border-top-left-radius: 3px;
641
+ border-top-right-radius: 3px;
642
+ box-shadow: inset 0 1px 0 rgba(255,255,255,0.4);
643
+ }
644
+
645
+ .job_summary_content {
646
+ padding: 0 1em;
647
+ }
648
+
649
+ .meta {
650
+ font-style: italic;
651
+ color: #777;
652
+ }
653
+
654
+ .job-type {
655
+ -moz-border-radius: 1em;
656
+ -webkit-border-radius: 1em;
657
+ border-radius: 1em;
658
+ color: #fff;
659
+ text-shadow: 0 1px 0 rgba(255,255,255,0.5);
660
+ box-shadow: 0 2px 4px rgba(0,0,0,0.1), inset 0 1px 0 rgba(255,255,255,0.4);
661
+ position: absolute;
662
+ top: 0;
663
+ right: 0;
664
+ padding: .5em;
665
+ height: 1em;
666
+ width: auto;
667
+ min-width: 1em;
668
+ font-size: 1em;
669
+ text-align: center;
670
+ vertical-align: middle;
671
+ line-height: 1em;
672
+ margin: -.5em -.5em 0 0;
673
+
674
+ &.full-time {
675
+ background-color: @full-time;
676
+ }
677
+ &.part-time {
678
+ background-color: @part-time;
679
+ }
680
+ &.temporary {
681
+ background-color: @temporary;
682
+ }
683
+ &.freelance {
684
+ background-color: @freelance;
685
+ }
686
+ &.internship {
687
+ background-color: @internship;
688
+ }
689
+ }
690
+ }
691
+
692
+ #job-manager-job-dashboard {
693
+ table {
694
+ ul.job-dashboard-actions {
695
+ margin: 0;
696
+ padding:0;
697
+ visibility: hidden;
698
+ font-size: 0.92em;
699
+ li {
700
+ float: none;
701
+ display: inline;
702
+ padding: 0;
703
+ margin: 0 .5em 0 0;
704
+ font-weight: normal;
705
+ list-style: none outside;
706
+
707
+ &:after {
708
+ padding: 0 0 0 .5em;
709
+ content: "\2023";
710
+ }
711
+ &:last-child:after {
712
+ content: '';
713
+ }
714
+ .job-dashboard-action-delete {
715
+ color: red;
716
+ }
717
+ }
718
+ }
719
+ tr:hover, tr:focus {
720
+ ul.job-dashboard-actions {
721
+ visibility: visible;
722
+ }
723
+ }
724
+ .filled, .expires {
725
+ text-align: center;
726
+ }
727
+ }
728
+ }
assets/css/menu.css ADDED
@@ -0,0 +1 @@
 
1
+ #adminmenu #menu-posts-job_listing div.wp-menu-image{background-image:url(../images/briefcase-menu.png);background-size:auto;background-position:-70px -65px}#adminmenu #menu-posts-job_listing.wp-menu-open div.wp-menu-image,#adminmenu #menu-posts-job_listing:hover div.wp-menu-image{background-position:-70px -1px}#adminmenu #menu-posts-job_listing img{display:none}#icon-edit.icon32-posts-job_listing{background-image:url(../images/briefcase.png);background-position:-117px -11px;background-size:auto}@media(-webkit-min-device-pixel-ratio:2),(min-resolution:192dpi){#adminmenu #menu-posts-job_listing div.wp-menu-image{background-size:50px 46px;background-position:7px -26px}#adminmenu #menu-posts-job_listing.wp-menu-open div.wp-menu-image,#adminmenu #menu-posts-job_listing:hover div.wp-menu-image{background-position:7px 6px}#icon-edit.icon32-posts-job_listing{background-size:75px 27px;background-position:1px 2px}}
assets/css/menu.less ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Menu */
2
+ #adminmenu {
3
+ #menu-posts-job_listing {
4
+ div.wp-menu-image {
5
+ background-image: url(../images/briefcase-menu.png);
6
+ background-size: auto;
7
+ background-position: -70px -65px;
8
+ }
9
+ &.wp-menu-open div.wp-menu-image, &:hover div.wp-menu-image {
10
+ background-position: -70px -1px;
11
+ }
12
+ img {
13
+ display: none;
14
+ }
15
+ }
16
+ }
17
+ #icon-edit.icon32-posts-job_listing {
18
+ background-image: url(../images/briefcase.png);
19
+ background-position: -117px -11px;
20
+ background-size: auto;
21
+ }
22
+
23
+ @media
24
+ (-webkit-min-device-pixel-ratio: 2),
25
+ (min-resolution: 192dpi) {
26
+ #adminmenu {
27
+ #menu-posts-job_listing {
28
+ div.wp-menu-image {
29
+ background-size: 50px 46px;
30
+ background-position: 7px -26px;
31
+ }
32
+ &.wp-menu-open div.wp-menu-image, &:hover div.wp-menu-image {
33
+ background-position: 7px 6px;
34
+ }
35
+ }
36
+ }
37
+ #icon-edit.icon32-posts-job_listing {
38
+ background-size: 75px 27px;
39
+ background-position: 1px 2px;
40
+ }
41
+ }
assets/css/mixins.less ADDED
@@ -0,0 +1,92 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @full-time: #90da36;
2
+ @part-time: #f08d3c;
3
+ @internship:#6033cc;
4
+ @freelance: #3399cc;
5
+ @temporary: #d93674;
6
+
7
+ .clearfix {
8
+ zoom: 1; /* For IE 6/7 (trigger hasLayout) */
9
+
10
+ &:before, &:after {
11
+ content: "";
12
+ display: table;
13
+ }
14
+ &:after {
15
+ clear: both;
16
+ }
17
+ }
18
+ .border_radius(@radius:4px) {
19
+ -webkit-border-radius:@radius;
20
+ border-radius:@radius;
21
+ }
22
+ .border_radius_right(@radius:4px) {
23
+ -webkit-border-top-right-radius: @radius;
24
+ -webkit-border-bottom-right-radius: @radius;
25
+ border-top-right-radius: @radius;
26
+ border-bottom-right-radius: @radius;
27
+ }
28
+ .border_radius_left(@radius:4px) {
29
+ -webkit-border-top-left-radius: @radius;
30
+ -webkit-border-bottom-left-radius: @radius;
31
+ border-top-left-radius: @radius;
32
+ border-bottom-left-radius: @radius;
33
+ }
34
+ .border_radius_bottom(@radius:4px) {
35
+ -webkit-border-bottom-left-radius: @radius;
36
+ -webkit-border-bottom-right-radius: @radius;
37
+ border-bottom-left-radius: @radius;
38
+ border-bottom-right-radius: @radius;
39
+ }
40
+ .border_radius_top(@radius:4px) {
41
+ -webkit-border-top-left-radius: @radius;
42
+ -webkit-border-top-right-radius: @radius;
43
+ border-top-left-radius: @radius;
44
+ border-top-right-radius: @radius;
45
+ }
46
+ .opacity(@opacity:0.75) {
47
+ filter:~"alpha(opacity=@opacity * 100)";
48
+ -khtml-opacity: @opacity;
49
+ opacity: @opacity;
50
+ }
51
+ .box_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_in:3px, @shadow_color:#888) {
52
+ box-shadow:@shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
53
+ -webkit-box-shadow:@shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
54
+ -moz-box-shadow:@shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
55
+ }
56
+ .inset_box_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_in:3px, @shadow_color:#888) {
57
+ box-shadow:inset @shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
58
+ -webkit-box-shadow:inset @shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
59
+ -moz-box-shadow:inset @shadow_x @shadow_y @shadow_rad @shadow_in @shadow_color;
60
+ }
61
+ .text_shadow(@shadow_x:3px, @shadow_y:3px, @shadow_rad:3px, @shadow_color:#fff) {
62
+ text-shadow:@shadow_x @shadow_y @shadow_rad @shadow_color;
63
+ }
64
+ .vertical_gradient(@from: #000, @to: #FFF) {
65
+ background: @from;
66
+ background: -webkit-gradient(linear, left top, left bottom, from(@from), to(@to));
67
+ background: -webkit-linear-gradient(@from, @to);
68
+ background: -moz-linear-gradient(center top, @from 0%, @to 100%);
69
+ background: -moz-gradient(center top, @from 0%, @to 100%);
70
+ }
71
+ .transition(@selector:all, @animation:ease-in-out, @duration:.2s) {
72
+ -webkit-transition:@selector @animation @duration;
73
+ -moz-transition:@selector @animation @duration;
74
+ -o-transition:@selector @animation @duration;
75
+ transition:@selector @animation @duration;
76
+ }
77
+ .scale(@ratio:1.5){
78
+ -webkit-transform:scale(@ratio);
79
+ -moz-transform:scale(@ratio);
80
+ -ms-transform:scale(@ratio);
81
+ -o-transform:scale(@ratio);
82
+ transform:scale(@ratio);
83
+ }
84
+ .borderbox () {
85
+ -webkit-box-sizing: border-box; /* Safari/Chrome, other WebKit */
86
+ -moz-box-sizing: border-box; /* Firefox, other Gecko */
87
+ box-sizing: border-box; /* Opera/IE 8+ */
88
+ }
89
+ .clear { clear: both; }
90
+ .nobr { white-space: nowrap; }
91
+ .darkorlighttextshadow ( @a, @opacity: 0.8 ) when (lightness(@a) >= 65%) { .text_shadow( 0, -1px, 0, rgba(0,0,0,@opacity) ); }
92
+ .darkorlighttextshadow ( @a, @opacity: 0.8 ) when (lightness(@a) < 65%) { .text_shadow( 0, 1px, 0, rgba(255,255,255,@opacity) ); }
assets/font/genericons-regular-webfont.eot ADDED
Binary file
assets/font/genericons-regular-webfont.svg ADDED
@@ -0,0 +1,95 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?xml version="1.0" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" >
3
+ <svg xmlns="http://www.w3.org/2000/svg">
4
+ <metadata></metadata>
5
+ <defs>
6
+ <font id="genericonsregular" horiz-adv-x="2048" vert-origin-y="0">
7
+ <font-face units-per-em="2048" ascent="1638" descent="-410" />
8
+ <missing-glyph horiz-adv-x="500" />
9
+ <glyph unicode="&#xe000;" horiz-adv-x="500" d="M0 0z" />
10
+ <glyph unicode="&#xf100;" d="M512 512v128h768v-128h-768zM512 768v128h256v-128h-256zM512 1024v128h640v-128h-640zM512 1280v128h1024v-128h-1024zM896 768v128h640v-128h-640zM1280 1024v128h256v-128h-256z" />
11
+ <glyph unicode="&#xf101;" d="M256 1024q0 209 103 385.5t279.5 279.5t385.5 103t385.5 -103t279.5 -279.5t103 -385.5t-103 -385.5t-279.5 -279.5t-385.5 -103t-385.5 103t-279.5 279.5t-103 385.5zM768 1024q0 -106 75 -181t181 -75t181 75t75 181t-75 181t-181 75t-181 -75t-75 -181z" />
12
+ <glyph unicode="&#xf102;" d="M128 384v896l512 128l128 256h512l128 -256h512v-1024h-1792zM256 1440v160h256v-96zM576 960q0 -185 131.5 -316.5t316.5 -131.5q186 0 317 131.5t131 316.5t-131 316.5t-317 131.5q-185 0 -316.5 -131.5t-131.5 -316.5zM704 960q0 133 93.5 226.5t226.5 93.5 t226.5 -93.5t93.5 -226.5t-93.5 -226.5t-226.5 -93.5t-226.5 93.5t-93.5 226.5z" />
13
+ <glyph unicode="&#xf103;" d="M128 512v384h384v-384h-384zM128 1024v384h896v-384h-896zM640 512v384h384v-384h-384zM1152 512v896h896v-896h-896z" />
14
+ <glyph unicode="&#xf104;" d="M512 384v1280l1152 -640z" />
15
+ <glyph unicode="&#xf105;" d="M640 1408q0 159 112.5 271.5t271.5 112.5t271.5 -112.5t112.5 -271.5q0 -124 -71.5 -222t-184.5 -138v-536l-256 -128v664q-113 40 -184.5 138t-71.5 222z" />
16
+ <glyph unicode="&#xf106;" d="M384 640l128 768h512l-256 -768h-384zM1152 640l128 768h512l-256 -768h-384z" />
17
+ <glyph unicode="&#xf107;" d="M387 862q0 106 75 181l136 135l91 -90l-136 -136q-38 -37 -38 -90t38 -91l90 -90q38 -38 91 -38t90 38l136 135l91 -90l-136 -136q-75 -75 -181 -75t-181 75l-91 91q-75 75 -75 181zM734 952l362 362l90 -90l-362 -362zM870 1450l135 136q75 75 181 75t181 -75l91 -91 q75 -75 75 -181t-75 -181l-136 -136l-90 91l135 136q38 37 38 90t-38 91l-90 90q-38 38 -91 38t-90 -38l-136 -135z" />
18
+ <glyph unicode="&#xf108;" d="M0 1152v384q0 96 80 176t176 80h1024q96 0 176 -80t80 -176v-384q0 -96 -80 -176t-176 -80h-448l-448 -448v448h-128q-96 0 -176 80t-80 176zM768 640l128 128h384q168 0 276 108t108 276v384q96 0 176 -80t80 -176v-384q0 -96 -80 -176t-176 -80h-128v-448l-448 448 h-320z" />
19
+ <glyph unicode="&#xf109;" d="M256 768v512h384l384 384v-1280l-384 384h-384zM1205 843q75 75 75 181t-75 181l91 91q53 -54 82.5 -124t29.5 -148t-29.5 -148t-82.5 -124zM1386 662q71 71 110.5 164.5t39.5 197.5t-39.5 197.5t-110.5 164.5l91 91q88 -89 137.5 -206t49.5 -247q0 -87 -23 -170 t-64.5 -153.5t-99.5 -129.5z" />
20
+ <glyph unicode="&#xf200;" d="M0 1024q0 208 81 398t218.5 327t327 218t397.5 81q209 0 398.5 -81t326.5 -218t218 -326.5t81 -398.5q0 -335 -195.5 -601.5t-504.5 -369.5q-36 -7 -53 8.5t-17 40.5q0 4 0.5 102t0.5 179q0 130 -69 189q77 9 137.5 24.5t124.5 51.5t107 89t70.5 140t27.5 201 q0 161 -105 274q6 15 11 35t9 56t-3.5 83.5t-26.5 96.5q-4 1 -10.5 2t-32 -1t-55.5 -11t-79.5 -33.5t-104.5 -61.5q-118 33 -256 35q-138 -2 -256 -35q-55 37 -104 61.5t-80 33t-54.5 11.5t-33.5 1l-10 -2q-58 -146 -10 -271q-105 -115 -105 -274q0 -114 27.5 -201 t70.5 -140t107 -89t124.5 -52t136.5 -24q-53 -47 -65 -137q-28 -13 -59.5 -20t-75.5 -6.5t-87.5 28.5t-75.5 83q-2 4 -6.5 10.5t-19 24t-31.5 31t-44 25.5t-56 14h-10t-18.5 -3.5t-17 -9t4 -18.5t34.5 -31q3 -1 7.5 -4t19 -14.5t27.5 -27t30 -43.5t30 -61q1 -3 2.5 -7t8 -17 t15.5 -25.5t24.5 -28t33.5 -28t45 -23.5t57.5 -16t71.5 -3.5t87 11.5q0 -50 0.5 -110t0.5 -64q0 -24 -17 -40t-53 -10q-309 103 -504.5 370t-195.5 602z" />
21
+ <glyph unicode="&#xf201;" d="M0 1024q0 206 82 395.5t219.5 327t327 219.5t395.5 82t395.5 -82t327 -219.5t219.5 -327t82 -395.5t-82 -395.5t-219.5 -327t-327 -219.5t-395.5 -82t-395.5 82t-327 219.5t-219.5 327t-82 395.5zM128 1024q0 -167 58 -319.5t166 -272.5q125 205 339 360t445 232 q-16 48 -80 176q-282 -86 -481.5 -111t-446.5 -1v-64zM160 1232q194 -22 444 14t388 82q-141 282 -320 528q-194 -85 -329.5 -247.5t-182.5 -376.5zM480 320q216 -192 544 -192q181 0 368 80q-33 300 -208 688q-222 -74 -410 -225.5t-294 -350.5zM832 1904 q102 -166 304 -512q6 2 86 31t118.5 45t108 47t122 64t93.5 69q-126 126 -290.5 199t-349.5 73q-32 0 -96 -8t-96 -8zM1200 1248q22 -29 36.5 -54.5t34 -67.5t25.5 -54q170 33 336 30t288 -30q-26 285 -160 464q-71 -57 -162 -104.5t-214.5 -100.5t-183.5 -83zM1344 928 q14 -27 43 -103t74.5 -231t74.5 -306q156 108 258 278t126 362q-276 46 -576 0z" />
22
+ <glyph unicode="&#xf202;" d="M0 381q50 -6 100 -6q293 0 522 180q-137 2 -244.5 83t-147.5 208q44 -7 79 -7q57 0 110 15q-145 29 -241 144.5t-96 267.5v5q86 -48 191 -53q-86 58 -136.5 150t-50.5 200q0 113 57 211q158 -194 383 -310t483 -129q-11 49 -11 96q0 174 123 297t297 123q89 0 168.5 -35 t138.5 -97q142 27 266 102q-47 -150 -184 -233q124 15 241 66q-84 -127 -210 -217q2 -36 2 -55q0 -168 -49 -337t-150 -323.5t-241 -273.5t-336 -190t-420 -71q-351 0 -644 189z" />
23
+ <glyph unicode="&#xf203;" d="M0 117q0 -48 34.5 -82.5t82.5 -34.5h1814q48 0 82.5 34.5t34.5 82.5v1814q0 48 -34.5 82.5t-82.5 34.5h-1814q-48 0 -82.5 -34.5t-34.5 -82.5v-1814zM900 969v303h222v258q0 78 26 147t77 124t136.5 87t194.5 32q55 0 108 -3t79 -6l26 -3l-7 -282h-193q-76 0 -101.5 -32 t-25.5 -101v-3v-2v-9v-207h329l-14 -303h-315v-841h-320v841h-222z" />
24
+ <glyph unicode="&#xf204;" d="M640 969v303h222v258q0 78 26 147t77 124t136.5 87t194.5 32q55 0 108 -3t79 -6l26 -3l-7 -282h-193q-76 0 -101.5 -32t-25.5 -101v-3v-2v-9v-207h329l-14 -303h-315v-841h-320v841h-222z" />
25
+ <glyph unicode="&#xf205;" d="M128 1024q0 182 71 348t191 286t286 191t348 71t348 -71t286 -191t191 -286t71 -348t-71 -348t-191 -286t-286 -191t-348 -71t-348 71t-286 191t-191 286t-71 348zM218 1024q0 -236 125 -430.5t329 -294.5l-384 1053q-70 -156 -70 -328zM351 1466h52q37 0 91 2.5t89 4.5 l34 3q21 1 30.5 -14.5t2.5 -32.5t-27 -20q-44 -5 -93 -7l294 -873l176 529l-125 344l-85 7q-20 2 -27.5 19t2.5 33t30 15q133 -10 212 -10q38 0 91.5 2.5t88.5 4.5l35 3q16 1 25.5 -8.5t10 -22t-7 -23.5t-23.5 -13q-43 -5 -92 -7l291 -866l80 268q25 79 33.5 107.5 t18.5 74.5t10 79q0 46 -11.5 90.5t-23.5 71t-32 60.5q-2 4 -11.5 19t-12 20t-10.5 18.5t-11 19t-9 17.5t-8.5 19t-6.5 18t-5.5 19.5t-3 18.5t-1.5 20q0 57 39 100t96 43q3 0 11 -1q-110 101 -249.5 156.5t-294.5 55.5q-208 0 -385.5 -98t-287.5 -266zM796 251 q112 -33 228 -33q138 0 267 46q-3 6 -5 11l-248 679zM1429 328q183 106 291.5 291.5t108.5 404.5q0 207 -98 386q5 -40 5 -82q0 -135 -61 -289z" />
26
+ <glyph unicode="&#xf206;" d="M128 288q49 98 162 161t254 63q32 0 80 -16t80 -16q11 -8 41 -30.5l40 -30t34.5 -26.5t34 -28t28 -25.5t27 -28t20.5 -27t19 -30t12 -30.5v-64v-32h-608q-73 0 -136.5 44.5t-87.5 115.5zM128 480v480q52 -52 140.5 -90t179.5 -38h64q0 -16 -16 -48t-16 -48 q0 -50 25 -93.5t71 -66.5h-128q-176 0 -320 -96zM128 1600v96q0 96 64 160t160 64h1344q96 0 160 -64t64 -160v-160h-256v256h-128v-256h-256v-128h256v-256h128v256h256v-1056q0 -96 -64 -160t-160 -64h-544v64q0 128 -43.5 215t-180.5 201q-60 30 -126 89.5t-66 102.5 q0 46 26.5 78t101.5 82q48 48 72.5 75t57.5 70.5t47.5 86t14.5 88.5q0 122 -48.5 213.5t-143.5 138.5h160l160 160h-608q-133 0 -249.5 -55t-198.5 -137zM224 1312q-23 164 54.5 274t201.5 110q121 -24 208.5 -136.5t111.5 -279.5q24 -165 -38.5 -258.5t-185.5 -93.5 q-122 0 -225 109.5t-127 274.5z" />
27
+ <glyph unicode="&#xf207;" d="M384 1422q0 -58 40.5 -97.5t105.5 -39.5h1q67 0 108.5 39.5t41.5 97.5q-2 60 -42 98.5t-106 38.5q-67 0 -108 -39t-41 -98zM400 384h263v793h-263v-793zM809 384h264v443q0 45 8 64q16 40 50.5 68t85.5 28q133 0 133 -179v-424h264v455q0 175 -83.5 266t-220.5 91 q-50 0 -90.5 -12t-68.5 -34t-45 -41t-33 -44v112h-264v-793z" />
28
+ <glyph unicode="&#xf208;" d="M128 384v1280q0 106 75 181t181 75h1280q106 0 181 -75t75 -181v-1280q0 -106 -75 -181t-181 -75h-1280q-106 0 -181 75t-75 181zM384 1422q0 -58 40.5 -97.5t105.5 -39.5h1q67 0 108.5 39.5t41.5 97.5q-2 60 -42 98.5t-106 38.5q-67 0 -108 -39t-41 -98zM400 384h263 v793h-263v-793zM809 384h264v443q0 45 8 64q16 40 50.5 68t85.5 28q133 0 133 -179v-424h264v455q0 175 -83.5 266t-220.5 91q-50 0 -90.5 -12t-68.5 -34t-45 -41t-33 -44v112h-264v-793z" />
29
+ <glyph unicode="&#xf209;" d="M171 1260q0 109 35.5 219t110 213t179 182t254 126.5t323.5 47.5q176 0 327.5 -60.5t253.5 -161t160 -231t58 -270.5q0 -246 -85 -443t-241 -309.5t-355 -112.5q-99 0 -186.5 46.5t-121.5 110.5q-73 -290 -89 -347q-34 -123 -127 -270l-149 54q-7 167 22 290l162 688 q-40 81 -40 200q0 139 70.5 232.5t172.5 93.5q83 0 127 -53.5t44 -135.5q0 -51 -18.5 -124t-49 -170t-44.5 -154q-23 -99 37.5 -171t161.5 -72q117 0 209.5 92t142 244.5t49.5 334.5q0 214 -139 349t-387 135q-139 0 -257.5 -49.5t-197 -133t-122.5 -193t-44 -229.5 q0 -147 83 -247q18 -21 21.5 -34t-3.5 -37q-16 -61 -25 -101q-7 -24 -24.5 -32t-39.5 1q-127 51 -192.5 181.5t-65.5 300.5z" />
30
+ <glyph unicode="&#xf210;" d="M0 1024q0 208 81 398t218.5 327t327 218t397.5 81q209 0 398.5 -81t326.5 -218t218 -326.5t81 -398.5t-81 -398.5t-218 -326.5t-326.5 -218t-398.5 -81q-147 0 -290 42q74 116 103 219l72 282q28 -53 99 -90.5t151 -37.5q162 0 288.5 91.5t195.5 251t69 359.5 q0 114 -47 220t-130 187.5t-206.5 130.5t-265.5 49q-141 0 -262 -38.5t-205.5 -103t-145.5 -147.5t-89.5 -172.5t-28.5 -178.5q0 -138 53 -243.5t156 -147.5q18 -8 32.5 -1t18.5 26q2 9 10 41t11 41q5 19 2.5 30t-16.5 28q-68 78 -68 200q0 97 35.5 186t99.5 156.5t160 108 t209 40.5q201 0 313.5 -109.5t112.5 -283.5q0 -148 -40 -271.5t-115 -198t-169 -74.5q-82 0 -131.5 58.5t-30.5 138.5q11 46 35.5 125t39.5 138t15 101q0 66 -35.5 109.5t-102.5 43.5q-82 0 -139.5 -76t-57.5 -189q0 -43 8 -83.5t16 -59.5l9 -19q-113 -475 -132 -558 q-24 -97 -18 -235q-275 120 -444 374t-169 564z" />
31
+ <glyph unicode="&#xf211;" d="M160 1024q0 -172 122 -294t294 -122t294 122t122 294t-122 294t-294 122t-294 -122t-122 -294zM1056 1024q0 -172 122 -294t294 -122t294 122t122 294t-122 294t-294 122t-294 -122t-122 -294z" />
32
+ <glyph unicode="&#xf212;" d="M128 1379l84 -108q121 84 141 84q92 0 173 -287q20 -73 46 -167.5t52 -190t46 -167.5q108 -287 265 -287q253 0 619 471q353 451 365 710q16 347 -260 355q-373 12 -505 -417q69 29 133 29q136 0 120 -152q-8 -92 -120 -268q-113 -176 -169 -176q-73 0 -133 271 q-20 78 -72 407q-49 303 -258 284q-89 -8 -265 -160q-126 -113 -262 -231z" />
33
+ <glyph unicode="&#xf213;" d="M128 768v512q0 159 112.5 271.5t271.5 112.5h1024q159 0 271.5 -112.5t112.5 -271.5v-512q0 -104 -51.5 -192.5t-140 -140t-192.5 -51.5h-1024q-104 0 -192.5 51.5t-140 140t-51.5 192.5zM768 640l640 384l-640 384v-768z" />
34
+ <glyph unicode="&#xf214;" d="M472 1186h198v-629q0 -121 26 -187q26 -65 92 -122t161 -89q93 -31 218 -31q110 0 201 22q88 20 208 76v282q-134 -88 -271 -88q-76 0 -136 36q-44 25 -61 70q-17 46 -17 200v460h426v281h-426v453h-255q-17 -139 -62 -228q-48 -93 -121 -154q-74 -64 -181 -99v-253z" />
35
+ <glyph unicode="&#xf215;" d="M128 512v768h310q-54 -124 -54 -256q0 -130 51 -248.5t136.5 -204t204 -136.5t248.5 -51q174 0 321.5 86t233 233t85.5 321q0 132 -54 256h310v-768q0 -159 -112.5 -271.5t-271.5 -112.5h-1024q-159 0 -271.5 112.5t-112.5 271.5zM128 1408v128q0 159 112.5 271.5 t271.5 112.5h1024q159 0 271.5 -112.5t112.5 -271.5v-128h-387q-90 119 -222.5 187.5t-286.5 68.5t-286.5 -68.5t-222.5 -187.5h-387zM512 1024q0 212 150 362t362 150t362 -150t150 -362t-150 -362t-362 -150t-362 150t-150 362zM640 1024q0 -159 112.5 -271.5 t271.5 -112.5t271.5 112.5t112.5 271.5t-112.5 271.5t-271.5 112.5t-271.5 -112.5t-112.5 -271.5zM1408 1664q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5z" />
36
+ <glyph unicode="&#xf300;" d="M256 896v384q0 106 75 181t181 75h1024q106 0 181 -75t75 -181v-384q0 -106 -75 -181t-181 -75h-448l-448 -448v448h-128q-106 0 -181 75t-75 181z" />
37
+ <glyph unicode="&#xf301;" d="M384 512v1024h384l64 -128h448v-128h-640l-128 -256h128l64 128h960l-256 -640h-1024z" />
38
+ <glyph unicode="&#xf302;" d="M256 768l768 768h512v-512l-768 -768zM1152 1280q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5z" />
39
+ <glyph unicode="&#xf303;" d="M256 1088q0 143 55.5 273.5t150 225t225 150t273.5 55.5t273.5 -55.5t225 -150t150 -225t55.5 -273.5t-55.5 -273.5t-150 -225t-225 -150t-273.5 -55.5t-273.5 55.5t-225 150t-150 225t-55.5 273.5zM384 1088q0 -117 45.5 -223.5t123 -184t184 -123t223.5 -45.5 t223.5 45.5t184 123t123 184t45.5 223.5t-45.5 223.5t-123 184t-184 123t-223.5 45.5t-223.5 -45.5t-184 -123t-123 -184t-45.5 -223.5zM896 1062v474h128v-421l298 -298l-90 -91z" />
40
+ <glyph unicode="&#xf304;" d="M512 384v256q0 159 112.5 271.5t271.5 112.5h256q159 0 271.5 -112.5t112.5 -271.5v-256h-1024zM768 1408q0 106 75 181t181 75t181 -75t75 -181t-75 -181t-181 -75t-181 75t-75 181z" />
41
+ <glyph unicode="&#xf305;" d="M256 384v1280h256v128h128v-128h640v128h128v-128h256v-1280h-1408zM384 640q0 -53 37.5 -90.5t90.5 -37.5h896q53 0 90.5 37.5t37.5 90.5v640q0 53 -37.5 90.5t-90.5 37.5h-896q-53 0 -90.5 -37.5t-37.5 -90.5v-640zM768 1216q0 26 19 45t45 19h128q26 0 45 -19t19 -45 v-512q0 -26 -19 -45t-45 -19t-45 19t-19 45v448h-64q-26 0 -45 19t-19 45z" />
42
+ <glyph unicode="&#xf306;" d="M256 384v1280h256v128h128v-128h640v128h128v-128h256v-1280h-1408zM384 640q0 -53 37.5 -90.5t90.5 -37.5h896q53 0 90.5 37.5t37.5 90.5v640q0 53 -37.5 90.5t-90.5 37.5h-896q-53 0 -90.5 -37.5t-37.5 -90.5v-640zM768 1216q0 26 19 45t45 19h256h2h1h3 q22 -2 38.5 -18t19.5 -39v-2v-2v-1v-2q0 -5 -2 -15l-128 -512q-6 -26 -28.5 -40t-48.5 -7q-26 6 -40 28.5t-7 48.5l108 433h-174q-26 0 -45 19t-19 45z" />
43
+ <glyph unicode="&#xf307;" d="M256 384v1280h256v128h128v-128h640v128h128v-128h256v-1280h-1408zM384 640q0 -53 37.5 -90.5t90.5 -37.5h896q53 0 90.5 37.5t37.5 90.5v640q0 53 -37.5 90.5t-90.5 37.5h-896q-53 0 -90.5 -37.5t-37.5 -90.5v-640zM512 640v128h128v-128h-128zM512 896v128h128v-128 h-128zM768 640v128h128v-128h-128zM768 896v128h128v-128h-128zM768 1152v128h128v-128h-128zM1024 640v128h128v-128h-128zM1024 896v128h128v-128h-128zM1024 1152v128h128v-128h-128zM1280 896v128h128v-128h-128zM1280 1152v128h128v-128h-128z" />
44
+ <glyph unicode="&#xf308;" d="M256 384l512 512l128 -128l-512 -512zM576 1216v128h384l320 320v256h128l512 -512v-128h-256l-320 -320v-384h-128z" />
45
+ <glyph unicode="&#xf400;" d="M256 1216q0 117 45.5 223.5t123 184t184 123t223.5 45.5t223.5 -45.5t184 -123t123 -184t45.5 -223.5q0 -184 -111 -337l495 -495l-128 -128l-495 495q-153 -111 -337 -111q-117 0 -223.5 45.5t-184 123t-123 184t-45.5 223.5zM384 1216q0 -185 131.5 -316.5 t316.5 -131.5q186 0 317 131.5t131 316.5t-131 316.5t-317 131.5q-185 0 -316.5 -131.5t-131.5 -316.5z" />
46
+ <glyph unicode="&#xf401;" d="M256 1216q0 117 45.5 223.5t123 184t184 123t223.5 45.5t223.5 -45.5t184 -123t123 -184t45.5 -223.5q0 -184 -111 -337l495 -495l-128 -128l-495 495q-153 -111 -337 -111q-117 0 -223.5 45.5t-184 123t-123 184t-45.5 223.5zM384 1216q0 -185 131.5 -316.5 t316.5 -131.5q186 0 317 131.5t131 316.5t-131 316.5t-317 131.5q-185 0 -316.5 -131.5t-131.5 -316.5zM512 1152v128h640v-128h-640z" />
47
+ <glyph unicode="&#xf402;" d="M256 1216q0 117 45.5 223.5t123 184t184 123t223.5 45.5t223.5 -45.5t184 -123t123 -184t45.5 -223.5q0 -184 -111 -337l495 -495l-128 -128l-495 495q-153 -111 -337 -111q-117 0 -223.5 45.5t-184 123t-123 184t-45.5 223.5zM384 1216q0 -185 131.5 -316.5 t316.5 -131.5q186 0 317 131.5t131 316.5t-131 316.5t-317 131.5q-185 0 -316.5 -131.5t-131.5 -316.5zM512 1152v128h256v256h128v-256h256v-128h-256v-256h-128v256h-256z" />
48
+ <glyph unicode="&#xf403;" d="M0 1024l506 506q101 103 234.5 160.5t283.5 57.5t283.5 -57.5t233.5 -159.5l507 -507l-506 -507q-101 -103 -234.5 -160t-283.5 -57t-283.5 57.5t-233.5 160.5zM272 1024l370 -371q77 -78 175.5 -119.5t206.5 -41.5t206 41.5t174 118.5l373 372l-371 371 q-158 161 -382 161q-108 0 -206.5 -41t-173.5 -119zM640 1024q0 159 112.5 271.5t271.5 112.5t271.5 -112.5t112.5 -271.5t-112.5 -271.5t-271.5 -112.5t-271.5 112.5t-112.5 271.5zM1024 1152q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5 t-90.5 -37.5t-37.5 -90.5z" />
49
+ <glyph unicode="&#xf404;" d="M0 1024l506 506q101 103 234.5 160.5t283.5 57.5q193 0 358 -95l-143 -143q-103 46 -215 46q-108 0 -206.5 -41t-173.5 -119l-372 -372l240 -240l-136 -136zM339 429l90 -90l1280 1280l-90 90zM640 1024q0 159 112.5 271.5t271.5 112.5q44 0 98 -14l-468 -468 q-14 54 -14 98zM666 395l143 143q103 -46 215 -46q108 0 206 41.5t174 118.5l373 372l-241 241l136 135l376 -376l-506 -507q-101 -103 -234.5 -160t-283.5 -57q-193 0 -358 95zM926 654l468 468q14 -54 14 -98q0 -159 -112.5 -271.5t-271.5 -112.5q-44 0 -98 14z" />
50
+ <glyph unicode="&#xf405;" d="M640 768l320 320l-320 320l128 128l320 -320l320 320l128 -128l-320 -320l320 -320l-128 -128l-320 320l-320 -320z" />
51
+ <glyph unicode="&#xf406;" d="M128 256l832 832l-832 832l128 128l832 -832l832 832l128 -128l-832 -832l832 -832l-128 -128l-832 832l-832 -832z" />
52
+ <glyph unicode="&#xf407;" d="M384 1280v128l256 128q0 53 37.5 90.5t90.5 37.5h384q53 0 90.5 -37.5t37.5 -90.5l256 -128v-128h-1152zM512 512v704h128v-704h128v704h128v-704h128v704h128v-704h128v704h128v-704q0 -53 -37.5 -90.5t-90.5 -37.5h-640q-53 0 -90.5 37.5t-37.5 90.5zM768 1472 q0 -26 19 -45t45 -19h256q26 0 45 19t19 45t-19 45t-45 19h-256q-26 0 -45 -19t-19 -45z" />
53
+ <glyph unicode="&#xf408;" d="M256 1151l476 -330l-183 -535l475 332l475 -332l-183 535l476 329h-587l-181 535l-180 -534h-588z" />
54
+ <glyph unicode="&#xf409;" d="M384 1024l640 640l640 -640l-128 -128l-512 512l-512 -512zM640 512v384l384 384l384 -384v-384h-256v384h-256v-384h-256z" />
55
+ <glyph unicode="&#xf410;" d="M256 512v51l576 384l192 -128l192 128l576 -384v-51h-1536zM256 717v614l461 -307zM256 1485v51h1536v-51l-768 -512zM1331 1024l461 307v-614z" />
56
+ <glyph unicode="&#xf411;" d="M384 384v448l896 896l448 -448l-896 -896h-448zM512 768l256 -256l128 128l-256 256zM685 941l96 -96l595 595l-96 96zM845 781l96 -96l595 595l-96 96z" />
57
+ <glyph unicode="&#xf412;" d="M256 640v704l384 384v-704h640v448l640 -640l-640 -640v448h-1024z" />
58
+ <glyph unicode="&#xf413;" d="M128 384q0 106 75 181t181 75t181 -75t75 -181t-75 -181t-181 -75t-181 75t-75 181zM128 971v345q240 0 459 -94t377.5 -253.5t252.5 -379.5t94 -461h-345q0 170 -63.5 324t-181.5 273q-119 119 -272 182.5t-321 63.5zM129 1582v345q243 0 475 -64.5t428.5 -181 t362 -282.5t281 -363.5t180 -430.5t64.5 -477h-345q0 197 -52 385.5t-145.5 348t-227 294t-292 228t-346 146t-383.5 52.5z" />
59
+ <glyph unicode="&#xf414;" d="M21 230q-57 102 31 244l760 1237q57 93 134.5 126.5t155 0t135.5 -126.5l759 -1237q88 -142 31 -244t-224 -102h-1557q-168 0 -225 102zM896 512q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5zM896 896 q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5v384q0 53 -37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5v-384z" />
60
+ <glyph unicode="&#xf415;" d="M128 1024h400q45 0 79.5 27.5t44.5 69.5q33 125 136.5 206t235.5 81q154 0 270 -114q38 -38 90.5 -38t90.5 38q37 38 37 91t-37 90q-88 89 -204.5 139t-246.5 50q-194 0 -353 -106t-234 -278h-309v-256zM536 663q0 -53 37 -90q89 -89 205 -139t246 -50q194 0 353 106 t234 278h309v256h-400q-45 0 -79.5 -27.5t-44.5 -69.5q-33 -125 -136.5 -206t-235.5 -81q-156 0 -269 115q-38 37 -91 37t-91 -38q-37 -38 -37 -91zM768 1024q0 -106 75 -181t181 -75t181 75t75 181t-75 181t-181 75t-181 -75t-75 -181z" />
61
+ <glyph unicode="&#xf416;" d="M512 832v320h128v-320q0 -133 93.5 -226.5t226.5 -93.5t226.5 93.5t93.5 226.5v640q0 80 -56 136t-136 56t-136 -56t-56 -136v-512q0 -26 19 -45t45 -19t45 19t19 45v452h128v-452q0 -80 -56 -136t-136 -56t-136 56t-56 136v512q0 133 93.5 226.5t226.5 93.5t226.5 -93.5 t93.5 -226.5v-640q0 -185 -131.5 -316.5t-316.5 -131.5t-316.5 131.5t-131.5 316.5z" />
62
+ <glyph unicode="&#xf417;" d="M384 1216q0 117 45.5 223.5t123 184t184 123t223.5 45.5t223.5 -45.5t184 -123t123 -184t45.5 -223.5t-44.5 -222.5t-124.5 -185.5l-407 -406l-407 406q-80 80 -124.5 185.5t-44.5 222.5zM640 1216q0 -133 93.5 -226.5t226.5 -93.5t226.5 93.5t93.5 226.5t-93.5 226.5 t-226.5 93.5t-226.5 -93.5t-93.5 -226.5z" />
63
+ <glyph unicode="&#xf418;" d="M608 1056l128 128l224 -192l448 512l128 -96l-512 -768h-128z" />
64
+ <glyph unicode="&#xf419;" d="M0 256v256h2048v-256h-2048zM0 896v256h2048v-256h-2048zM0 1536v256h2048v-256h-2048z" />
65
+ <glyph unicode="&#xf420;" d="M384 512l640 640l640 -640h-1280zM384 1280v128h1280v-128h-1280z" />
66
+ <glyph unicode="&#xf421;" d="M384 896v256h1152v-256h-1152z" />
67
+ <glyph unicode="&#xf422;" d="M384 512v1024h1152v-1024h-1152zM512 640h896v640h-896v-640z" />
68
+ <glyph unicode="&#xf423;" d="M83 832l373 671l112 -62l-267 -481h403v-384h-128v256h-493zM768 1024q0 87 43 160.5t116.5 116.5t160.5 43t160.5 -43t116.5 -116.5t43 -160.5t-43 -160.5t-116.5 -116.5t-160.5 -43t-160.5 43t-116.5 116.5t-43 160.5zM896 1024q0 -79 56.5 -135.5t135.5 -56.5 t135.5 56.5t56.5 135.5t-56.5 135.5t-135.5 56.5t-135.5 -56.5t-56.5 -135.5zM1427 832l373 671l112 -62l-267 -481h403v-384h-128v256h-493z" />
69
+ <glyph unicode="&#xf424;" d="M256 640v768l384 384h768l384 -384v-768l-384 -384h-768zM896 640q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5zM896 1024q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5v384q0 53 -37.5 90.5t-90.5 37.5 t-90.5 -37.5t-37.5 -90.5v-384z" />
70
+ <glyph unicode="&#xf425;" d="M384 384v1280h256q0 53 37.5 90.5t90.5 37.5h384q53 0 90.5 -37.5t37.5 -90.5h256v-1280h-1152zM512 512h896v1024h-128v-128h-640v128h-128v-1024zM640 704q0 26 19 45t45 19t45 -19t19 -45t-19 -45t-45 -19t-45 19t-19 45zM640 960q0 26 19 45t45 19t45 -19t19 -45 t-19 -45t-45 -19t-45 19t-19 45zM640 1216q0 26 19 45t45 19t45 -19t19 -45t-19 -45t-45 -19t-45 19t-19 45zM768 1600q0 -26 19 -45t45 -19h256q26 0 45 19t19 45t-19 45t-45 19h-256q-26 0 -45 -19t-19 -45zM896 640v128h384v-128h-384zM896 896v128h384v-128h-384z M896 1152v128h384v-128h-384z" />
71
+ <glyph unicode="&#xf426;" d="M128 768q0 106 75 181t181 75h7q-7 29 -7 64q0 133 93.5 226.5t226.5 93.5q134 0 228 -96q47 101 140.5 162.5t207.5 61.5q159 0 271.5 -112.5t112.5 -271.5q0 -62 -23 -128h23q106 0 181 -75t75 -181t-75 -181t-181 -75h-1280q-106 0 -181 75t-75 181z" />
72
+ <glyph unicode="&#xf427;" d="M384 384v288l455 455l-1 1q-74 74 -74 180t74 181l233 233q75 74 181 74t180 -74l286 -286q74 -75 74 -180.5t-74 -180.5l-233 -233q-74 -73 -178.5 -74t-179.5 71l-455 -455h-288zM1088 1360l256 -256l160 160l-256 256z" />
73
+ <glyph unicode="&#xf428;" d="M768 1024q0 106 75 181t181 75t181 -75t75 -181t-75 -181t-181 -75t-181 75t-75 181z" />
74
+ <glyph unicode="&#xf429;" d="M384 896v128h896l-343 343l87 86l493 -493l-493 -493l-87 86l343 343h-896z" />
75
+ <glyph unicode="&#xf430;" d="M531 960l493 -493l87 86l-343 343h896v128h-896l343 343l-87 86z" />
76
+ <glyph unicode="&#xf431;" d="M384 1152l128 128l448 -448l448 448l128 -128l-576 -576z" />
77
+ <glyph unicode="&#xf432;" d="M384 768l576 576l576 -576l-128 -128l-448 448l-448 -448z" />
78
+ <glyph unicode="&#xf433;" d="M0 0v896l896 -896h-896z" />
79
+ <glyph unicode="&#xf434;" d="M1152 0l896 896v-896h-896z" />
80
+ <glyph unicode="&#xf435;" d="M384 512l640 640l640 -640h-1280zM384 1280v128h1280v-128h-1280z" />
81
+ <glyph unicode="&#xf436;" d="M512 640v128h128v-128h-128zM512 896v128h128v-128h-128zM512 1152v128h128v-128h-128zM512 1408v128h128v-128h-128zM768 640v128h128v-128h-128zM768 896v128h128v-128h-128zM768 1152v128h128v-128h-128zM768 1408v128h128v-128h-128zM1024 640v128h128v-128h-128z M1024 896v128h128v-128h-128zM1024 1152v128h128v-128h-128zM1024 1408v128h128v-128h-128zM1280 640v128h128v-128h-128zM1280 896v128h128v-128h-128zM1280 1152v128h128v-128h-128zM1280 1408v128h128v-128h-128z" />
82
+ <glyph unicode="&#xf437;" d="M512 512v1024q0 106 75 181t181 75h512q106 0 181 -75t75 -181v-1024q0 -106 -75 -181t-181 -75h-512q-106 0 -181 75t-75 181zM640 768h768v768h-768v-768zM896 512q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5z " />
83
+ <glyph unicode="&#xf438;" d="M256 1024v256h512v128l384 -256l-384 -256v128h-512zM512 512v384h128v-128h768v768h-768v-128h-128v128q0 106 75 181t181 75h512q106 0 181 -75t75 -181v-1024q0 -106 -75 -181t-181 -75h-512q-106 0 -181 75t-75 181zM896 512q0 -53 37.5 -90.5t90.5 -37.5t90.5 37.5 t37.5 90.5t-37.5 90.5t-90.5 37.5t-90.5 -37.5t-37.5 -90.5z" />
84
+ <glyph unicode="&#xf439;" d="M384 1152h1280q0 -231 -145.5 -406.5t-366.5 -220.5v-269h-256v269q-221 45 -366.5 220.5t-145.5 406.5zM640 1280v384q0 53 37.5 90.5t90.5 37.5t90.5 -37.5t37.5 -90.5v-384h-256zM1152 1280v384q0 53 37.5 90.5t90.5 37.5t90.5 -37.5t37.5 -90.5v-384h-256z" />
85
+ <glyph unicode="&#xf440;" d="M128 768q0 106 75 181t181 75h6q-6 32 -6 64q0 133 93.5 226.5t226.5 93.5q134 0 228 -96q47 101 140.5 162.5t207.5 61.5q159 0 271.5 -112.5t112.5 -271.5q0 -62 -23 -128h23q106 0 181 -75t75 -181t-75 -181t-181 -75h-384v256h-512v-256h-384q-106 0 -181 75t-75 181 zM640 384h256v256h256v-256h256l-384 -384z" />
86
+ <glyph unicode="&#xf441;" d="M128 768q0 106 75 181t181 75h6q-6 32 -6 64q0 133 93.5 226.5t226.5 93.5q134 0 228 -96q47 101 140.5 162.5t207.5 61.5q159 0 271.5 -112.5t112.5 -271.5q0 -62 -23 -128h23q106 0 181 -75t75 -181t-75 -181t-181 -75h-512v256h256l-384 384l-384 -384h256v-256h-512 q-106 0 -181 75t-75 181z" />
87
+ <glyph unicode="&#xf442;" d="M512 512v896h512l-128 -128h-256v-640h640v256l128 128v-512h-896zM896 987l550 549h-422v128h640v-640h-128v422l-550 -550z" />
88
+ <glyph unicode="&#xf443;" d="M512 384v1280h640l384 -384v-896h-1024zM640 512h768v640h-384v384h-384v-1024zM1152 1280h203l-203 203v-203z" />
89
+ <glyph unicode="&#xf444;" d="M384 512v1024q0 106 75 181t181 75h1024v-1152h-64q-53 0 -90.5 -37.5t-37.5 -90.5t37.5 -90.5t90.5 -37.5h64v-128h-1024q-106 0 -181 75t-75 181zM512 512q0 -53 37.5 -90.5t90.5 -37.5h818q-50 55 -50 128t50 128h-818q-53 0 -90.5 -37.5t-37.5 -90.5z" />
90
+ <glyph unicode="&#xf500;" d="M128 0l960 960l960 -960h-1920z" />
91
+ <glyph unicode="&#xf501;" d="M0 128l960 960l-960 960v-1920z" />
92
+ <glyph unicode="&#xf502;" d="M128 2048l960 -960l960 960h-1920z" />
93
+ <glyph unicode="&#xf503;" d="M1088 1088l960 960v-1920z" />
94
+ </font>
95
+ </defs></svg>
assets/font/genericons-regular-webfont.ttf ADDED
Binary file
assets/font/genericons-regular-webfont.woff ADDED
Binary file
assets/images/ajax-loader.gif ADDED
Binary file
assets/images/briefcase-menu.png ADDED
Binary file
assets/images/briefcase.png ADDED
Binary file
assets/images/company.png ADDED
Binary file
assets/images/featured_head.png ADDED
Binary file
assets/images/icons/approve.png ADDED
Binary file
assets/images/icons/delete.png ADDED
Binary file
assets/images/icons/edit.png ADDED
Binary file
assets/images/icons/view.png ADDED
Binary file
assets/images/on.png ADDED
Binary file
assets/js/admin.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function($) {
2
+ // Tooltips
3
+ $( ".tips, .help_tip" ).tipTip({
4
+ 'attribute' : 'data-tip',
5
+ 'fadeIn' : 50,
6
+ 'fadeOut' : 50,
7
+ 'delay' : 200
8
+ });
9
+ });
assets/js/admin.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function(e){e(".tips, .help_tip").tipTip({attribute:"data-tip",fadeIn:50,fadeOut:50,delay:200})});
assets/js/ajax-filters.js ADDED
@@ -0,0 +1,127 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function($) {
2
+
3
+ var xhr;
4
+
5
+ function update_job_listing_results( page, append, target ) {
6
+
7
+ var form = target.find( '.job_filters' );
8
+ var showing = target.find( '.showing_jobs' );
9
+ var results = target.find( '.job_listings' );
10
+
11
+ if (xhr) xhr.abort();
12
+
13
+ if ( append ) {
14
+ $( '.load_more_jobs', target ).addClass('loading');
15
+ } else {
16
+ $(results).addClass('loading');
17
+ $('li.job_listing', results).css('visibility', 'hidden');
18
+ }
19
+
20
+ var filter_job_type = new Array();
21
+
22
+ $('input[name="filter_job_type[]"]:checked', form).each(function() {
23
+ filter_job_type.push( $(this).val() );
24
+ });
25
+
26
+ var categories = form.find('select[name^=search_categories], input[name^=search_categories]').map(function () { return $(this).val(); }).get();
27
+
28
+ var data = {
29
+ action: 'job_manager_get_listings',
30
+ search_keywords: form.find('input[name=search_keywords]').val(),
31
+ search_location: form.find('input[name=search_location]').val(),
32
+ search_categories: categories,
33
+ filter_job_type: filter_job_type,
34
+ per_page: form.find('input[name=per_page]').val(),
35
+ orderby: form.find('input[name=orderby]').val(),
36
+ order: form.find('input[name=order]').val(),
37
+ page: page
38
+ };
39
+
40
+ xhr = $.ajax( {
41
+ type: 'POST',
42
+ url: job_manager_ajax_filters.ajax_url,
43
+ data: data,
44
+ success: function( response ) {
45
+ if ( response ) {
46
+ try {
47
+
48
+ // Get the valid JSON only from the returned string
49
+ if ( response.indexOf("<!--WPJM-->") >= 0 )
50
+ response = response.split("<!--WPJM-->")[1]; // Strip off before WPJM
51
+
52
+ if ( response.indexOf("<!--WPJM_END-->") >= 0 )
53
+ response = response.split("<!--WPJM_END-->")[0]; // Strip off anything after WPJM_END
54
+
55
+ var result = $.parseJSON( response );
56
+
57
+ if ( result.showing )
58
+ $(showing).show().find('span').html( result.showing );
59
+ else
60
+ $(showing).hide();
61
+
62
+ if ( result.rss )
63
+ $(showing).find('.rss_link').attr('href', result.rss).show();
64
+ else
65
+ $(showing).find('.rss_link').hide();
66
+
67
+ if ( result.html )
68
+ if ( append )
69
+ $(results).append( result.html );
70
+ else
71
+ $(results).html( result.html );
72
+
73
+ if ( ! result.found_jobs || result.max_num_pages == page )
74
+ $( '.load_more_jobs', target ).hide();
75
+ else
76
+ $( '.load_more_jobs', target ).show().data('page', page);
77
+
78
+ $(results).removeClass('loading');
79
+ $( '.load_more_jobs', target ).removeClass('loading');
80
+ $('li.job_listing', results).css('visibility', 'visible');
81
+
82
+ } catch(err) {
83
+ console.log(err);
84
+ }
85
+ }
86
+ }
87
+ } );
88
+ }
89
+
90
+ $( '#search_keywords, #search_location, .job_types input, #search_categories' ).change( function() {
91
+ var target = $(this).closest( 'div.job_listings' );
92
+
93
+ update_job_listing_results( 1, false, target );
94
+ } ).change();
95
+
96
+ $( '.showing_jobs .reset' ).click( function() {
97
+ var target = $(this).closest( 'div.job_listings' );
98
+ var form = $(this).closest( 'form' );
99
+
100
+ form.find('input[name=search_keywords]').val('');
101
+ form.find('input[name=search_location]').val('');
102
+ form.find('select[name^=search_categories]').val('');
103
+ $('input[name="filter_job_type[]"]', form).attr('checked', 'checked');
104
+
105
+ update_job_listing_results( 1, false, target );
106
+
107
+ return false;
108
+ } );
109
+
110
+ $( '.load_more_jobs' ).click(function() {
111
+ var target = $(this).closest( 'div.job_listings' );
112
+
113
+ page = $(this).data( 'page' );
114
+
115
+ if ( ! page )
116
+ page = 1;
117
+ else
118
+ page = parseInt( page );
119
+
120
+ $(this).data( 'page', ( page + 1 ) );
121
+
122
+ update_job_listing_results( page + 1, true, target );
123
+
124
+ return false;
125
+ } );
126
+
127
+ });
assets/js/ajax-filters.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function(e){function n(n,r,i){var s=i.find(".job_filters"),o=i.find(".showing_jobs"),u=i.find(".job_listings");t&&t.abort();if(r)e(".load_more_jobs",i).addClass("loading");else{e(u).addClass("loading");e("li.job_listing",u).css("visibility","hidden")}var a=new Array;e('input[name="filter_job_type[]"]:checked',s).each(function(){a.push(e(this).val())});var f=s.find("select[name^=search_categories], input[name^=search_categories]").map(function(){return e(this).val()}).get(),l={action:"job_manager_get_listings",search_keywords:s.find("input[name=search_keywords]").val(),search_location:s.find("input[name=search_location]").val(),search_categories:f,filter_job_type:a,per_page:s.find("input[name=per_page]").val(),orderby:s.find("input[name=orderby]").val(),order:s.find("input[name=order]").val(),page:n};t=e.ajax({type:"POST",url:job_manager_ajax_filters.ajax_url,data:l,success:function(t){if(t)try{t.indexOf("<!--WPJM-->")>=0&&(t=t.split("<!--WPJM-->")[1]);t.indexOf("<!--WPJM_END-->")>=0&&(t=t.split("<!--WPJM_END-->")[0]);var s=e.parseJSON(t);s.showing?e(o).show().find("span").html(s.showing):e(o).hide();s.rss?e(o).find(".rss_link").attr("href",s.rss).show():e(o).find(".rss_link").hide();s.html&&(r?e(u).append(s.html):e(u).html(s.html));!s.found_jobs||s.max_num_pages==n?e(".load_more_jobs",i).hide():e(".load_more_jobs",i).show().data("page",n);e(u).removeClass("loading");e(".load_more_jobs",i).removeClass("loading");e("li.job_listing",u).css("visibility","visible")}catch(a){console.log(a)}}})}var t;e("#search_keywords, #search_location, .job_types input, #search_categories").change(function(){var t=e(this).closest("div.job_listings");n(1,!1,t)}).change();e(".showing_jobs .reset").click(function(){var t=e(this).closest("div.job_listings"),r=e(this).closest("form");r.find("input[name=search_keywords]").val("");r.find("input[name=search_location]").val("");r.find("select[name^=search_categories]").val("");e('input[name="filter_job_type[]"]',r).attr("checked","checked");n(1,!1,t);return!1});e(".load_more_jobs").click(function(){var t=e(this).closest("div.job_listings");page=e(this).data("page");page?page=parseInt(page):page=1;e(this).data("page",page+1);n(page+1,!0,t);return!1})});
assets/js/job-application.js ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function($) {
2
+ // Slide toggle
3
+ jQuery( '.application_details' ).hide();
4
+ jQuery( '.application_button' ).click(function() {
5
+ jQuery( '.application_details' ).slideToggle();
6
+ });
7
+
8
+ // De-code emails
9
+ jQuery( '.job_application_email' ).each(function() {
10
+ var text = jQuery(this).html();
11
+ var href = jQuery(this).attr( 'href' );
12
+
13
+ text = text.replace( /(\[|\()at(\]|\))/i, '@' );
14
+ text = text.replace( /(\[|\()dot(\]|\))/ig, '.' );
15
+ text = text.replace( / /g, '' );
16
+
17
+ href = href.replace( /(\[|\()at(\]|\))/i, '@' );
18
+ href = href.replace( /(\[|\()dot(\]|\))/ig, '.' );
19
+ href = href.replace( / /g, '' );
20
+
21
+ jQuery(this).html( text );
22
+ jQuery(this).attr( 'href', href );
23
+ });
24
+ });
assets/js/job-application.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function(e){jQuery(".application_details").hide();jQuery(".application_button").click(function(){jQuery(".application_details").slideToggle()});jQuery(".job_application_email").each(function(){var e=jQuery(this).html(),t=jQuery(this).attr("href");e=e.replace(/(\[|\()at(\]|\))/i,"@");e=e.replace(/(\[|\()dot(\]|\))/ig,".");e=e.replace(/ /g,"");t=t.replace(/(\[|\()at(\]|\))/i,"@");t=t.replace(/(\[|\()dot(\]|\))/ig,".");t=t.replace(/ /g,"");jQuery(this).html(e);jQuery(this).attr("href",t)})});
assets/js/job-dashboard.js ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ jQuery(document).ready(function($) {
2
+
3
+ $('.job-dashboard-action-delete').click(function() {
4
+ var answer = confirm( job_manager_job_dashboard.i18n_confirm_delete );
5
+
6
+ if (answer)
7
+ return true;
8
+
9
+ return false;
10
+ });
11
+
12
+ });
assets/js/job-dashboard.min.js ADDED
@@ -0,0 +1 @@
 
1
+ jQuery(document).ready(function(e){e(".job-dashboard-action-delete").click(function(){var e=confirm(job_manager_job_dashboard.i18n_confirm_delete);return e?!0:!1})});
assets/js/jquery-tiptip/jquery.tipTip.js ADDED
@@ -0,0 +1,191 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ * TipTip
3
+ * Copyright 2010 Drew Wilson
4
+ * www.drewwilson.com
5
+ * code.drewwilson.com/entry/tiptip-jquery-plugin
6
+ *
7
+ * Version 1.3 - Updated: Mar. 23, 2010
8
+ *
9
+ * This Plug-In will create a custom tooltip to replace the default
10
+ * browser tooltip. It is extremely lightweight and very smart in
11
+ * that it detects the edges of the browser window and will make sure
12
+ * the tooltip stays within the current window size. As a result the
13
+ * tooltip will adjust itself to be displayed above, below, to the left
14
+ * or to the right depending on what is necessary to stay within the
15
+ * browser window. It is completely customizable as well via CSS.
16
+ *
17
+ * This TipTip jQuery plug-in is dual licensed under the MIT and GPL licenses:
18
+ * http://www.opensource.org/licenses/mit-license.php
19
+ * http://www.gnu.org/licenses/gpl.html
20
+ */
21
+
22
+ (function($){
23
+ $.fn.tipTip = function(options) {
24
+ var defaults = {
25
+ activation: "hover",
26
+ keepAlive: false,
27
+ maxWidth: "200px",
28
+ edgeOffset: 3,
29
+ defaultPosition: "bottom",
30
+ delay: 400,
31
+ fadeIn: 200,
32
+ fadeOut: 200,
33
+ attribute: "title",
34
+ content: false, // HTML or String to fill TipTIp with
35
+ enter: function(){},
36
+ exit: function(){}
37
+ };
38
+ var opts = $.extend(defaults, options);
39
+
40
+ // Setup tip tip elements and render them to the DOM
41
+ if($("#tiptip_holder").length <= 0){
42
+ var tiptip_holder = $('<div id="tiptip_holder" style="max-width:'+ opts.maxWidth +';"></div>');
43
+ var tiptip_content = $('<div id="tiptip_content"></div>');
44
+ var tiptip_arrow = $('<div id="tiptip_arrow"></div>');
45
+ $("body").append(tiptip_holder.html(tiptip_content).prepend(tiptip_arrow.html('<div id="tiptip_arrow_inner"></div>')));
46
+ } else {
47
+ var tiptip_holder = $("#tiptip_holder");
48
+ var tiptip_content = $("#tiptip_content");
49
+ var tiptip_arrow = $("#tiptip_arrow");
50
+ }
51
+
52
+ return this.each(function(){
53
+ var org_elem = $(this);
54
+ if(opts.content){
55
+ var org_title = opts.content;
56
+ } else {
57
+ var org_title = org_elem.attr(opts.attribute);
58
+ }
59
+ if(org_title != ""){
60
+ if(!opts.content){
61
+ org_elem.removeAttr(opts.attribute); //remove original Attribute
62
+ }
63
+ var timeout = false;
64
+
65
+ if(opts.activation == "hover"){
66
+ org_elem.hover(function(){
67
+ active_tiptip();
68
+ }, function(){
69
+ if(!opts.keepAlive){
70
+ deactive_tiptip();
71
+ }
72
+ });
73
+ if(opts.keepAlive){
74
+ tiptip_holder.hover(function(){}, function(){
75
+ deactive_tiptip();
76
+ });
77
+ }
78
+ } else if(opts.activation == "focus"){
79
+ org_elem.focus(function(){
80
+ active_tiptip();
81
+ }).blur(function(){
82
+ deactive_tiptip();
83
+ });
84
+ } else if(opts.activation == "click"){
85
+ org_elem.click(function(){
86
+ active_tiptip();
87
+ return false;
88
+ }).hover(function(){},function(){
89
+ if(!opts.keepAlive){
90
+ deactive_tiptip();
91
+ }
92
+ });
93
+ if(opts.keepAlive){
94
+ tiptip_holder.hover(function(){}, function(){
95
+ deactive_tiptip();
96
+ });
97
+ }
98
+ }
99
+
100
+ function active_tiptip(){
101
+ opts.enter.call(this);
102
+ tiptip_content.html(org_title);
103
+ tiptip_holder.hide().removeAttr("class").css("margin","0");
104
+ tiptip_arrow.removeAttr("style");
105
+
106
+ var top = parseInt(org_elem.offset()['top']);
107
+ var left = parseInt(org_elem.offset()['left']);
108
+ var org_width = parseInt(org_elem.outerWidth());
109
+ var org_height = parseInt(org_elem.outerHeight());
110
+ var tip_w = tiptip_holder.outerWidth();
111
+ var tip_h = tiptip_holder.outerHeight();
112
+ var w_compare = Math.round((org_width - tip_w) / 2);
113
+ var h_compare = Math.round((org_height - tip_h) / 2);
114
+ var marg_left = Math.round(left + w_compare);
115
+ var marg_top = Math.round(top + org_height + opts.edgeOffset);
116
+ var t_class = "";
117
+ var arrow_top = "";
118
+ var arrow_left = Math.round(tip_w - 12) / 2;
119
+
120
+ if(opts.defaultPosition == "bottom"){
121
+ t_class = "_bottom";
122
+ } else if(opts.defaultPosition == "top"){
123
+ t_class = "_top";
124
+ } else if(opts.defaultPosition == "left"){
125
+ t_class = "_left";
126
+ } else if(opts.defaultPosition == "right"){
127
+ t_class = "_right";
128
+ }
129
+
130
+ var right_compare = (w_compare + left) < parseInt($(window).scrollLeft());
131
+ var left_compare = (tip_w + left) > parseInt($(window).width());
132
+
133
+ if((right_compare && w_compare < 0) || (t_class == "_right" && !left_compare) || (t_class == "_left" && left < (tip_w + opts.edgeOffset + 5))){
134
+ t_class = "_right";
135
+ arrow_top = Math.round(tip_h - 13) / 2;
136
+ arrow_left = -12;
137
+ marg_left = Math.round(left + org_width + opts.edgeOffset);
138
+ marg_top = Math.round(top + h_compare);
139
+ } else if((left_compare && w_compare < 0) || (t_class == "_left" && !right_compare)){
140
+ t_class = "_left";
141
+ arrow_top = Math.round(tip_h - 13) / 2;
142
+ arrow_left = Math.round(tip_w);
143
+ marg_left = Math.round(left - (tip_w + opts.edgeOffset + 5));
144
+ marg_top = Math.round(top + h_compare);
145
+ }
146
+
147
+ var top_compare = (top + org_height + opts.edgeOffset + tip_h + 8) > parseInt($(window).height() + $(window).scrollTop());
148
+ var bottom_compare = ((top + org_height) - (opts.edgeOffset + tip_h + 8)) < 0;
149
+
150
+ if(top_compare || (t_class == "_bottom" && top_compare) || (t_class == "_top" && !bottom_compare)){
151
+ if(t_class == "_top" || t_class == "_bottom"){
152
+ t_class = "_top";
153
+ } else {
154
+ t_class = t_class+"_top";
155
+ }
156
+ arrow_top = tip_h;
157
+ marg_top = Math.round(top - (tip_h + 5 + opts.edgeOffset));
158
+ } else if(bottom_compare | (t_class == "_top" && bottom_compare) || (t_class == "_bottom" && !top_compare)){
159
+ if(t_class == "_top" || t_class == "_bottom"){
160
+ t_class = "_bottom";
161
+ } else {
162
+ t_class = t_class+"_bottom";
163
+ }
164
+ arrow_top = -12;
165
+ marg_top = Math.round(top + org_height + opts.edgeOffset);
166
+ }
167
+
168
+ if(t_class == "_right_top" || t_class == "_left_top"){
169
+ marg_top = marg_top + 5;
170
+ } else if(t_class == "_right_bottom" || t_class == "_left_bottom"){
171
+ marg_top = marg_top - 5;
172
+ }
173
+ if(t_class == "_left_top" || t_class == "_left_bottom"){
174
+ marg_left = marg_left + 5;
175
+ }
176
+ tiptip_arrow.css({"margin-left": arrow_left+"px", "margin-top": arrow_top+"px"});
177
+ tiptip_holder.css({"margin-left": marg_left+"px", "margin-top": marg_top+"px"}).attr("class","tip"+t_class);
178
+
179
+ if (timeout){ clearTimeout(timeout); }
180
+ timeout = setTimeout(function(){ tiptip_holder.stop(true,true).fadeIn(opts.fadeIn); }, opts.delay);
181
+ }
182
+
183
+ function deactive_tiptip(){
184
+ opts.exit.call(this);
185
+ if (timeout){ clearTimeout(timeout); }
186
+ tiptip_holder.fadeOut(opts.fadeOut);
187
+ }
188
+ }
189
+ });
190
+ }
191
+ })(jQuery);
assets/js/jquery-tiptip/jquery.tipTip.min.js ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ * TipTip
3
+ * Copyright 2010 Drew Wilson
4
+ * www.drewwilson.com
5
+ * code.drewwilson.com/entry/tiptip-jquery-plugin
6
+ *
7
+ * Version 1.3 - Updated: Mar. 23, 2010
8
+ *
9
+ * This Plug-In will create a custom tooltip to replace the default
10
+ * browser tooltip. It is extremely lightweight and very smart in
11
+ * that it detects the edges of the browser window and will make sure
12
+ * the tooltip stays within the current window size. As a result the
13
+ * tooltip will adjust itself to be displayed above, below, to the left
14
+ * or to the right depending on what is necessary to stay within the
15
+ * browser window. It is completely customizable as well via CSS.
16
+ *
17
+ * This TipTip jQuery plug-in is dual licensed under the MIT and GPL licenses:
18
+ * http://www.opensource.org/licenses/mit-license.php
19
+ * http://www.gnu.org/licenses/gpl.html
20
+ */(function(e){e.fn.tipTip=function(t){var n={activation:"hover",keepAlive:!1,maxWidth:"200px",edgeOffset:3,defaultPosition:"bottom",delay:400,fadeIn:200,fadeOut:200,attribute:"title",content:!1,enter:function(){},exit:function(){}},r=e.extend(n,t);if(e("#tiptip_holder").length<=0){var i=e('<div id="tiptip_holder" style="max-width:'+r.maxWidth+';"></div>'),s=e('<div id="tiptip_content"></div>'),o=e('<div id="tiptip_arrow"></div>');e("body").append(i.html(s).prepend(o.html('<div id="tiptip_arrow_inner"></div>')))}else var i=e("#tiptip_holder"),s=e("#tiptip_content"),o=e("#tiptip_arrow");return this.each(function(){var t=e(this);if(r.content)var n=r.content;else var n=t.attr(r.attribute);if(n!=""){r.content||t.removeAttr(r.attribute);var u=!1;if(r.activation=="hover"){t.hover(function(){a()},function(){r.keepAlive||f()});r.keepAlive&&i.hover(function(){},function(){f()})}else if(r.activation=="focus")t.focus(function(){a()}).blur(function(){f()});else if(r.activation=="click"){t.click(function(){a();return!1}).hover(function(){},function(){r.keepAlive||f()});r.keepAlive&&i.hover(function(){},function(){f()})}function a(){r.enter.call(this);s.html(n);i.hide().removeAttr("class").css("margin","0");o.removeAttr("style");var a=parseInt(t.offset().top),f=parseInt(t.offset().left),l=parseInt(t.outerWidth()),c=parseInt(t.outerHeight()),h=i.outerWidth(),p=i.outerHeight(),d=Math.round((l-h)/2),v=Math.round((c-p)/2),m=Math.round(f+d),g=Math.round(a+c+r.edgeOffset),y="",b="",w=Math.round(h-12)/2;r.defaultPosition=="bottom"?y="_bottom":r.defaultPosition=="top"?y="_top":r.defaultPosition=="left"?y="_left":r.defaultPosition=="right"&&(y="_right");var E=d+f<parseInt(e(window).scrollLeft()),S=h+f>parseInt(e(window).width());if(E&&d<0||y=="_right"&&!S||y=="_left"&&f<h+r.edgeOffset+5){y="_right";b=Math.round(p-13)/2;w=-12;m=Math.round(f+l+r.edgeOffset);g=Math.round(a+v)}else if(S&&d<0||y=="_left"&&!E){y="_left";b=Math.round(p-13)/2;w=Math.round(h);m=Math.round(f-(h+r.edgeOffset+5));g=Math.round(a+v)}var x=a+c+r.edgeOffset+p+8>parseInt(e(window).height()+e(window).scrollTop()),T=a+c-(r.edgeOffset+p+8)<0;if(x||y=="_bottom"&&x||y=="_top"&&!T){y=="_top"||y=="_bottom"?y="_top":y+="_top";b=p;g=Math.round(a-(p+5+r.edgeOffset))}else if(T|(y=="_top"&&T)||y=="_bottom"&&!x){y=="_top"||y=="_bottom"?y="_bottom":y+="_bottom";b=-12;g=Math.round(a+c+r.edgeOffset)}if(y=="_right_top"||y=="_left_top")g+=5;else if(y=="_right_bottom"||y=="_left_bottom")g-=5;if(y=="_left_top"||y=="_left_bottom")m+=5;o.css({"margin-left":w+"px","margin-top":b+"px"});i.css({"margin-left":m+"px","margin-top":g+"px"}).attr("class","tip"+y);u&&clearTimeout(u);u=setTimeout(function(){i.stop(!0,!0).fadeIn(r.fadeIn)},r.delay)}function f(){r.exit.call(this);u&&clearTimeout(u);i.fadeOut(r.fadeOut)}}})}})(jQuery);
includes/abstracts/abstract-wp-job-manager-form.php ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Abstract WP_Job_Manager_Form class.
5
+ *
6
+ * @abstract
7
+ */
8
+ abstract class WP_Job_Manager_Form {
9
+
10
+ protected static $fields;
11
+ protected static $action;
12
+ protected static $errors = array();
13
+
14
+ /**
15
+ * Add an error
16
+ * @param string $error
17
+ */
18
+ public static function add_error( $error ) {
19
+ self::$errors[] = $error;
20
+ }
21
+
22
+ /**
23
+ * Show errors
24
+ */
25
+ public static function show_errors() {
26
+ foreach ( self::$errors as $error )
27
+ echo '<div class="job-manager-error">' . $error . '</div>';
28
+ }
29
+
30
+ /**
31
+ * Get action
32
+ *
33
+ * @return string
34
+ */
35
+ public static function get_action() {
36
+ return self::$action;
37
+ }
38
+
39
+ /**
40
+ * get_fields function.
41
+ *
42
+ * @access public
43
+ * @param mixed $key
44
+ * @return void
45
+ */
46
+ public static function get_fields( $key ) {
47
+ if ( empty( self::$fields[ $key ] ) )
48
+ return;
49
+
50
+ $fields = self::$fields[ $key ];
51
+
52
+ uasort( $fields, __CLASS__ . '::priority_cmp' );
53
+
54
+ return $fields;
55
+ }
56
+
57
+ /**
58
+ * priority_cmp function.
59
+ *
60
+ * @access private
61
+ * @param mixed $a
62
+ * @param mixed $b
63
+ * @return void
64
+ */
65
+ public static function priority_cmp( $a, $b ) {
66
+ if ( $a['priority'] == $b['priority'] )
67
+ return 0;
68
+ return ( $a['priority'] < $b['priority'] ) ? -1 : 1;
69
+ }
70
+ }
includes/admin/class-wp-job-manager-admin.php ADDED
@@ -0,0 +1,63 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_Admin class.
7
+ */
8
+ class WP_Job_Manager_Admin {
9
+
10
+ /**
11
+ * __construct function.
12
+ *
13
+ * @access public
14
+ * @return void
15
+ */
16
+ public function __construct() {
17
+ include_once( 'class-wp-job-manager-cpt.php' );
18
+ include_once( 'class-wp-job-manager-settings.php' );
19
+ include_once( 'class-wp-job-manager-writepanels.php' );
20
+
21
+ $this->settings_page = new WP_Job_Manager_Settings();
22
+
23
+ add_action( 'admin_menu', array( $this, 'admin_menu' ), 12 );
24
+ add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue_scripts' ) );
25
+ }
26
+
27
+ /**
28
+ * admin_enqueue_scripts function.
29
+ *
30
+ * @access public
31
+ * @return void
32
+ */
33
+ public function admin_enqueue_scripts() {
34
+ global $job_manager;
35
+
36
+ wp_enqueue_style( 'job_manager_admin_menu_css', JOB_MANAGER_PLUGIN_URL . '/assets/css/menu.css' );
37
+ wp_enqueue_style( 'job_manager_admin_css', JOB_MANAGER_PLUGIN_URL . '/assets/css/admin.css' );
38
+ wp_register_script( 'jquery-tiptip', JOB_MANAGER_PLUGIN_URL. '/assets/js/jquery-tiptip/jquery.tipTip.min.js', array( 'jquery' ), JOB_MANAGER_VERSION, true );
39
+ wp_enqueue_script( 'job_manager_admin_js', JOB_MANAGER_PLUGIN_URL. '/assets/js/admin.min.js', array( 'jquery', 'jquery-tiptip' ), JOB_MANAGER_VERSION, true );
40
+ }
41
+
42
+ /**
43
+ * admin_menu function.
44
+ *
45
+ * @access public
46
+ * @return void
47
+ */
48
+ public function admin_menu() {
49
+ add_submenu_page( 'edit.php?post_type=job_listing', __( 'Settings', 'job_manager' ), __( 'Settings', 'job_manager' ), 'manage_options', 'job-manager-settings', array( $this->settings_page, 'output' ) );
50
+ }
51
+
52
+ /**
53
+ * admin_dashboard function.
54
+ *
55
+ * @access public
56
+ * @return void
57
+ */
58
+ public function admin_dashboard() {
59
+ include_once( 'class-dlm-admin-dashboard.php' );
60
+ }
61
+ }
62
+
63
+ new WP_Job_Manager_Admin();
includes/admin/class-wp-job-manager-category-walker.php ADDED
@@ -0,0 +1,48 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
3
+
4
+ /**
5
+ * WP_Job_Manager_Category_Walker class.
6
+ *
7
+ * @extends Walker
8
+ */
9
+ class WP_Job_Manager_Category_Walker extends Walker {
10
+
11
+ var $tree_type = 'category';
12
+ var $db_fields = array ('parent' => 'parent', 'id' => 'term_id', 'slug' => 'slug' );
13
+
14
+ /**
15
+ * @see Walker::start_el()
16
+ * @since 2.1.0
17
+ *
18
+ * @param string $output Passed by reference. Used to append additional content.
19
+ * @param object $category Category data object.
20
+ * @param int $depth Depth of category in reference to parents.
21
+ * @param array $args
22
+ */
23
+ function start_el( $output, $cat, $depth, $args ) {
24
+
25
+ if ( ! empty( $args['hierarchical'] ) )
26
+ $pad = str_repeat('&nbsp;', $depth * 3);
27
+ else
28
+ $pad = '';
29
+
30
+ $cat_name = apply_filters( 'list_product_cats', $cat->name, $cat );
31
+
32
+ $value = isset( $args['value'] ) && $args['value'] == 'id' ? $cat->term_id : $cat->slug;
33
+
34
+ $output .= "\t<option class=\"level-$depth\" value=\"" . $value . "\"";
35
+
36
+ if ( $value == $args['selected'] || ( is_array( $args['selected'] ) && in_array( $value, $args['selected'] ) ) )
37
+ $output .= ' selected="selected"';
38
+
39
+ $output .= '>';
40
+
41
+ $output .= $pad . __( $cat_name, 'download_monitor' );
42
+
43
+ if ( ! empty( $args['show_count'] ) )
44
+ $output .= '&nbsp;(' . $cat->count . ')';
45
+
46
+ $output .= "</option>\n";
47
+ }
48
+ }
includes/admin/class-wp-job-manager-cpt.php ADDED
@@ -0,0 +1,387 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_CPT class.
7
+ */
8
+ class WP_Job_Manager_CPT {
9
+
10
+ /**
11
+ * __construct function.
12
+ *
13
+ * @access public
14
+ * @return void
15
+ */
16
+ public function __construct() {
17
+ add_filter( 'enter_title_here', array( $this, 'enter_title_here' ), 1, 2 );
18
+ add_filter( 'manage_edit-job_listing_columns', array( $this, 'columns' ) );
19
+ add_action( 'manage_job_listing_posts_custom_column', array( $this, 'custom_columns' ), 2 );
20
+ add_filter( 'post_updated_messages', array( $this, 'post_updated_messages' ) );
21
+ add_action( 'admin_footer-edit.php', array( $this, 'add_bulk_actions' ) );
22
+ add_action( 'load-edit.php', array( $this, 'do_bulk_actions' ) );
23
+ add_action( 'admin_init', array( $this, 'approve_job' ) );
24
+ add_action( 'admin_notices', array( $this, 'approved_notice' ) );
25
+
26
+ if ( get_option( 'job_manager_enable_categories' ) )
27
+ add_action( "restrict_manage_posts", array( $this, "jobs_by_category" ) );
28
+
29
+ foreach ( array( 'post', 'post-new' ) as $hook )
30
+ add_action( "admin_footer-{$hook}.php", array( $this,'extend_submitdiv_post_status' ) );
31
+ }
32
+
33
+ /**
34
+ * Edit bulk actions
35
+ */
36
+ public function add_bulk_actions() {
37
+ global $post_type;
38
+
39
+ if ( $post_type == 'job_listing' ) {
40
+ ?>
41
+ <script type="text/javascript">
42
+ jQuery(document).ready(function() {
43
+ jQuery('<option>').val('approve_jobs').text('<?php _e( 'Approve Jobs', 'job_manager' )?>').appendTo("select[name='action']");
44
+ jQuery('<option>').val('approve_jobs').text('<?php _e( 'Approve Jobs', 'job_manager' )?>').appendTo("select[name='action2']");
45
+ });
46
+ </script>
47
+ <?php
48
+ }
49
+ }
50
+
51
+ /**
52
+ * Do custom bulk actions
53
+ */
54
+ public function do_bulk_actions() {
55
+ $wp_list_table = _get_list_table( 'WP_Posts_List_Table' );
56
+ $action = $wp_list_table->current_action();
57
+
58
+ switch( $action ) {
59
+ case 'approve_jobs' :
60
+ check_admin_referer( 'bulk-posts' );
61
+
62
+ $post_ids = array_map( 'absint', array_filter( (array) $_GET['post'] ) );
63
+ $approved_jobs = array();
64
+
65
+ if ( ! empty( $post_ids ) )
66
+ foreach( $post_ids as $post_id ) {
67
+ $job_data = array(
68
+ 'ID' => $post_id,
69
+ 'post_status' => 'publish'
70
+ );
71
+ if ( get_post_status( $post_id ) == 'pending' && wp_update_post( $job_data ) )
72
+ $approved_jobs[] = $post_id;
73
+ }
74
+
75
+ wp_redirect( remove_query_arg( 'approve_jobs', add_query_arg( 'approved_jobs', $approved_jobs, admin_url( 'edit.php?post_type=job_listing' ) ) ) );
76
+ exit;
77
+ break;
78
+ }
79
+
80
+ return;
81
+ }
82
+
83
+ /**
84
+ * Approve a single job
85
+ */
86
+ public function approve_job() {
87
+ if ( ! empty( $_GET['approve_job'] ) && wp_verify_nonce( $_REQUEST['_wpnonce'], 'approve_job' ) && current_user_can( 'edit_post', $_GET['approve_job'] ) ) {
88
+ $post_id = absint( $_GET['approve_job'] );
89
+ $job_data = array(
90
+ 'ID' => $post_id,
91
+ 'post_status' => 'publish'
92
+ );
93
+ wp_update_post( $job_data );
94
+ wp_redirect( remove_query_arg( 'approve_job', add_query_arg( 'approved_jobs', $post_id, admin_url( 'edit.php?post_type=job_listing' ) ) ) );
95
+ exit;
96
+ }
97
+ }
98
+
99
+ /**
100
+ * Show a notice if we did a bulk action or approval
101
+ */
102
+ public function approved_notice() {
103
+ global $post_type, $pagenow;
104
+
105
+ if ( $pagenow == 'edit.php' && $post_type == 'job_listing' && ! empty( $_REQUEST['approved_jobs'] ) ) {
106
+ $approved_jobs = $_REQUEST['approved_jobs'];
107
+ if ( is_array( $approved_jobs ) ) {
108
+ $approved_jobs = array_map( 'absint', $approved_jobs );
109
+ $titles = array();
110
+ foreach ( $approved_jobs as $job_id )
111
+ $titles[] = get_the_title( $job_id );
112
+ echo '<div class="updated"><p>' . sprintf( __( '%s approved', 'job_manager' ), '&quot;' . implode( '&quot;, &quot;', $titles ) . '&quot;' ) . '</p></div>';
113
+ } else {
114
+ echo '<div class="updated"><p>' . sprintf( __( '%s approved', 'job_manager' ), '&quot;' . get_the_title( $approved_jobs ) . '&quot;' ) . '</p></div>';
115
+ }
116
+ }
117
+ }
118
+
119
+ /**
120
+ * jobs_by_category function.
121
+ *
122
+ * @access public
123
+ * @param int $show_counts (default: 1)
124
+ * @param int $hierarchical (default: 1)
125
+ * @param int $show_uncategorized (default: 1)
126
+ * @param string $orderby (default: '')
127
+ * @return void
128
+ */
129
+ public function jobs_by_category( $show_counts = 1, $hierarchical = 1, $show_uncategorized = 1, $orderby = '' ) {
130
+ global $typenow, $wp_query;
131
+
132
+ if ( $typenow != 'job_listing' || ! taxonomy_exists( 'job_listing_category' ) )
133
+ return;
134
+
135
+ include_once( 'class-wp-job-manager-category-walker.php' );
136
+
137
+ $r = array();
138
+ $r['pad_counts'] = 1;
139
+ $r['hierarchical'] = $hierarchical;
140
+ $r['hide_empty'] = 1;
141
+ $r['show_count'] = $show_counts;
142
+ $r['selected'] = ( isset( $wp_query->query['job_listing_category'] ) ) ? $wp_query->query['job_listing_category'] : '';
143
+
144
+ $r['menu_order'] = false;
145
+
146
+ if ( $orderby == 'order' )
147
+ $r['menu_order'] = 'asc';
148
+ elseif ( $orderby )
149
+ $r['orderby'] = $orderby;
150
+
151
+ $terms = get_terms( 'job_listing_category', $r );
152
+
153
+ if ( ! $terms )
154
+ return;
155
+
156
+ $output = "<select name='job_listing_category' id='dropdown_job_listing_category'>";
157
+ $output .= '<option value="" ' . selected( isset( $_GET['job_listing_category'] ) ? $_GET['job_listing_category'] : '', '', false ) . '>'.__( 'Select a category', "job_manager" ).'</option>';
158
+ $output .= $this->walk_category_dropdown_tree( $terms, 0, $r );
159
+ $output .="</select>";
160
+
161
+ echo $output;
162
+ }
163
+
164
+ /**
165
+ * Walk the Product Categories.
166
+ *
167
+ * @access public
168
+ * @return void
169
+ */
170
+ private function walk_category_dropdown_tree() {
171
+ $args = func_get_args();
172
+
173
+ // the user's options are the third parameter
174
+ if ( empty($args[2]['walker']) || !is_a($args[2]['walker'], 'Walker') )
175
+ $walker = new WP_Job_Manager_Category_Walker;
176
+ else
177
+ $walker = $args[2]['walker'];
178
+
179
+ return call_user_func_array( array( $walker, 'walk' ), $args );
180
+ }
181
+
182
+ /**
183
+ * enter_title_here function.
184
+ *
185
+ * @access public
186
+ * @return void
187
+ */
188
+ public function enter_title_here( $text, $post ) {
189
+ if ( $post->post_type == 'job_listing' )
190
+ return __( 'Job position title', "job_manager" );
191
+ return $text;
192
+ }
193
+
194
+ /**
195
+ * post_updated_messages function.
196
+ *
197
+ * @access public
198
+ * @param mixed $messages
199
+ * @return void
200
+ */
201
+ public function post_updated_messages( $messages ) {
202
+ global $post, $post_ID;
203
+
204
+ $messages['job_listing'] = array(
205
+ 0 => '',
206
+ 1 => sprintf( __( 'Job listing updated. <a href="%s">View Job</a>', "job_manager" ), esc_url( get_permalink( $post_ID ) ) ),
207
+ 2 => __( 'Custom field updated.', "job_manager" ),
208
+ 3 => __( 'Custom field deleted.', "job_manager" ),
209
+ 4 => __( 'Job listing updated.', "job_manager" ),
210
+ 5 => isset( $_GET['revision'] ) ? sprintf( __( 'Job listing restored to revision from %s', "job_manager" ), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,
211
+ 6 => sprintf( __( 'Job listing published. <a href="%s">View Job</a>', "job_manager" ), esc_url( get_permalink( $post_ID ) ) ),
212
+ 7 => __('Job listing saved.', "job_manager"),
213
+ 8 => sprintf( __( 'Job listing submitted. <a target="_blank" href="%s">Preview Job</a>', "job_manager" ), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),
214
+ 9 => sprintf( __( 'Job listing scheduled for: <strong>%1$s</strong>. <a target="_blank" href="%2$s">Preview Job</a>', "job_manager" ),
215
+ date_i18n( __( 'M j, Y @ G:i', "job_manager" ), strtotime( $post->post_date ) ), esc_url( get_permalink( $post_ID ) ) ),
216
+ 10 => sprintf( __( 'Job listing draft updated. <a target="_blank" href="%s">Preview Job</a>', "job_manager" ), esc_url( add_query_arg( 'preview', 'true', get_permalink( $post_ID ) ) ) ),
217
+ );
218
+
219
+ return $messages;
220
+ }
221
+
222
+ /**
223
+ * columns function.
224
+ *
225
+ * @access public
226
+ * @param mixed $columns
227
+ * @return void
228
+ */
229
+ public function columns( $columns ) {
230
+ $columns = array();
231
+
232
+ $columns["cb"] = "<input type=\"checkbox\" />";
233
+ $columns["job_listing_type"] = __( "Type", "job_manager" );
234
+ $columns["position"] = __( "Position", "job_manager" );
235
+ $columns["company"] = __( "Company", "job_manager" );
236
+ $columns["job_posted"] = __( "Posted", "job_manager" );
237
+ $columns["job_expires"] = __( "Expires", "job_manager" );
238
+ if ( get_option( 'job_manager_enable_categories' ) )
239
+ $columns["job_listing_category"] = __( "Categories", "job_manager" );
240
+ $columns['status'] = __( "Job Status", "job_manager" );
241
+ $columns['filled'] = __( "Filled?", "job_manager" );
242
+ $columns["job_actions"] = __( "Actions", "job_manager" );
243
+
244
+ return $columns;
245
+ }
246
+
247
+ /**
248
+ * custom_columns function.
249
+ *
250
+ * @access public
251
+ * @param mixed $column
252
+ * @return void
253
+ */
254
+ public function custom_columns( $column ) {
255
+ global $post, $job_manager;
256
+
257
+ switch ( $column ) {
258
+ case "job_listing_type" :
259
+ $type = get_the_job_type( $post );
260
+ if ( $type )
261
+ echo '<span class="job-type ' . $type->slug . '">' . $type->name . '</span>';
262
+ break;
263
+ case "position" :
264
+ edit_post_link( '#' . $post->ID . ' &ndash; ' . $post->post_title, '<strong>', '</strong>', $post->ID );
265
+ echo '<span class="location">';
266
+ the_job_location( $post );
267
+ echo '</span>';
268
+ break;
269
+ case "company" :
270
+ the_company_logo();
271
+ the_company_twitter();
272
+
273
+ if ( get_the_company_website() )
274
+ the_company_name( '<strong><a href="' . get_the_company_website() . '">', '</a></strong>' );
275
+ else
276
+ the_company_name( '<strong>', '</strong> ' );
277
+
278
+ the_company_tagline( '<span class="tagline">', '</span>' );
279
+ break;
280
+ case "job_listing_category" :
281
+ if ( ! $terms = get_the_term_list( $post->ID, $column, '', ', ', '' ) ) echo '<span class="na">&ndash;</span>'; else echo $terms;
282
+ break;
283
+ case "status" :
284
+ echo get_the_job_status( $post );
285
+ break;
286
+ case "filled" :
287
+ if ( is_position_filled( $post ) ) echo '&#10004;'; else echo '&ndash;';
288
+ break;
289
+ case "job_posted" :
290
+ echo '<strong>' . date_i18n( get_option( 'date_format' ), strtotime( $post->post_date ) ) . '</strong><span>';
291
+ echo ( empty( $post->post_author ) ? __( 'by a guest', 'job_manager' ) : sprintf( __( 'by %s', 'job_manager' ), '<a href="' . get_edit_user_link( $post->post_author ) . '">' . get_the_author() . '</a>' ) ) . '</span>';
292
+ break;
293
+ case "job_expires" :
294
+ if ( $post->_job_expires )
295
+ echo '<strong>' . date_i18n( get_option( 'date_format' ), strtotime( $post->_job_expires ) ) . '</strong>';
296
+ else
297
+ echo '&ndash;';
298
+ break;
299
+ case "job_actions" :
300
+ $admin_actions = array();
301
+ if ( $post->post_status == 'pending' ) {
302
+ $admin_actions['approve'] = array(
303
+ 'action' => 'approve',
304
+ 'name' => __( 'Approve', 'job_manager' ),
305
+ 'url' => wp_nonce_url( add_query_arg( 'approve_job', $post->ID ), 'approve_job' )
306
+ );
307
+ }
308
+ if ( $post->post_status !== 'trash' ) {
309
+ $admin_actions['view'] = array(
310
+ 'action' => 'view',
311
+ 'name' => __( 'View', 'job_manager' ),
312
+ 'url' => get_permalink( $post->ID )
313
+ );
314
+ $admin_actions['edit'] = array(
315
+ 'action' => 'edit',
316
+ 'name' => __( 'Edit', 'job_manager' ),
317
+ 'url' => get_edit_post_link( $post->ID )
318
+ );
319
+ $admin_actions['delete'] = array(
320
+ 'action' => 'delete',
321
+ 'name' => __( 'Delete', 'job_manager' ),
322
+ 'url' => get_delete_post_link( $post->ID )
323
+ );
324
+ }
325
+
326
+ $admin_actions = apply_filters( 'job_manager_admin_actions', $admin_actions, $post );
327
+
328
+ foreach ( $admin_actions as $action ) {
329
+ $image = isset( $action['image_url'] ) ? $action['image_url'] : JOB_MANAGER_PLUGIN_URL . '/assets/images/icons/' . $action['action'] . '.png';
330
+ printf( '<a class="button tips" href="%s" data-tip="%s"><img src="%s" alt="%s" width="14" /></a>', esc_url( $action['url'] ), esc_attr( $action['name'] ), esc_attr( $image ), esc_attr( $action['name'] ) );
331
+ }
332
+
333
+ break;
334
+ }
335
+ }
336
+
337
+ /**
338
+ * Adds post status to the "submitdiv" Meta Box and post type WP List Table screens. Based on https://gist.github.com/franz-josef-kaiser/2930190
339
+ *
340
+ * @return void
341
+ */
342
+ public function extend_submitdiv_post_status() {
343
+ global $wp_post_statuses, $post, $post_type;
344
+
345
+ // Abort if we're on the wrong post type, but only if we got a restriction
346
+ if ( 'job_listing' !== $post_type ) {
347
+ return;
348
+ }
349
+
350
+ // Get all non-builtin post status and add them as <option>
351
+ $options = $display = '';
352
+ foreach ( $wp_post_statuses as $status )
353
+ {
354
+ if ( ! $status->_builtin ) {
355
+ // Match against the current posts status
356
+ $selected = selected( $post->post_status, $status->name, false );
357
+
358
+ // If we one of our custom post status is selected, remember it
359
+ $selected AND $display = $status->label;
360
+
361
+ // Build the options
362
+ $options .= "<option{$selected} value='{$status->name}'>{$status->label}</option>";
363
+ }
364
+ }
365
+ ?>
366
+ <script type="text/javascript">
367
+ jQuery( document ).ready( function($)
368
+ {
369
+ <?php
370
+ // Add the selected post status label to the "Status: [Name] (Edit)"
371
+ if ( ! empty( $display ) ) :
372
+ ?>
373
+ $( '#post-status-display' ).html( '<?php echo $display; ?>' )
374
+ <?php
375
+ endif;
376
+
377
+ // Add the options to the <select> element
378
+ ?>
379
+ var select = $( '#post-status-select' ).find( 'select' );
380
+ $( select ).append( "<?php echo $options; ?>" );
381
+ } );
382
+ </script>
383
+ <?php
384
+ }
385
+ }
386
+
387
+ new WP_Job_Manager_CPT();
includes/admin/class-wp-job-manager-settings.php ADDED
@@ -0,0 +1,226 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_Settings class.
7
+ */
8
+ class WP_Job_Manager_Settings {
9
+
10
+ /**
11
+ * __construct function.
12
+ *
13
+ * @access public
14
+ * @return void
15
+ */
16
+ public function __construct() {
17
+ $this->settings_group = 'job_manager';
18
+ add_action( 'admin_init', array( $this, 'register_settings' ) );
19
+ }
20
+
21
+ /**
22
+ * init_settings function.
23
+ *
24
+ * @access protected
25
+ * @return void
26
+ */
27
+ protected function init_settings() {
28
+ $this->settings = apply_filters( 'job_manager_settings',
29
+ array(
30
+ 'job_listings' => array(
31
+ __( 'Job Listings', 'job_manager' ),
32
+ array(
33
+ array(
34
+ 'name' => 'job_manager_per_page',
35
+ 'std' => '10',
36
+ 'placeholder' => '',
37
+ 'label' => __( 'Jobs per page', 'job_manager' ),
38
+ 'desc' => __( 'How many jobs should be shown per page by default?', 'job_manager' )
39
+ ),
40
+ array(
41
+ 'name' => 'job_manager_hide_filled_positions',
42
+ 'std' => '0',
43
+ 'label' => __( 'Filled positions', 'job_manager' ),
44
+ 'cb_label' => __( 'Hide filled positions', 'job_manager' ),
45
+ 'desc' => __( 'If enabled, filled positions will be hidden from the job list.', 'job_manager' ),
46
+ 'type' => 'checkbox'
47
+ ),
48
+ array(
49
+ 'name' => 'job_manager_enable_categories',
50
+ 'std' => '0',
51
+ 'label' => __( 'Job categories', 'job_manager' ),
52
+ 'cb_label' => __( 'Enable job categories', 'job_manager' ),
53
+ 'desc' => __( 'Choose whether to enable job categories. Categories must be setup by an admin for users to choose during job submission.', 'job_manager' ),
54
+ 'type' => 'checkbox'
55
+ ),
56
+ ),
57
+ ),
58
+ 'job_submission' => array(
59
+ __( 'Job Submission', 'job_manager' ),
60
+ array(
61
+ array(
62
+ 'name' => 'job_manager_enable_registration',
63
+ 'std' => '1',
64
+ 'label' => __( 'Account creation', 'job_manager' ),
65
+ 'cb_label' => __( 'Allow account creation', 'job_manager' ),
66
+ 'desc' => __( 'If enabled, non-logged in users will be able to create an account by entering their email address on the job submission form.', 'job_manager' ),
67
+ 'type' => 'checkbox'
68
+ ),
69
+ array(
70
+ 'name' => 'job_manager_user_requires_account',
71
+ 'std' => '1',
72
+ 'label' => __( 'Account required', 'job_manager' ),
73
+ 'cb_label' => __( 'Job submission requires an account', 'job_manager' ),
74
+ 'desc' => __( 'If disabled, non-logged in users will be able to submit job listings without creating an account.', 'job_manager' ),
75
+ 'type' => 'checkbox'
76
+ ),
77
+ array(
78
+ 'name' => 'job_manager_submission_requires_approval',
79
+ 'std' => '1',
80
+ 'label' => __( 'Approval Required', 'job_manager' ),
81
+ 'cb_label' => __( 'New submissions require admin approval', 'job_manager' ),
82
+ 'desc' => __( 'If enabled, new submissions will be inactive, pending admin approval.', 'job_manager' ),
83
+ 'type' => 'checkbox'
84
+ ),
85
+ array(
86
+ 'name' => 'job_manager_submission_duration',
87
+ 'std' => '30',
88
+ 'label' => __( 'Listing duration', 'job_manager' ),
89
+ 'desc' => __( 'How many <strong>days</strong> listings are live before expiring. Can be left blank to never expire.', 'job_manager' ),
90
+ ),
91
+ )
92
+ ),
93
+ )
94
+ );
95
+ }
96
+
97
+ /**
98
+ * register_settings function.
99
+ *
100
+ * @access public
101
+ * @return void
102
+ */
103
+ public function register_settings() {
104
+ $this->init_settings();
105
+
106
+ foreach ( $this->settings as $section ) {
107
+ foreach ( $section[1] as $option ) {
108
+ if ( isset( $option['std'] ) )
109
+ add_option( $option['name'], $option['std'] );
110
+ register_setting( $this->settings_group, $option['name'] );
111
+ }
112
+ }
113
+ }
114
+
115
+ /**
116
+ * output function.
117
+ *
118
+ * @access public
119
+ * @return void
120
+ */
121
+ public function output() {
122
+ $this->init_settings();
123
+ ?>
124
+ <div class="wrap">
125
+ <form method="post" action="options.php">
126
+
127
+ <?php settings_fields( $this->settings_group ); ?>
128
+ <?php screen_icon(); ?>
129
+
130
+ <h2 class="nav-tab-wrapper">
131
+ <?php
132
+ foreach ( $this->settings as $section ) {
133
+ echo '<a href="#settings-' . sanitize_title( $section[0] ) . '" class="nav-tab">' . esc_html( $section[0] ) . '</a>';
134
+ }
135
+ ?>
136
+ </h2><br/>
137
+
138
+ <?php
139
+ if ( ! empty( $_GET['settings-updated'] ) ) {
140
+ flush_rewrite_rules();
141
+ echo '<div class="updated fade"><p>' . __( 'Settings successfully saved', 'job_manager' ) . '</p></div>';
142
+ }
143
+
144
+ foreach ( $this->settings as $section ) {
145
+
146
+ echo '<div id="settings-' . sanitize_title( $section[0] ) . '" class="settings_panel">';
147
+
148
+ echo '<table class="form-table">';
149
+
150
+ foreach ( $section[1] as $option ) {
151
+
152
+ $placeholder = ( ! empty( $option['placeholder'] ) ) ? 'placeholder="' . $option['placeholder'] . '"' : '';
153
+ $class = ! empty( $option['class'] ) ? $option['class'] : '';
154
+
155
+ echo '<tr valign="top" class="' . $class . '"><th scope="row"><label for="setting-' . $option['name'] . '">' . $option['label'] . '</a></th><td>';
156
+
157
+ if ( ! isset( $option['type'] ) ) $option['type'] = '';
158
+
159
+ $value = get_option( $option['name'] );
160
+
161
+ switch ( $option['type'] ) {
162
+
163
+ case "checkbox" :
164
+
165
+ ?><label><input id="setting-<?php echo $option['name']; ?>" name="<?php echo $option['name']; ?>" type="checkbox" value="1" <?php checked( '1', $value ); ?> /> <?php echo $option['cb_label']; ?></label><?php
166
+
167
+ if ( $option['desc'] )
168
+ echo ' <p class="description">' . $option['desc'] . '</p>';
169
+
170
+ break;
171
+ case "textarea" :
172
+
173
+ ?><textarea id="setting-<?php echo $option['name']; ?>" class="large-text" cols="50" rows="3" name="<?php echo $option['name']; ?>" <?php echo $placeholder; ?>><?php echo esc_textarea( $value ); ?></textarea><?php
174
+
175
+ if ( $option['desc'] )
176
+ echo ' <p class="description">' . $option['desc'] . '</p>';
177
+
178
+ break;
179
+ case "select" :
180
+
181
+ ?><select id="setting-<?php echo $option['name']; ?>" class="regular-text" name="<?php echo $option['name']; ?>"><?php
182
+ foreach( $option['options'] as $key => $name )
183
+ echo '<option value="' . esc_attr( $key ) . '" ' . selected( $value, $key, false ) . '>' . esc_html( $name ) . '</option>';
184
+ ?></select><?php
185
+
186
+ if ( $option['desc'] )
187
+ echo ' <p class="description">' . $option['desc'] . '</p>';
188
+
189
+ break;
190
+ default :
191
+
192
+ ?><input id="setting-<?php echo $option['name']; ?>" class="regular-text" type="text" name="<?php echo $option['name']; ?>" value="<?php esc_attr_e( $value ); ?>" <?php echo $placeholder; ?> /><?php
193
+
194
+ if ( $option['desc'] )
195
+ echo ' <p class="description">' . $option['desc'] . '</p>';
196
+
197
+ break;
198
+
199
+ }
200
+
201
+ echo '</td></tr>';
202
+ }
203
+
204
+ echo '</table></div>';
205
+
206
+ }
207
+ ?>
208
+ <p class="submit">
209
+ <input type="submit" class="button-primary" value="<?php _e( 'Save Changes', 'job_manager' ); ?>" />
210
+ </p>
211
+ </form>
212
+ </div>
213
+ <script type="text/javascript">
214
+ jQuery('.nav-tab-wrapper a').click(function() {
215
+ jQuery('.settings_panel').hide();
216
+ jQuery('.nav-tab-active').removeClass('nav-tab-active');
217
+ jQuery( jQuery(this).attr('href') ).show();
218
+ jQuery(this).addClass('nav-tab-active');
219
+ return false;
220
+ });
221
+
222
+ jQuery('.nav-tab-wrapper a:first').click();
223
+ </script>
224
+ <?php
225
+ }
226
+ }
includes/admin/class-wp-job-manager-writepanels.php ADDED
@@ -0,0 +1,238 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
3
+
4
+ class WP_Job_Manager_Writepanels {
5
+
6
+ /**
7
+ * __construct function.
8
+ *
9
+ * @access public
10
+ * @return void
11
+ */
12
+ public function __construct() {
13
+ add_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );
14
+ add_action( 'save_post', array( $this, 'save_post' ), 1, 2 );
15
+ add_action( 'job_manager_save_job_listing', array( $this, 'save_job_listing_data' ), 1, 2 );
16
+
17
+ $this->job_listing_fields = apply_filters( 'job_manager_job_listing_data_fields', array(
18
+ '_job_location' => array(
19
+ 'label' => __( 'Job location', 'job_manager' ),
20
+ 'placeholder' => __( 'e.g. "London, UK", "New York", "Houston, TX"', 'job_manager' ),
21
+ 'description' => __( 'Leave this blank if the job can be done from anywhere (i.e. telecommuting)', 'job_manager' )
22
+ ),
23
+ '_application' => array(
24
+ 'label' => __( 'Application email/URL', 'job_manager' ),
25
+ 'placeholder' => __( 'URL or email which applicants use to apply', 'job_manager' )
26
+ ),
27
+ '_company_name' => array(
28
+ 'label' => __( 'Company name', 'job_manager' ),
29
+ 'placeholder' => ''
30
+ ),
31
+ '_company_website' => array(
32
+ 'label' => __( 'Company website', 'job_manager' ),
33
+ 'placeholder' => ''
34
+ ),
35
+ '_company_tagline' => array(
36
+ 'label' => __( 'Company tagline', 'job_manager' ),
37
+ 'placeholder' => __( 'Brief description about the company', 'job_manager' )
38
+ ),
39
+ '_company_twitter' => array(
40
+ 'label' => __( 'Company Twitter', 'job_manager' ),
41
+ 'placeholder' => '@yourcompany'
42
+ ),
43
+ '_company_logo' => array(
44
+ 'label' => __( 'Company logo', 'job_manager' ),
45
+ 'placeholder' => __( 'URL to the company logo', 'job_manager' ),
46
+ 'type' => 'file'
47
+ ),
48
+ '_filled' => array(
49
+ 'label' => __( 'Position filled?', 'job_manager' ),
50
+ 'type' => 'checkbox'
51
+ )
52
+ ) );
53
+ }
54
+
55
+ /**
56
+ * add_meta_boxes function.
57
+ *
58
+ * @access public
59
+ * @return void
60
+ */
61
+ public function add_meta_boxes() {
62
+ add_meta_box( 'job_listing_data', __( 'Job Listing Data', 'job_manager' ), array( $this, 'job_listing_data' ), 'job_listing', 'normal', 'high' );
63
+ }
64
+
65
+ /**
66
+ * input_text function.
67
+ *
68
+ * @access private
69
+ * @param mixed $key
70
+ * @param mixed $field
71
+ * @return void
72
+ */
73
+ private function input_file( $key, $field ) {
74
+ global $thepostid;
75
+
76
+ if ( empty( $field['value'] ) )
77
+ $field['value'] = get_post_meta( $thepostid, $key, true );
78
+ ?>
79
+ <p class="form-field">
80
+ <label for="<?php echo esc_attr( $key ); ?>"><?php echo esc_html( $field['label'] ) ; ?>:</label>
81
+ <input type="text" class="file_url" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" placeholder="<?php echo esc_attr( $field['placeholder'] ); ?>" value="<?php echo esc_attr( $field['value'] ); ?>" />
82
+ <?php if ( ! empty( $field['description'] ) ) : ?><span class="description"><?php echo $field['description']; ?></span><?php endif; ?> <button class="button upload_image_button" data-uploader_button_text="<?php _e( 'Use as company logo', 'job_manager' ); ?>"><?php _e( 'Upload company logo', 'job_manager' ); ?></button>
83
+ </p>
84
+ <script type="text/javascript">
85
+ // Uploading files
86
+ var file_frame;
87
+ var file_target_input;
88
+
89
+ jQuery('.upload_image_button').live('click', function( event ){
90
+
91
+ event.preventDefault();
92
+
93
+ file_target_input = jQuery( this ).closest('.form-field').find('.file_url');
94
+
95
+ // If the media frame already exists, reopen it.
96
+ if ( file_frame ) {
97
+ file_frame.open();
98
+ return;
99
+ }
100
+
101
+ // Create the media frame.
102
+ file_frame = wp.media.frames.file_frame = wp.media({
103
+ title: jQuery( this ).data( 'uploader_title' ),
104
+ button: {
105
+ text: jQuery( this ).data( 'uploader_button_text' ),
106
+ },
107
+ multiple: false // Set to true to allow multiple files to be selected
108
+ });
109
+
110
+ // When an image is selected, run a callback.
111
+ file_frame.on( 'select', function() {
112
+ // We set multiple to false so only get one image from the uploader
113
+ attachment = file_frame.state().get('selection').first().toJSON();
114
+
115
+ jQuery( file_target_input ).val( attachment.url );
116
+ });
117
+
118
+ // Finally, open the modal
119
+ file_frame.open();
120
+ });
121
+ </script>
122
+ <?php
123
+ }
124
+
125
+ /**
126
+ * input_text function.
127
+ *
128
+ * @access private
129
+ * @param mixed $key
130
+ * @param mixed $field
131
+ * @return void
132
+ */
133
+ private function input_text( $key, $field ) {
134
+ global $thepostid;
135
+
136
+ if ( empty( $field['value'] ) )
137
+ $field['value'] = get_post_meta( $thepostid, $key, true );
138
+ ?>
139
+ <p class="form-field">
140
+ <label for="<?php echo esc_attr( $key ); ?>"><?php echo esc_html( $field['label'] ) ; ?>:</label>
141
+ <input type="text" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" placeholder="<?php echo esc_attr( $field['placeholder'] ); ?>" value="<?php echo esc_attr( $field['value'] ); ?>" />
142
+ <?php if ( ! empty( $field['description'] ) ) : ?><span class="description"><?php echo $field['description']; ?></span><?php endif; ?>
143
+ </p>
144
+ <?php
145
+ }
146
+
147
+ /**
148
+ * input_checkbox function.
149
+ *
150
+ * @access private
151
+ * @param mixed $key
152
+ * @param mixed $field
153
+ * @return void
154
+ */
155
+ private function input_checkbox( $key, $field ) {
156
+ global $thepostid;
157
+
158
+ if ( empty( $field['value'] ) )
159
+ $field['value'] = get_post_meta( $thepostid, $key, true );
160
+ ?>
161
+ <p class="form-field">
162
+ <label for="<?php echo esc_attr( $key ); ?>"><?php echo esc_html( $field['label'] ) ; ?></label>
163
+ <input type="checkbox" class="checkbox" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" value="1" <?php checked( $field['value'], 1 ); ?> />
164
+ <?php if ( ! empty( $field['description'] ) ) : ?><span class="description"><?php echo $field['description']; ?></span><?php endif; ?>
165
+ </p>
166
+ <?php
167
+ }
168
+
169
+ /**
170
+ * job_listing_data function.
171
+ *
172
+ * @access public
173
+ * @param mixed $post
174
+ * @return void
175
+ */
176
+ public function job_listing_data( $post ) {
177
+ global $post, $thepostid;
178
+
179
+ $thepostid = $post->ID;
180
+
181
+ echo '<div class="wp_job_manager_meta_data">';
182
+
183
+ wp_nonce_field( 'save_meta_data', 'job_manager_nonce' );
184
+
185
+ do_action( 'job_manager_job_listing_data_start', $thepostid );
186
+
187
+ foreach ( $this->job_listing_fields as $key => $field ) {
188
+ $type = ! empty( $field['type'] ) ? $field['type'] : 'text';
189
+
190
+ if ( method_exists( $this, 'input_' . $type ) )
191
+ call_user_func( array( $this, 'input_' . $type ), $key, $field );
192
+ }
193
+
194
+ do_action( 'job_manager_job_listing_data_end', $thepostid );
195
+
196
+ echo '</div>';
197
+ }
198
+
199
+ /**
200
+ * save_post function.
201
+ *
202
+ * @access public
203
+ * @param mixed $post_id
204
+ * @param mixed $post
205
+ * @return void
206
+ */
207
+ public function save_post( $post_id, $post ) {
208
+ if ( empty( $post_id ) || empty( $post ) || empty( $_POST ) ) return;
209
+ if ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) return;
210
+ if ( is_int( wp_is_post_revision( $post ) ) ) return;
211
+ if ( is_int( wp_is_post_autosave( $post ) ) ) return;
212
+ if ( empty($_POST['job_manager_nonce']) || ! wp_verify_nonce( $_POST['job_manager_nonce'], 'save_meta_data' ) ) return;
213
+ if ( ! current_user_can( 'edit_post', $post_id ) ) return;
214
+ if ( $post->post_type != 'job_listing' ) return;
215
+
216
+ do_action( 'job_manager_save_job_listing', $post_id, $post );
217
+ }
218
+
219
+ /**
220
+ * save_job_listing_data function.
221
+ *
222
+ * @access public
223
+ * @param mixed $post_id
224
+ * @param mixed $post
225
+ * @return void
226
+ */
227
+ public function save_job_listing_data( $post_id, $post ) {
228
+ global $wpdb;
229
+
230
+ foreach ( $this->job_listing_fields as $key => $field )
231
+ if ( isset( $_POST[ $key ] ) )
232
+ update_post_meta( $post_id, $key, sanitize_text_field( $_POST[ $key ] ) );
233
+ elseif ( ! empty( $field['type'] ) && $field['type'] == 'checkbox' )
234
+ update_post_meta( $post_id, $key, 0 );
235
+ }
236
+ }
237
+
238
+ new WP_Job_Manager_Writepanels();
includes/class-wp-job-manager-ajax.php ADDED
@@ -0,0 +1,185 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_Ajax class.
7
+ */
8
+ class WP_Job_Manager_Ajax {
9
+
10
+ /**
11
+ * Constructor
12
+ */
13
+ public function __construct() {
14
+ add_action( 'wp_ajax_nopriv_job_manager_get_listings', array( $this, 'get_listings' ) );
15
+ add_action( 'wp_ajax_job_manager_get_listings', array( $this, 'get_listings' ) );
16
+ }
17
+
18
+ /**
19
+ * Get listings via ajax
20
+ */
21
+ public function get_listings() {
22
+ global $job_manager, $wpdb;
23
+
24
+ ob_start();
25
+
26
+ $search_location = sanitize_text_field( stripslashes( $_POST['search_location'] ) );
27
+ $search_keywords = sanitize_text_field( stripslashes( $_POST['search_keywords'] ) );
28
+ $search_categories = isset( $_POST['search_categories'] ) ? $_POST['search_categories'] : '';
29
+ $filter_job_types = isset( $_POST['filter_job_type'] ) ? array_filter( array_map( 'sanitize_title', (array) $_POST['filter_job_type'] ) ) : array();
30
+
31
+ if ( is_array( $search_categories ) ) {
32
+ $search_categories = array_map( 'sanitize_text_field', array_map( 'stripslashes', $search_categories ) );
33
+ } else {
34
+ $search_categories = array( sanitize_text_field( stripslashes( $search_categories ) ), 0 );
35
+ }
36
+
37
+ $search_categories = array_filter( $search_categories );
38
+
39
+ $args = array(
40
+ 'post_type' => 'job_listing',
41
+ 'post_status' => 'publish',
42
+ 'ignore_sticky_posts' => 1,
43
+ 'offset' => ( absint( $_POST['page'] ) - 1 ) * absint( $_POST['per_page'] ),
44
+ 'posts_per_page' => absint( $_POST['per_page'] ),
45
+ 'orderby' => sanitize_text_field( $_POST['orderby'] ),
46
+ 'order' => sanitize_text_field( $_POST['order'] ),
47
+ 'tax_query' => array(
48
+ array(
49
+ 'taxonomy' => 'job_listing_type',
50
+ 'field' => 'slug',
51
+ 'terms' => $filter_job_types + array( 0 )
52
+ )
53
+ ),
54
+ 'meta_query' => array()
55
+ );
56
+
57
+ if ( get_option( 'job_manager_hide_filled_positions' ) == 1 )
58
+ $args['meta_query'][] = array(
59
+ 'key' => '_filled',
60
+ 'value' => '1',
61
+ 'compare' => '!='
62
+ );
63
+
64
+ // Location search
65
+ if ( $search_location )
66
+ $args['meta_query'][] = array(
67
+ 'key' => '_job_location',
68
+ 'value' => $search_location,
69
+ 'compare' => 'LIKE'
70
+ );
71
+
72
+ // Keyword search - search meta as well as post content
73
+ if ( $search_keywords ) {
74
+ $post_ids = $wpdb->get_col( $wpdb->prepare( "
75
+ SELECT DISTINCT post_id FROM {$wpdb->postmeta}
76
+ WHERE meta_value LIKE '%%%s%%'
77
+ ", $search_keywords ) );
78
+
79
+ $post_ids = $post_ids + $wpdb->get_col( $wpdb->prepare( "
80
+ SELECT DISTINCT ID FROM {$wpdb->posts}
81
+ WHERE post_title LIKE '%%%s%%'
82
+ OR post_content LIKE '%%%s%%'
83
+ ", $search_keywords, $search_keywords ) );
84
+
85
+ $args['post__in'] = $post_ids + array( 0 );
86
+ }
87
+
88
+ // Category search
89
+ if ( $search_categories ) {
90
+ $args['tax_query'][] = array(
91
+ 'taxonomy' => 'job_listing_category',
92
+ 'field' => 'slug',
93
+ 'terms' => $search_categories + array( 0 )
94
+ );
95
+ }
96
+
97
+ $jobs = new WP_Query( $args );
98
+
99
+ $result = array();
100
+ $result['found_jobs'] = false;
101
+
102
+ if ( $jobs->have_posts() ) : $result['found_jobs'] = true; ?>
103
+
104
+ <?php while ( $jobs->have_posts() ) : $jobs->the_post(); ?>
105
+
106
+ <?php get_job_manager_template_part( 'content', 'job_listing' ); ?>
107
+
108
+ <?php endwhile; ?>
109
+
110
+ <?php else : ?>
111
+
112
+ <li class="no_job_listings_found"><?php _e( 'No more jobs found matching your selection.', 'job_manager' ); ?></li>
113
+
114
+ <?php endif;
115
+
116
+ $result['html'] = ob_get_clean();
117
+
118
+ // Generate 'showing' text
119
+ $types = get_job_listing_types();
120
+
121
+ if ( sizeof( $filter_job_types ) > 0 && ( sizeof( $filter_job_types ) !== sizeof( $types ) || $search_keywords || $search_location || $search_categories ) ) {
122
+ $showing_types = array();
123
+ $unmatched = false;
124
+
125
+ foreach ( $types as $type ) {
126
+ if ( in_array( $type->slug, $filter_job_types ) )
127
+ $showing_types[] = $type->name;
128
+ else
129
+ $unmatched = true;
130
+ }
131
+
132
+ if ( ! $unmatched )
133
+ $showing_types = '';
134
+ elseif ( sizeof( $showing_types ) == 1 ) {
135
+ $showing_types = implode( ', ', $showing_types ) . ' ';
136
+ } else {
137
+ $last = array_pop( $showing_types );
138
+ $showing_types = implode( ', ', $showing_types );
139
+ $showing_types .= " &amp; $last ";
140
+ }
141
+
142
+ $showing_categories = array();
143
+
144
+ if ( $search_categories ) {
145
+ foreach ( $search_categories as $category ) {
146
+ $category = get_term_by( 'slug', $category, 'job_listing_category' );
147
+
148
+ if ( ! is_wp_error( $category ) )
149
+ $showing_categories[] = $category->name;
150
+ }
151
+ }
152
+
153
+ if ( $search_keywords ) {
154
+ $showing_jobs = sprintf( __( 'Showing %s&ldquo;%s&rdquo; %sjobs', 'job_manager' ), $showing_types, $search_keywords, implode( ', ', $showing_categories ) );
155
+ } else {
156
+ $showing_jobs = sprintf( __( 'Showing all %s%sjobs', 'job_manager' ), $showing_types, implode( ', ', $showing_categories ) . ' ' );
157
+ }
158
+
159
+ $showing_location = $search_location ? sprintf( ' ' . __( 'located in &ldquo;%s&rdquo;', 'job_manager' ), $search_location ) : '';
160
+
161
+ $result['showing'] = $showing_jobs . $showing_location;
162
+
163
+ } else {
164
+ $result['showing'] = '';
165
+ }
166
+
167
+ // Generate RSS link
168
+ $result['rss'] = get_job_listing_rss_link( array(
169
+ 'type' => implode( ',', $filter_job_types ),
170
+ 'location' => $search_location,
171
+ 'job_categories' => implode( ',', $search_categories ),
172
+ 's' => $search_keywords,
173
+ ) );
174
+
175
+ $result['max_num_pages'] = $jobs->max_num_pages;
176
+
177
+ echo '<!--WPJM-->';
178
+ echo json_encode( $result );
179
+ echo '<!--WPJM_END-->';
180
+
181
+ die();
182
+ }
183
+ }
184
+
185
+ new WP_Job_Manager_Ajax();
includes/class-wp-job-manager-api.php ADDED
@@ -0,0 +1,78 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_API API
7
+ *
8
+ * This API class handles API requests.
9
+ */
10
+ class WP_Job_Manager_API {
11
+
12
+ /**
13
+ * __construct function.
14
+ *
15
+ * @access public
16
+ * @return void
17
+ */
18
+ public function __construct() {
19
+ add_filter( 'query_vars', array( $this, 'add_query_vars'), 0 );
20
+ //add_action( 'init', array( $this, 'add_endpoint'), 0 );
21
+ add_action( 'parse_request', array( $this, 'api_requests'), 0 );
22
+ }
23
+
24
+ /**
25
+ * add_query_vars function.
26
+ *
27
+ * @access public
28
+ * @return void
29
+ */
30
+ public function add_query_vars( $vars ) {
31
+ $vars[] = 'job-manager-api';
32
+ return $vars;
33
+ }
34
+
35
+ /**
36
+ * add_endpoint function.
37
+ *
38
+ * @access public
39
+ * @return void
40
+ */
41
+ public function add_endpoint() {
42
+ add_rewrite_endpoint( 'job-manager-api', EP_ALL );
43
+ }
44
+
45
+ /**
46
+ * API request - Trigger any API requests (handy for third party plugins/gateways).
47
+ *
48
+ * @access public
49
+ * @return void
50
+ */
51
+ public function api_requests() {
52
+ global $wp;
53
+
54
+ if ( ! empty( $_GET['job-manager-api'] ) )
55
+ $wp->query_vars['wc-api'] = $_GET['job-manager-api'];
56
+
57
+ if ( ! empty( $wp->query_vars['wc-api'] ) ) {
58
+ // Buffer, we won't want any output here
59
+ ob_start();
60
+
61
+ // Get API trigger
62
+ $api = strtolower( esc_attr( $wp->query_vars['job-manager-api'] ) );
63
+
64
+ // Load class if exists
65
+ if ( class_exists( $api ) )
66
+ $api_class = new $api();
67
+
68
+ // Trigger actions
69
+ do_action( 'job_manager_api_' . $api );
70
+
71
+ // Done, clear buffer and exit
72
+ ob_end_clean();
73
+ die('1');
74
+ }
75
+ }
76
+ }
77
+
78
+ new WP_Job_Manager_API();
includes/class-wp-job-manager-forms.php ADDED
@@ -0,0 +1,70 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * WP_Job_Manager_Forms class.
4
+ */
5
+ class WP_Job_Manager_Forms {
6
+
7
+ /**
8
+ * Constructor
9
+ */
10
+ public function __construct() {
11
+ add_action( 'init', array( $this, 'load_posted_form' ) );
12
+ }
13
+
14
+ /**
15
+ * If a form was posted, load its class so that it can be processed before display.
16
+ */
17
+ public function load_posted_form() {
18
+ if ( ! empty( $_POST['job_manager_form'] ) ) {
19
+ $this->load_form_class( sanitize_title( $_POST['job_manager_form'] ) );
20
+ }
21
+ }
22
+
23
+ /**
24
+ * Load a form's class
25
+ *
26
+ * @param string $form_name
27
+ * @return string class name on success, false on failure
28
+ */
29
+ private function load_form_class( $form_name ) {
30
+ global $job_manager;
31
+
32
+ // Load the form abtract
33
+ if ( ! class_exists( 'WP_Job_Manager_Form' ) )
34
+ include( 'abstracts/abstract-wp-job-manager-form.php' );
35
+
36
+ // Now try to load the form_name
37
+ $form_class = 'WP_Job_Manager_Form_' . str_replace( '-', '_', $form_name );
38
+ $form_file = JOB_MANAGER_PLUGIN_DIR . '/includes/forms/class-wp-job-manager-form-' . $form_name . '.php';
39
+
40
+ if ( class_exists( $form_class ) )
41
+ return $form_class;
42
+
43
+ if ( ! file_exists( $form_file ) )
44
+ return false;
45
+
46
+ if ( ! class_exists( $form_class ) )
47
+ include $form_file;
48
+
49
+ // Init the form
50
+ call_user_func( array( $form_class, "init" ) );
51
+
52
+ return $form_class;
53
+ }
54
+
55
+ /**
56
+ * get_form function.
57
+ *
58
+ * @access public
59
+ * @param mixed $form_name
60
+ * @return string
61
+ */
62
+ public function get_form( $form_name ) {
63
+ if ( $form = $this->load_form_class( $form_name ) ) {
64
+ ob_start();
65
+ call_user_func( array( $form, "output" ) );
66
+ return ob_get_clean();
67
+ }
68
+ }
69
+
70
+ }
includes/class-wp-job-manager-install.php ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_Install
7
+ */
8
+ class WP_Job_Manager_Install {
9
+
10
+ /**
11
+ * __construct function.
12
+ *
13
+ * @access public
14
+ * @return void
15
+ */
16
+ public function __construct() {
17
+ $this->init_user_roles();
18
+ $this->default_terms();
19
+ $this->cron();
20
+ }
21
+
22
+ /**
23
+ * Init user roles
24
+ *
25
+ * @access public
26
+ * @return void
27
+ */
28
+ public function init_user_roles() {
29
+ global $wp_roles;
30
+
31
+ if ( class_exists( 'WP_Roles' ) && ! isset( $wp_roles ) )
32
+ $wp_roles = new WP_Roles();
33
+
34
+ if ( is_object( $wp_roles ) ) {
35
+ $wp_roles->add_cap( 'administrator', 'manage_job_listings' );
36
+ }
37
+ }
38
+
39
+ /**
40
+ * default_terms function.
41
+ *
42
+ * @access public
43
+ * @return void
44
+ */
45
+ public function default_terms() {
46
+ if ( get_option( 'job_manager_installed_terms' ) == 1 )
47
+ return;
48
+
49
+ $taxonomies = array(
50
+ 'job_listing_type' => array(
51
+ 'Full Time',
52
+ 'Part Time',
53
+ 'Temporary',
54
+ 'Freelance',
55
+ 'Internship'
56
+ )
57
+ );
58
+
59
+ foreach ( $taxonomies as $taxonomy => $terms ) {
60
+ foreach ( $terms as $term ) {
61
+ if ( ! get_term_by( 'slug', sanitize_title( $term ), $taxonomy ) ) {
62
+ wp_insert_term( $term, $taxonomy );
63
+ }
64
+ }
65
+ }
66
+
67
+ update_option( 'job_manager_installed_terms', 1 );
68
+ }
69
+
70
+ /**
71
+ * Setup cron jobs
72
+ */
73
+ public function cron() {
74
+ wp_clear_scheduled_hook( 'job_manager_check_for_expired_jobs' );
75
+ wp_schedule_event( time(), 'hourly', 'job_manager_check_for_expired_jobs' );
76
+ }
77
+ }
78
+
79
+ new WP_Job_Manager_Install();
includes/class-wp-job-manager-post-types.php ADDED
@@ -0,0 +1,329 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * WP_Job_Manager_Content class.
4
+ */
5
+ class WP_Job_Manager_Post_Types {
6
+
7
+ /**
8
+ * Constructor
9
+ */
10
+ public function __construct() {
11
+ add_action( 'init', array( $this, 'register_post_types' ) );
12
+ add_filter( 'the_content', array( $this, 'job_content' ) );
13
+ add_action( 'job_manager_check_for_expired_jobs', array( $this, 'check_for_expired_jobs' ) );
14
+ add_action( 'pending_to_publish', array( $this, 'set_expirey' ) );
15
+ add_action( 'preview_to_publish', array( $this, 'set_expirey' ) );
16
+
17
+ add_filter( 'the_job_description', 'wptexturize' );
18
+ add_filter( 'the_job_description', 'convert_smilies' );
19
+ add_filter( 'the_job_description', 'convert_chars' );
20
+ add_filter( 'the_job_description', 'wpautop' );
21
+ add_filter( 'the_job_description', 'shortcode_unautop' );
22
+ add_filter( 'the_job_description', 'prepend_attachment' );
23
+ }
24
+
25
+ /**
26
+ * register_post_types function.
27
+ *
28
+ * @access public
29
+ * @return void
30
+ */
31
+ public function register_post_types() {
32
+
33
+ if ( post_type_exists( "job_listing" ) )
34
+ return;
35
+
36
+ $admin_capability = 'manage_job_listings';
37
+
38
+ /**
39
+ * Taxonomies
40
+ */
41
+ if ( get_option( 'job_manager_enable_categories' ) ) {
42
+ $singular = __( 'Job Category', 'job_manager' );
43
+ $plural = __( 'Job Categories', 'job_manager' );
44
+
45
+ if ( current_theme_supports( 'job-manager-templates' ) ) {
46
+ $rewrite = array(
47
+ 'slug' => _x( 'job-category', 'Job category slug - resave permalinks after changing this', 'job_manager' ),
48
+ 'with_front' => false,
49
+ 'hierarchical' => false
50
+ );
51
+ } else {
52
+ $rewrite = false;
53
+ }
54
+
55
+ register_taxonomy( "job_listing_category",
56
+ array( "job_listing" ),
57
+ array(
58
+ 'hierarchical' => true,
59
+ 'update_count_callback' => '_update_post_term_count',
60
+ 'label' => $plural,
61
+ 'labels' => array(
62
+ 'name' => $plural,
63
+ 'singular_name' => $singular,
64
+ 'search_items' => sprintf( __( 'Search %s', 'job_manager' ), $plural ),
65
+ 'all_items' => sprintf( __( 'All %s', 'job_manager' ), $plural ),
66
+ 'parent_item' => sprintf( __( 'Parent %s', 'job_manager' ), $singular ),
67
+ 'parent_item_colon' => sprintf( __( 'Parent %s:', 'job_manager' ), $singular ),
68
+ 'edit_item' => sprintf( __( 'Edit %s', 'job_manager' ), $singular ),
69
+ 'update_item' => sprintf( __( 'Update %s', 'job_manager' ), $singular ),
70
+ 'add_new_item' => sprintf( __( 'Add New %s', 'job_manager' ), $singular ),
71
+ 'new_item_name' => sprintf( __( 'New %s Name', 'job_manager' ), $singular )
72
+ ),
73
+ 'show_ui' => true,
74
+ 'query_var' => true,
75
+ 'capabilities' => array(
76
+ 'manage_terms' => $admin_capability,
77
+ 'edit_terms' => $admin_capability,
78
+ 'delete_terms' => $admin_capability,
79
+ 'assign_terms' => $admin_capability,
80
+ ),
81
+ 'rewrite' => $rewrite,
82
+ )
83
+ );
84
+ }
85
+
86
+ $singular = __( 'Job Type', 'job_manager' );
87
+ $plural = __( 'Job Types', 'job_manager' );
88
+
89
+ if ( current_theme_supports( 'job-manager-templates' ) ) {
90
+ $rewrite = array(
91
+ 'slug' => _x( 'job-type', 'Job type slug - resave permalinks after changing this', 'job_manager' ),
92
+ 'with_front' => false,
93
+ 'hierarchical' => false
94
+ );
95
+ } else {
96
+ $rewrite = false;
97
+ }
98
+
99
+ register_taxonomy( "job_listing_type",
100
+ array( "job_listing" ),
101
+ array(
102
+ 'hierarchical' => true,
103
+ 'label' => $plural,
104
+ 'labels' => array(
105
+ 'name' => $plural,
106
+ 'singular_name' => $singular,
107
+ 'search_items' => sprintf( __( 'Search %s', 'job_manager' ), $plural ),
108
+ 'all_items' => sprintf( __( 'All %s', 'job_manager' ), $plural ),
109
+ 'parent_item' => sprintf( __( 'Parent %s', 'job_manager' ), $singular ),
110
+ 'parent_item_colon' => sprintf( __( 'Parent %s:', 'job_manager' ), $singular ),
111
+ 'edit_item' => sprintf( __( 'Edit %s', 'job_manager' ), $singular ),
112
+ 'update_item' => sprintf( __( 'Update %s', 'job_manager' ), $singular ),
113
+ 'add_new_item' => sprintf( __( 'Add New %s', 'job_manager' ), $singular ),
114
+ 'new_item_name' => sprintf( __( 'New %s Name', 'job_manager' ), $singular )
115
+ ),
116
+ 'show_ui' => true,
117
+ 'query_var' => true,
118
+ 'capabilities' => array(
119
+ 'manage_terms' => $admin_capability,
120
+ 'edit_terms' => $admin_capability,
121
+ 'delete_terms' => $admin_capability,
122
+ 'assign_terms' => $admin_capability,
123
+ ),
124
+ 'rewrite' => $rewrite,
125
+ )
126
+ );
127
+
128
+ /**
129
+ * Post types
130
+ */
131
+ $singular = __( 'Job Listing', 'job_manager' );
132
+ $plural = __( 'Job Listings', 'job_manager' );
133
+
134
+ if ( current_theme_supports( 'job-manager-templates' ) ) {
135
+ $has_archive = _x( 'jobs', 'Post type archive slug - resave permalinks after changing this', 'job_manager' );
136
+ } else {
137
+ $has_archive = false;
138
+ }
139
+
140
+ $rewrite = array(
141
+ 'slug' => _x( 'job', 'Job permalink - resave permalinks after changing this', 'job_manager' ),
142
+ 'with_front' => false,
143
+ 'feeds' => true,
144
+ 'pages' => false
145
+ );
146
+
147
+ register_post_type( "job_listing",
148
+ apply_filters( "register_post_type_job_listing", array(
149
+ 'labels' => array(
150
+ 'name' => $plural,
151
+ 'singular_name' => $singular,
152
+ 'menu_name' => $plural,
153
+ 'all_items' => sprintf( __( 'All %s', 'job_manager' ), $plural ),
154
+ 'add_new' => __( 'Add New', 'job_manager' ),
155
+ 'add_new_item' => sprintf( __( 'Add %s', 'job_manager' ), $singular ),
156
+ 'edit' => __( 'Edit', 'job_manager' ),
157
+ 'edit_item' => sprintf( __( 'Edit %s', 'job_manager' ), $singular ),
158
+ 'new_item' => sprintf( __( 'New %s', 'job_manager' ), $singular ),
159
+ 'view' => sprintf( __( 'View %s', 'job_manager' ), $singular ),
160
+ 'view_item' => sprintf( __( 'View %s', 'job_manager' ), $singular ),
161
+ 'search_items' => sprintf( __( 'Search %s', 'job_manager' ), $plural ),
162
+ 'not_found' => sprintf( __( 'No %s found', 'job_manager' ), $plural ),
163
+ 'not_found_in_trash' => sprintf( __( 'No %s found in trash', 'job_manager' ), $plural ),
164
+ 'parent' => sprintf( __( 'Parent %s', 'job_manager' ), $singular )
165
+ ),
166
+ 'description' => __( 'This is where you can create and manage job listings.', 'job_manager' ),
167
+ 'public' => true,
168
+ 'show_ui' => true,
169
+ 'capability_type' => 'post',
170
+ 'capabilities' => array(
171
+ 'publish_posts' => $admin_capability,
172
+ 'edit_posts' => $admin_capability,
173
+ 'edit_others_posts' => $admin_capability,
174
+ 'delete_posts' => $admin_capability,
175
+ 'delete_others_posts' => $admin_capability,
176
+ 'read_private_posts' => $admin_capability,
177
+ 'edit_post' => $admin_capability,
178
+ 'delete_post' => $admin_capability,
179
+ 'read_post' => $admin_capability
180
+ ),
181
+ 'publicly_queryable' => true,
182
+ 'exclude_from_search' => false,
183
+ 'hierarchical' => false,
184
+ 'rewrite' => $rewrite,
185
+ 'query_var' => true,
186
+ 'supports' => array( 'title', 'editor', 'custom-fields' ),
187
+ 'has_archive' => $has_archive,
188
+ 'show_in_nav_menus' => false
189
+ ) )
190
+ );
191
+
192
+ /**
193
+ * Feeds
194
+ */
195
+ add_feed( 'job_feed', array( $this, 'job_feed' ) );
196
+
197
+ /**
198
+ * Post status
199
+ */
200
+ register_post_status( 'expired', array(
201
+ 'label' => _x( 'Expired', 'job_listing', 'job_manager' ),
202
+ 'public' => true,
203
+ 'exclude_from_search' => false,
204
+ 'show_in_admin_all_list' => true,
205
+ 'show_in_admin_status_list' => true,
206
+ 'label_count' => _n_noop( 'Expired <span class="count">(%s)</span>', 'Expired <span class="count">(%s)</span>', 'job_manager' ),
207
+ ) );
208
+ }
209
+
210
+ /**
211
+ * Add extra content when showing job content
212
+ */
213
+ public function job_content( $content ) {
214
+ global $post, $job_manager;
215
+
216
+ if ( ! is_singular( 'job_listing' ) )
217
+ return $content;
218
+
219
+ remove_filter( 'the_content', array( $this, 'job_content' ) );
220
+
221
+ if ( $post->post_type == 'job_listing' ) {
222
+ ob_start();
223
+
224
+ get_job_manager_template_part( 'content-single', 'job_listing' );
225
+
226
+ $content = ob_get_clean();
227
+ }
228
+
229
+ add_filter( 'the_content', array( $this, 'job_content' ) );
230
+
231
+ return $content;
232
+ }
233
+
234
+ /**
235
+ * Job listing feeds
236
+ */
237
+ public function job_feed() {
238
+ $args = array(
239
+ 'post_type' => 'job_listing',
240
+ 'post_status' => 'publish',
241
+ 'ignore_sticky_posts' => 1,
242
+ 'posts_per_page' => 10,
243
+ 's' => sanitize_text_field( $_GET['s'] ),
244
+ 'meta_query' => array(
245
+ array(
246
+ 'key' => '_job_location',
247
+ 'value' => sanitize_text_field( $_GET['location'] ),
248
+ 'compare' => 'LIKE'
249
+ )
250
+ ),
251
+ 'tax_query' => array(
252
+ array(
253
+ 'taxonomy' => 'job_listing_type',
254
+ 'field' => 'slug',
255
+ 'terms' => explode( ',', sanitize_text_field( $_GET['type'] ) ) + array( 0 )
256
+ )
257
+ )
258
+ );
259
+
260
+ if ( $_GET['job_categories'] ) {
261
+ $args['tax_query'][] = array(
262
+ 'taxonomy' => 'job_listing_category',
263
+ 'field' => 'slug',
264
+ 'terms' => explode( ',', sanitize_text_field( $_GET['job_categories'] ) ) + array( 0 )
265
+ );
266
+ }
267
+
268
+ query_posts( $args );
269
+
270
+ do_feed_rss2( false );
271
+ }
272
+
273
+ /**
274
+ * Expire jobs
275
+ */
276
+ public function check_for_expired_jobs() {
277
+ global $wpdb;
278
+
279
+ // Change status to expired
280
+ $job_ids = $wpdb->get_col( $wpdb->prepare( "
281
+ SELECT postmeta.post_id FROM {$wpdb->postmeta} as postmeta
282
+ LEFT JOIN {$wpdb->posts} as posts ON postmeta.post_id = posts.ID
283
+ WHERE postmeta.meta_key = '_job_expires'
284
+ AND postmeta.meta_value > 0
285
+ AND postmeta.meta_value < %s
286
+ AND posts.post_status = 'publish'
287
+ AND posts.post_type = 'job_listing'
288
+ ", current_time( 'mysql' ) ) );
289
+
290
+ if ( $job_ids ) {
291
+ foreach ( $job_ids as $job_id ) {
292
+ $job_data = array();
293
+ $job_data['ID'] = $job_id;
294
+ $job_data['post_status'] = 'expired';
295
+ wp_update_post( $job_data );
296
+ }
297
+ }
298
+
299
+ // Delete old expired jobs
300
+ $job_ids = $wpdb->get_col( $wpdb->prepare( "
301
+ SELECT posts.ID FROM {$wpdb->posts} as posts
302
+ WHERE posts.post_type = 'job_listing'
303
+ AND posts.post_modified < %s
304
+ AND posts.post_status = 'expired'
305
+ ", date( 'Y-m-d H:i:s', strtotime( '-30 days', current_time( 'timestamp' ) ) ) ) );
306
+
307
+ if ( $job_ids ) {
308
+ foreach ( $job_ids as $job_id ) {
309
+ wp_trash_post( $job_id );
310
+ }
311
+ }
312
+ }
313
+
314
+ /**
315
+ * Set expirey date when job status changes
316
+ */
317
+ public function set_expirey( $post ) {
318
+ if ( $post->post_type !== 'job_listing' )
319
+ return;
320
+
321
+ // Expires
322
+ $duration = absint( get_option( 'job_manager_submission_duration' ) );
323
+
324
+ if ( $duration ) {
325
+ $expires = date( 'Y-m-d H:i:s', strtotime( "+{$duration} days", current_time( 'timestamp' ) ) );
326
+ update_post_meta( $post->ID, '_job_expires', $expires );
327
+ }
328
+ }
329
+ }
includes/class-wp-job-manager-shortcodes.php ADDED
@@ -0,0 +1,324 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * WP_Job_Manager_Shortcodes class.
7
+ */
8
+ class WP_Job_Manager_Shortcodes {
9
+
10
+ private $job_dashboard_message = '';
11
+
12
+ /**
13
+ * __construct function.
14
+ *
15
+ * @access public
16
+ * @return void
17
+ */
18
+ public function __construct() {
19
+ add_action( 'wp', array( $this, 'shortcode_action_handler' ) );
20
+
21
+ add_shortcode( 'submit_job_form', array( $this, 'submit_job_form' ) );
22
+ add_shortcode( 'job_dashboard', array( $this, 'job_dashboard' ) );
23
+ add_shortcode( 'jobs', array( $this, 'output_jobs' ) );
24
+ add_shortcode( 'job', array( $this, 'output_job' ) );
25
+ add_shortcode( 'job_summary', array( $this, 'output_job_summary' ) );
26
+ }
27
+
28
+ /**
29
+ * Handle actions which need to be run before the shortcode e.g. post actions
30
+ */
31
+ public function shortcode_action_handler() {
32
+ global $post;
33
+
34
+ if ( is_page() && strstr( $post->post_content, '[job_dashboard' ) ) {
35
+ $this->job_dashboard_handler();
36
+ }
37
+ }
38
+
39
+ /**
40
+ * Show the job submission form
41
+ */
42
+ public function submit_job_form() {
43
+ return $GLOBALS['job_manager']->forms->get_form( 'submit-job' );
44
+ }
45
+
46
+ /**
47
+ * Handles actions on job dashboard
48
+ */
49
+ public function job_dashboard_handler() {
50
+ if ( ! empty( $_REQUEST['action'] ) && ! empty( $_REQUEST['_wpnonce'] ) && wp_verify_nonce( $_REQUEST['_wpnonce'], 'job_manager_my_job_actions' ) ) {
51
+
52
+ $action = sanitize_title( $_REQUEST['action'] );
53
+ $job_id = absint( $_REQUEST['job_id'] );
54
+
55
+ try {
56
+ // Get Job
57
+ $job = get_post( $job_id );
58
+
59
+ // Check ownership
60
+ if ( $job->post_author != get_current_user_id() )
61
+ throw new Exception( __( 'Invalid Job ID', 'job_manager' ) );
62
+
63
+ switch ( $action ) {
64
+ case 'mark_filled' :
65
+ // Check status
66
+ if ( $job->_filled == 1 )
67
+ throw new Exception( __( 'This job is already filled', 'job_manager' ) );
68
+
69
+ // Update
70
+ update_post_meta( $job_id, '_filled', 1 );
71
+
72
+ // Message
73
+ $this->job_dashboard_message = '<div class="job-manager-message">' . sprintf( __( '%s has been filled', 'job_manager' ), $job->post_title ) . '</div>';
74
+ break;
75
+ case 'mark_not_filled' :
76
+ // Check status
77
+ if ( $job->_filled != 1 )
78
+ throw new Exception( __( 'This job is already not filled', 'job_manager' ) );
79
+
80
+ // Update
81
+ update_post_meta( $job_id, '_filled', 0 );
82
+
83
+ // Message
84
+ $this->job_dashboard_message = '<div class="job-manager-message">' . sprintf( __( '%s has been marked as not filled', 'job_manager' ), $job->post_title ) . '</div>';
85
+ break;
86
+ case 'delete' :
87
+ // Trash it
88
+ wp_trash_post( $job_id );
89
+
90
+ // Message
91
+ $this->job_dashboard_message = '<div class="job-manager-message">' . sprintf( __( '%s has been deleted', 'job_manager' ), $job->post_title ) . '</div>';
92
+
93
+ break;
94
+ }
95
+
96
+ do_action( 'job_manager_my_job_do_action', $action, $job_id );
97
+
98
+ } catch ( Exception $e ) {
99
+ $this->job_dashboard_message = '<div class="job-manager-error">' . $e->getMessage() . '</div>';
100
+ }
101
+ }
102
+ }
103
+
104
+ /**
105
+ * Shortcode which lists the logged in user's jobs
106
+ */
107
+ public function job_dashboard( $atts ) {
108
+ global $job_manager;
109
+
110
+ if ( ! is_user_logged_in() ) {
111
+ _e( 'You need to be signed in to manage your job listings.', 'job_manager' );
112
+ return;
113
+ }
114
+
115
+ wp_enqueue_script( 'wp-job-manager-job-dashboard' );
116
+
117
+ // If doing an action, show conditional content if needed....
118
+ if ( ! empty( $_REQUEST['action'] ) ) {
119
+
120
+ $action = sanitize_title( $_REQUEST['action'] );
121
+ $job_id = absint( $_REQUEST['job_id'] );
122
+
123
+ switch ( $action ) {
124
+ case 'edit' :
125
+ return $job_manager->forms->get_form( 'edit-job' );
126
+ }
127
+ }
128
+
129
+ // ....If not show the job dashboard
130
+ $args = array(
131
+ 'post_type' => 'job_listing',
132
+ 'post_status' => array( 'publish', 'expired', 'pending' ),
133
+ 'ignore_sticky_posts' => 1,
134
+ 'posts_per_page' => -1,
135
+ 'orderby' => 'date',
136
+ 'order' => 'desc',
137
+ 'author' => get_current_user_id()
138
+ );
139
+
140
+ $jobs = get_posts( $args );
141
+
142
+ ob_start();
143
+
144
+ echo $this->job_dashboard_message;
145
+
146
+ get_job_manager_template( 'job-dashboard.php', array( 'jobs' => $jobs ) );
147
+
148
+ return ob_get_clean();
149
+ }
150
+
151
+ /**
152
+ * output_jobs function.
153
+ *
154
+ * @access public
155
+ * @param mixed $args
156
+ * @return void
157
+ */
158
+ public function output_jobs( $atts ) {
159
+ global $job_manager;
160
+
161
+ ob_start();
162
+
163
+ extract( shortcode_atts( array(
164
+ 'per_page' => get_option( 'job_manager_per_page' ),
165
+ 'orderby' => 'date',
166
+ 'order' => 'desc',
167
+ 'show_filters' => true,
168
+ 'show_categories' => get_option( 'job_manager_enable_categories' ),
169
+ 'categories' => ''
170
+ ), $atts ) );
171
+
172
+ $categories = array_filter( array_map( 'trim', explode( ',', $categories ) ) );
173
+
174
+ if ( $show_filters && $show_filters !== 'false' ) {
175
+
176
+ get_job_manager_template( 'job-filters.php', array( 'per_page' => $per_page, 'orderby' => $orderby, 'order' => $order, 'show_categories' => $show_categories, 'categories' => $categories ) );
177
+
178
+ ?><ul class="job_listings"></ul><a class="load_more_jobs" href="#" style="display:none;"><strong><?php _e( 'Load more job listings', 'job_manager' ); ?></strong></a><?php
179
+
180
+ } else {
181
+
182
+ $args = array(
183
+ 'post_type' => 'job_listing',
184
+ 'post_status' => 'publish',
185
+ 'ignore_sticky_posts' => 1,
186
+ 'posts_per_page' => $per_page,
187
+ 'orderby' => $orderby,
188
+ 'order' => $order,
189
+ );
190
+
191
+ if ( $categories )
192
+ $args['tax_query'] = array(
193
+ array(
194
+ 'taxonomy' => 'job_listing_category',
195
+ 'field' => 'slug',
196
+ 'terms' => $categories
197
+ )
198
+ );
199
+
200
+ if ( get_option( 'job_manager_hide_filled_positions' ) == 1 )
201
+ $args['meta_query'] = array(
202
+ array(
203
+ 'key' => '_filled',
204
+ 'value' => '1',
205
+ 'compare' => '!='
206
+ )
207
+ );
208
+
209
+ $jobs = new WP_Query( apply_filters( 'job_manager_output_jobs_args', $args ) );
210
+
211
+ if ( $jobs->have_posts() ) : ?>
212
+
213
+ <ul class="job_listings">
214
+
215
+ <?php while ( $jobs->have_posts() ) : $jobs->the_post(); ?>
216
+
217
+ <?php get_job_manager_template_part( 'content', 'job_listing' ); ?>
218
+
219
+ <?php endwhile; ?>
220
+
221
+ </ul>
222
+
223
+ <?php endif;
224
+
225
+ wp_reset_postdata();
226
+ }
227
+
228
+ return '<div class="job_listings">' . ob_get_clean() . '</div>';
229
+ }
230
+
231
+ /**
232
+ * output_job function.
233
+ *
234
+ * @access public
235
+ * @param array $args
236
+ * @return string
237
+ */
238
+ public function output_job( $atts ) {
239
+ global $job_manager;
240
+
241
+ extract( shortcode_atts( array(
242
+ 'id' => '',
243
+ ), $atts ) );
244
+
245
+ if ( ! $id )
246
+ return;
247
+
248
+ ob_start();
249
+
250
+ $args = array(
251
+ 'post_type' => 'job_listing',
252
+ 'post_status' => 'publish',
253
+ 'p' => $id
254
+ );
255
+
256
+ $jobs = new WP_Query( $args );
257
+
258
+ if ( $jobs->have_posts() ) : ?>
259
+
260
+ <?php while ( $jobs->have_posts() ) : $jobs->the_post(); ?>
261
+
262
+ <h1><?php the_title(); ?></h1>
263
+
264
+ <?php get_job_manager_template_part( 'content-single', 'job_listing' ); ?>
265
+
266
+ <?php endwhile; ?>
267
+
268
+ <?php endif;
269
+
270
+ wp_reset_postdata();
271
+
272
+ return '<div class="job_shortcode single_job_listing">' . ob_get_clean() . '</div>';
273
+ }
274
+
275
+ /**
276
+ * Job Summary shortcode
277
+ *
278
+ * @access public
279
+ * @param array $args
280
+ * @return string
281
+ */
282
+ public function output_job_summary( $atts ) {
283
+ global $job_manager;
284
+
285
+ extract( shortcode_atts( array(
286
+ 'id' => '',
287
+ 'width' => '250px',
288
+ 'align' => 'left'
289
+ ), $atts ) );
290
+
291
+ if ( ! $id )
292
+ return;
293
+
294
+ ob_start();
295
+
296
+ $args = array(
297
+ 'post_type' => 'job_listing',
298
+ 'post_status' => 'publish',
299
+ 'p' => $id
300
+ );
301
+
302
+ $jobs = new WP_Query( $args );
303
+
304
+ if ( $jobs->have_posts() ) : ?>
305
+
306
+ <?php while ( $jobs->have_posts() ) : $jobs->the_post(); ?>
307
+
308
+ <div class="job_summary_shortcode align<?php echo $align ?>" style="width: <?php echo $width ? $width : auto; ?>">
309
+
310
+ <?php get_job_manager_template_part( 'content-summary', 'job_listing' ); ?>
311
+
312
+ </div>
313
+
314
+ <?php endwhile; ?>
315
+
316
+ <?php endif;
317
+
318
+ wp_reset_postdata();
319
+
320
+ return ob_get_clean();
321
+ }
322
+ }
323
+
324
+ new WP_Job_Manager_Shortcodes();
includes/class-wp-job-manager-widgets.php ADDED
@@ -0,0 +1,232 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
+
5
+ /**
6
+ * Job Manager Widget base
7
+ */
8
+ class WP_Job_Manager_Widget extends WP_Widget {
9
+
10
+ public $widget_cssclass;
11
+ public $widget_description;
12
+ public $widget_id;
13
+ public $widget_name;
14
+ public $settings;
15
+
16
+ /**
17
+ * Constructor
18
+ */
19
+ public function __construct() {
20
+ $widget_ops = array(
21
+ 'classname' => $this->widget_cssclass,
22
+ 'description' => $this->widget_description
23
+ );
24
+
25
+ $this->WP_Widget( $this->widget_id, $this->widget_name, $widget_ops );
26
+
27
+ add_action( 'save_post', array( $this, 'flush_widget_cache' ) );
28
+ add_action( 'deleted_post', array( $this, 'flush_widget_cache' ) );
29
+ add_action( 'switch_theme', array( $this, 'flush_widget_cache' ) );
30
+ }
31
+
32
+ /**
33
+ * get_cached_widget function.
34
+ */
35
+ function get_cached_widget( $args ) {
36
+ $cache = wp_cache_get( $this->widget_id, 'widget' );
37
+
38
+ if ( ! is_array( $cache ) )
39
+ $cache = array();
40
+
41
+ if ( isset( $cache[ $args['widget_id'] ] ) ) {
42
+ echo $cache[ $args['widget_id'] ];
43
+ return true;
44
+ }
45
+
46
+ return false;
47
+ }
48
+
49
+ /**
50
+ * Cache the widget
51
+ */
52
+ public function cache_widget( $args, $content ) {
53
+ $cache[ $args['widget_id'] ] = $content;
54
+
55
+ wp_cache_set( $this->widget_id, $cache, 'widget' );
56
+ }
57
+
58
+ /**
59
+ * Flush the cache
60
+ * @return [type]
61
+ */
62
+ public function flush_widget_cache() {
63
+ wp_cache_delete( $this->widget_id, 'widget' );
64
+ }
65
+
66
+ /**
67
+ * update function.
68
+ *
69
+ * @see WP_Widget->update
70
+ * @access public
71
+ * @param array $new_instance
72
+ * @param array $old_instance
73
+ * @return array
74
+ */
75
+ function update( $new_instance, $old_instance ) {
76
+ $instance = $old_instance;
77
+
78
+ if ( ! $this->settings )
79
+ return $instance;
80
+
81
+ foreach ( $this->settings as $key => $setting ) {
82
+ $instance[ $key ] = sanitize_text_field( $new_instance[ $key ] );
83
+ }
84
+
85
+ $this->flush_widget_cache();
86
+
87
+ return $instance;
88
+ }
89
+
90
+ /**
91
+ * form function.
92
+ *
93
+ * @see WP_Widget->form
94
+ * @access public
95
+ * @param array $instance
96
+ * @return void
97
+ */
98
+ function form( $instance ) {
99
+
100
+ if ( ! $this->settings )
101
+ return;
102
+
103
+ foreach ( $this->settings as $key => $setting ) {
104
+
105
+ $value = isset( $instance[ $key ] ) ? $instance[ $key ] : $setting['std'];
106
+
107
+ switch ( $setting['type'] ) {
108
+ case 'text' :
109
+ ?>
110
+ <p>
111
+ <label for="<?php echo $this->get_field_id( $key ); ?>"><?php echo $setting['label']; ?></label>
112
+ <input class="widefat" id="<?php echo esc_attr( $this->get_field_id( $key ) ); ?>" name="<?php echo $this->get_field_name( $key ); ?>" type="text" value="<?php echo esc_attr( $value ); ?>" />
113
+ </p>
114
+ <?php
115
+ break;
116
+ case 'number' :
117
+ ?>
118
+ <p>
119
+ <label for="<?php echo $this->get_field_id( $key ); ?>"><?php echo $setting['label']; ?></label>
120
+ <input class="widefat" id="<?php echo esc_attr( $this->get_field_id( $key ) ); ?>" name="<?php echo $this->get_field_name( $key ); ?>" type="number" step="<?php echo esc_attr( $setting['step'] ); ?>" min="<?php echo esc_attr( $setting['min'] ); ?>" max="<?php echo esc_attr( $setting['max'] ); ?>" value="<?php echo esc_attr( $value ); ?>" />
121
+ </p>
122
+ <?php
123
+ break;
124
+ }
125
+ }
126
+ }
127
+ }
128
+
129
+ /**
130
+ * Recent Jobs Widget
131
+ */
132
+ class WP_Job_Manager_Widget_Recent_Jobs extends WP_Job_Manager_Widget {
133
+
134
+ /**
135
+ * Constructor
136
+ */
137
+ public function __construct() {
138
+ $this->widget_cssclass = 'job_manager widget_recent_jobs';
139
+ $this->widget_description = __( 'Display a list of the most recent jobs on your site.', 'job_manager' );
140
+ $this->widget_id = 'widget_recent_jobs';
141
+ $this->widget_name = __( 'Recent Job Listings', 'job_manager' );
142
+ $this->settings = array(
143
+ 'title' => array(
144
+ 'type' => 'text',
145
+ 'std' => __( 'Recent Jobs', 'job_manager' ),
146
+ 'label' => __( 'Title', 'job_manager' )
147
+ ),
148
+ 'number' => array(
149
+ 'type' => 'number',
150
+ 'step' => 1,
151
+ 'min' => 1,
152
+ 'max' => '',
153
+ 'std' => 10,
154
+ 'label' => __( 'Number of jobs to show', 'job_manager' )
155
+ )
156
+ );
157
+ parent::__construct();
158
+ }
159
+
160
+ /**
161
+ * widget function.
162
+ *
163
+ * @see WP_Widget
164
+ * @access public
165
+ * @param array $args
166
+ * @param array $instance
167
+ * @return void
168
+ */
169
+ function widget( $args, $instance ) {
170
+ global $job_manager;
171
+
172
+ if ( $this->get_cached_widget( $args ) )
173
+ return;
174
+
175
+ ob_start();
176
+
177
+ extract( $args );
178
+
179
+ $title = apply_filters( 'widget_title', $instance['title'], $instance, $this->id_base );
180
+ $number = absint( $instance['number'] );
181
+
182
+ $query_args = array(
183
+ 'post_type' => 'job_listing',
184
+ 'post_status' => 'publish',
185
+ 'ignore_sticky_posts' => 1,
186
+ 'posts_per_page' => $number,
187
+ 'orderby' => 'date',
188
+ 'order' => 'DESC',
189
+ );
190
+
191
+ if ( get_option( 'job_manager_hide_filled_positions' ) == 1 )
192
+ $query_args['meta_query'] = array(
193
+ array(
194
+ 'key' => '_filled',
195
+ 'value' => '1',
196
+ 'compare' => '!='
197
+ )
198
+ );
199
+
200
+ $jobs = new WP_Query( $query_args );
201
+
202
+ if ( $jobs->have_posts() ) : ?>
203
+
204
+ <?php echo $before_widget; ?>
205
+
206
+ <?php if ( $title ) echo $before_title . $title . $after_title; ?>
207
+
208
+ <ul class="job_listings">
209
+
210
+ <?php while ( $jobs->have_posts() ) : $jobs->the_post(); ?>
211
+
212
+ <?php get_job_manager_template_part( 'content-widget', 'job_listing' ); ?>
213
+
214
+ <?php endwhile; ?>
215
+
216
+ </ul>
217
+
218
+ <?php echo $after_widget; ?>
219
+
220
+ <?php endif;
221
+
222
+ wp_reset_postdata();
223
+
224
+ $content = ob_get_clean();
225
+
226
+ echo $content;
227
+
228
+ $this->cache_widget( $args, $content );
229
+ }
230
+ }
231
+
232
+ register_widget( 'WP_Job_Manager_Widget_Recent_Jobs' );
includes/forms/class-wp-job-manager-form-edit-job.php ADDED
@@ -0,0 +1,110 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ include_once( 'class-wp-job-manager-form-submit-job.php' );
4
+
5
+ /**
6
+ * WP_Job_Manager_Form_Edit_Job class.
7
+ */
8
+ class WP_Job_Manager_Form_Edit_Job extends WP_Job_Manager_Form_Submit_Job {
9
+
10
+ public static $form_name = 'edit-job';
11
+
12
+ /**
13
+ * Constructor
14
+ */
15
+ public static function init() {
16
+ self::$job_id = ! empty( $_REQUEST['job_id'] ) ? absint( $_REQUEST[ 'job_id' ] ) : 0;
17
+ }
18
+
19
+ /**
20
+ * output function.
21
+ *
22
+ * @access public
23
+ * @return void
24
+ */
25
+ public static function output() {
26
+ self::submit_handler();
27
+ self::submit();
28
+ }
29
+
30
+ /**
31
+ * Submit Step
32
+ */
33
+ public static function submit() {
34
+ global $job_manager, $post;
35
+
36
+ $job = get_post( self::$job_id );
37
+
38
+ if ( empty( self::$job_id ) || $job->post_status !== 'publish' ) {
39
+ echo wpautop( __( 'Invalid job', 'job_manager' ) );
40
+ return;
41
+ }
42
+
43
+ self::init_fields();
44
+
45
+ foreach ( self::$fields as $group_key => $fields ) {
46
+ foreach ( $fields as $key => $field ) {
47
+ switch ( $key ) {
48
+ case 'job_title' :
49
+ if ( ! isset( self::$fields[ $group_key ][ $key ]['value'] ) )
50
+ self::$fields[ $group_key ][ $key ]['value'] = $job->post_title;
51
+ break;
52
+ case 'job_description' :
53
+ if ( ! isset( self::$fields[ $group_key ][ $key ]['value'] ) )
54
+ self::$fields[ $group_key ][ $key ]['value'] = $job->post_content;
55
+ break;
56
+ case 'job_type' :
57
+ if ( ! isset( self::$fields[ $group_key ][ $key ]['value'] ) )
58
+ self::$fields[ $group_key ][ $key ]['value'] = current( wp_get_object_terms( $job->ID, 'job_listing_type', array( 'fields' => 'slugs' ) ) );
59
+ break;
60
+ case 'job_category' :
61
+ if ( ! isset( self::$fields[ $group_key ][ $key ]['value'] ) )
62
+ self::$fields[ $group_key ][ $key ]['value'] = current( wp_get_object_terms( $job->ID, 'job_listing_category', array( 'fields' => 'slugs' ) ) );
63
+ break;
64
+ default:
65
+ if ( ! isset( self::$fields[ $group_key ][ $key ]['value'] ) )
66
+ self::$fields[ $group_key ][ $key ]['value'] = get_post_meta( $job->ID, '_' . $key, true );
67
+ break;
68
+ }
69
+ }
70
+ }
71
+
72
+ get_job_manager_template( 'job-submit.php', array(
73
+ 'form' => self::$form_name,
74
+ 'job_id' => self::get_job_id(),
75
+ 'action' => self::get_action(),
76
+ 'job_fields' => self::get_fields( 'job' ),
77
+ 'company_fields' => self::get_fields( 'company' ),
78
+ 'submit_button_text' => __( 'Update job listing', 'job_manager' )
79
+ ) );
80
+ }
81
+
82
+ /**
83
+ * Submit Step is posted
84
+ */
85
+ public static function submit_handler() {
86
+ if ( empty( $_POST['submit_job'] ) || ! wp_verify_nonce( $_POST['_wpnonce'], 'submit_form_posted' ) )
87
+ return;
88
+
89
+ try {
90
+
91
+ // Get posted values
92
+ $values = self::get_posted_fields();
93
+
94
+ // Validate required
95
+ if ( is_wp_error( ( $return = self::validate_fields( $values ) ) ) )
96
+ throw new Exception( $return->get_error_message() );
97
+
98
+ // Update the job
99
+ self::save_job( $values['job']['job_title'], $values['job']['job_description'], 'publish' );
100
+ self::update_job_data( $values );
101
+
102
+ // Successful
103
+ echo '<div class="job-manager-message">' . __( 'Your changes have been saved.', 'job_manager' ), ' <a href="' . get_permalink( self::$job_id ) . '">' . __( 'View Job Listing &rarr;', 'job_manager' ) . '</a>' . '</div>';
104
+
105
+ } catch ( Exception $e ) {
106
+ echo '<div class="job-manager-error">' . $e->getMessage() . '</div>';
107
+ return;
108
+ }
109
+ }
110
+ }
includes/forms/class-wp-job-manager-form-submit-job.php ADDED
@@ -0,0 +1,546 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * WP_Job_Manager_Form_Submit_Job class.
5
+ */
6
+ class WP_Job_Manager_Form_Submit_Job extends WP_Job_Manager_Form {
7
+
8
+ public static $form_name = 'submit-job';
9
+ protected static $job_id;
10
+ protected static $preview_job;
11
+ protected static $steps;
12
+ protected static $step;
13
+
14
+ /**
15
+ * Init form
16
+ */
17
+ public static function init() {
18
+ add_action( 'wp', array( __CLASS__, 'process' ) );
19
+
20
+ // Get step/job
21
+ self::$step = ! empty( $_REQUEST['step'] ) ? max( absint( $_REQUEST['step'] ), 0 ) : 0;
22
+ self::$job_id = ! empty( $_REQUEST['job_id'] ) ? absint( $_REQUEST[ 'job_id' ] ) : 0;
23
+
24
+ self::$steps = (array) apply_filters( 'submit_job_steps', array(
25
+ 'submit' => array(
26
+ 'name' => __( 'Submit Details', 'job_manager' ),
27
+ 'view' => array( __CLASS__, 'submit' ),
28
+ 'handler' => array( __CLASS__, 'submit_handler' ),
29
+ 'priority' => 10
30
+ ),
31
+ 'preview' => array(
32
+ 'name' => __( 'Preview', 'job_manager' ),
33
+ 'view' => array( __CLASS__, 'preview' ),
34
+ 'handler' => array( __CLASS__, 'preview_handler' ),
35
+ 'priority' => 20
36
+ ),
37
+ 'done' => array(
38
+ 'name' => __( 'Done', 'job_manager' ),
39
+ 'view' => array( __CLASS__, 'done' ),
40
+ 'priority' => 30
41
+ )
42
+ ) );
43
+
44
+ usort( self::$steps, array( __CLASS__, 'sort_by_priority' ) );
45
+
46
+ // Validate job ID if set
47
+ if ( self::$job_id && ! in_array( get_post_status( self::$job_id ), apply_filters( 'job_manager_valid_submit_job_statuses', array( 'preview' ) ) ) ) {
48
+ self::$job_id = 0;
49
+ self::$step = 0;
50
+ }
51
+ }
52
+
53
+ /**
54
+ * Increase step from outside of the class
55
+ */
56
+ public function next_step() {
57
+ self::$step ++;
58
+ }
59
+
60
+ /**
61
+ * Decrease step from outside of the class
62
+ */
63
+ public function previous_step() {
64
+ self::$step --;
65
+ }
66
+
67
+ /**
68
+ * Sort array by priority value
69
+ */
70
+ private function sort_by_priority( $a, $b ) {
71
+ return $a['priority'] - $b['priority'];
72
+ }
73
+
74
+ /**
75
+ * Get the submitted job ID
76
+ * @return int
77
+ */
78
+ public static function get_job_id() {
79
+ return absint( self::$job_id );
80
+ }
81
+
82
+ /**
83
+ * init_fields function.
84
+ *
85
+ * @access public
86
+ * @return void
87
+ */
88
+ public static function init_fields() {
89
+ if ( self::$fields )
90
+ return;
91
+
92
+ self::$fields = apply_filters( 'submit_job_form_fields', array(
93
+ 'job' => array(
94
+ 'job_title' => array(
95
+ 'label' => __( 'Job title', 'job_manager' ),
96
+ 'type' => 'text',
97
+ 'required' => true,
98
+ 'placeholder' => '',
99
+ 'priority' => 1
100
+ ),
101
+ 'job_location' => array(
102
+ 'label' => __( 'Job location', 'job_manager' ),
103
+ 'description' => __( 'Leave this blank if the job can be done from anywhere (i.e. telecommuting)', 'job_manager' ),
104
+ 'type' => 'text',
105
+ 'required' => false,
106
+ 'placeholder' => __( 'e.g. "London, UK", "New York", "Houston, TX"', 'job_manager' ),
107
+ 'priority' => 2
108
+ ),
109
+ 'job_type' => array(
110
+ 'label' => __( 'Job type', 'job_manager' ),
111
+ 'type' => 'select',
112
+ 'required' => true,
113
+ 'options' => self::job_types(),
114
+ 'placeholder' => '',
115
+ 'priority' => 3
116
+ ),
117
+ 'job_category' => array(
118
+ 'label' => __( 'Job category', 'job_manager' ),
119
+ 'type' => 'select',
120
+ 'required' => true,
121
+ 'options' => self::job_categories(),
122
+ 'placeholder' => '',
123
+ 'priority' => 4
124
+ ),
125
+ 'job_description' => array(
126
+ 'label' => __( 'Description', 'job_manager' ),
127
+ 'type' => 'job-description',
128
+ 'required' => true,
129
+ 'placeholder' => '',
130
+ 'priority' => 5
131
+ ),
132
+ 'application' => array(
133
+ 'label' => __( 'Application email/URL', 'job_manager' ),
134
+ 'type' => 'text',
135
+ 'required' => true,
136
+ 'placeholder' => __( 'Enter an email address or website URL', 'job_manager' ),
137
+ 'priority' => 6
138
+ )
139
+ ),
140
+ 'company' => array(
141
+ 'company_name' => array(
142
+ 'label' => __( 'Company name', 'job_manager' ),
143
+ 'type' => 'text',
144
+ 'required' => true,
145
+ 'placeholder' => __( 'Enter the name of the company', 'job_manager' ),
146
+ 'priority' => 1
147
+ ),
148
+ 'company_website' => array(
149
+ 'label' => __( 'Website', 'job_manager' ),
150
+ 'type' => 'text',
151
+ 'required' => false,
152
+ 'placeholder' => __( 'http://', 'job_manager' ),
153
+ 'priority' => 2
154
+ ),
155
+ 'company_tagline' => array(
156
+ 'label' => __( 'Tagline', 'job_manager' ),
157
+ 'type' => 'text',
158
+ 'required' => false,
159
+ 'placeholder' => __( 'Briefly describe your company', 'job_manager' ),
160
+ 'maxlength' => 64,
161
+ 'priority' => 3
162
+ ),
163
+ 'company_twitter' => array(
164
+ 'label' => __( 'Twitter username', 'job_manager' ),
165
+ 'type' => 'text',
166
+ 'required' => false,
167
+ 'placeholder' => __( '@yourcompany', 'job_manager' ),
168
+ 'priority' => 4
169
+ ),
170
+ 'company_logo' => array(
171
+ 'label' => __( 'Logo', 'job_manager' ),
172
+ 'type' => 'file',
173
+ 'required' => false,
174
+ 'placeholder' => '',
175
+ 'priority' => 5
176
+ )
177
+ )
178
+ ) );
179
+
180
+ if ( ! get_option( 'job_manager_enable_categories' ) || wp_count_terms( 'job_listing_category' ) == 0 )
181
+ unset( self::$fields['job']['job_category'] );
182
+ }
183
+
184
+ /**
185
+ * Get post data for fields
186
+ *
187
+ * @return array of data
188
+ */
189
+ protected function get_posted_fields() {
190
+ self::init_fields();
191
+
192
+ $values = array();
193
+
194
+ foreach ( self::$fields as $group_key => $fields ) {
195
+ foreach ( $fields as $key => $field ) {
196
+ $values[ $group_key ][ $key ] = isset( $_POST[ $key ] ) ? stripslashes( $_POST[ $key ] ) : '';
197
+
198
+ switch ( $key ) {
199
+ case 'job_description' :
200
+ $values[ $group_key ][ $key ] = wp_kses_post( trim( $values[ $group_key ][ $key ] ) );
201
+ break;
202
+ case 'company_logo' :
203
+ $image_url = self::upload_image( 'company_logo' );
204
+ if ( $image_url )
205
+ $values[ $group_key ][ $key ] = $image_url;
206
+ break;
207
+ default:
208
+ $values[ $group_key ][ $key ] = sanitize_text_field( $values[ $group_key ][ $key ] );
209
+ break;
210
+ }
211
+
212
+ // Set fields value
213
+ self::$fields[ $group_key ][ $key ]['value'] = $values[ $group_key ][ $key ];
214
+ }
215
+ }
216
+
217
+ return $values;
218
+ }
219
+
220
+ /**
221
+ * Validate hte posted fields
222
+ *
223
+ * @return bool on success, WP_ERROR on failure
224
+ */
225
+ protected function validate_fields( $values ) {
226
+ foreach ( self::$fields as $group_key => $fields ) {
227
+ foreach ( $fields as $key => $field ) {
228
+ if ( $field['required'] && empty( $values[ $group_key ][ $key ] ) )
229
+ return new WP_Error( 'validation-error', sprintf( __( '%s is a required field', 'job_manager' ), $field['label'] ) );
230
+ }
231
+ }
232
+
233
+ return true;
234
+ }
235
+
236
+ /**
237
+ * job_types function.
238
+ *
239
+ * @access private
240
+ * @return void
241
+ */
242
+ private function job_types() {
243
+ $options = array();
244
+ $terms = get_job_listing_types();
245
+ foreach ( $terms as $term )
246
+ $options[ $term->slug ] = $term->name;
247
+ return $options;
248
+ }
249
+
250
+ /**
251
+ * job_types function.
252
+ *
253
+ * @access private
254
+ * @return void
255
+ */
256
+ private function job_categories() {
257
+ $options = array();
258
+ $terms = get_job_listing_categories();
259
+ foreach ( $terms as $term )
260
+ $options[ $term->slug ] = $term->name;
261
+ return $options;
262
+ }
263
+
264
+ /**
265
+ * Process function. all processing code if needed - can also change view if step is complete
266
+ */
267
+ public static function process() {
268
+ $keys = array_keys( self::$steps );
269
+
270
+ if ( isset( $keys[ self::$step ] ) && is_callable( self::$steps[ $keys[ self::$step ] ]['handler'] ) ) {
271
+ call_user_func( self::$steps[ $keys[ self::$step ] ]['handler'] );
272
+ }
273
+ }
274
+
275
+ /**
276
+ * output function. Call the view handler.
277
+ */
278
+ public static function output() {
279
+ $keys = array_keys( self::$steps );
280
+
281
+ self::show_errors();
282
+
283
+ if ( isset( $keys[ self::$step ] ) && is_callable( self::$steps[ $keys[ self::$step ] ]['view'] ) ) {
284
+ call_user_func( self::$steps[ $keys[ self::$step ] ]['view'] );
285
+ }
286
+ }
287
+
288
+ /**
289
+ * Submit Step
290
+ */
291
+ public static function submit() {
292
+ global $job_manager, $post;
293
+
294
+ self::init_fields();
295
+
296
+ // Load data if neccessary
297
+ if ( ! empty( $_POST['edit_job'] ) && self::$job_id ) {
298
+ $job = get_post( self::$job_id );
299
+ foreach ( self::$fields as $group_key => $fields ) {
300
+ foreach ( $fields as $key => $field ) {
301
+ switch ( $key ) {
302
+ case 'job_title' :
303
+ self::$fields[ $group_key ][ $key ]['value'] = $job->post_title;
304
+ break;
305
+ case 'job_description' :
306
+ self::$fields[ $group_key ][ $key ]['value'] = $job->post_content;
307
+ break;
308
+ case 'job_type' :
309
+ self::$fields[ $group_key ][ $key ]['value'] = current( wp_get_object_terms( $job->ID, 'job_listing_type', array( 'fields' => 'slugs' ) ) );
310
+ break;
311
+ case 'job_category' :
312
+ self::$fields[ $group_key ][ $key ]['value'] = current( wp_get_object_terms( $job->ID, 'job_listing_category', array( 'fields' => 'slugs' ) ) );
313
+ break;
314
+ default:
315
+ self::$fields[ $group_key ][ $key ]['value'] = get_post_meta( $job->ID, '_' . $key, true );
316
+ break;
317
+ }
318
+ }
319
+ }
320
+
321
+ // Get user meta
322
+ } elseif ( is_user_logged_in() && empty( $_POST ) ) {
323
+ if ( is_user_logged_in() ) {
324
+ foreach ( self::$fields[ 'company' ] as $key => $field ) {
325
+ self::$fields[ 'company' ][ $key ]['value'] = get_user_meta( get_current_user_id(), '_' . $key, true );
326
+ }
327
+ }
328
+ }
329
+
330
+ get_job_manager_template( 'job-submit.php', array(
331
+ 'form' => self::$form_name,
332
+ 'job_id' => self::get_job_id(),
333
+ 'action' => self::get_action(),
334
+ 'job_fields' => self::get_fields( 'job' ),
335
+ 'company_fields' => self::get_fields( 'company' ),
336
+ 'submit_button_text' => __( 'Preview job listing &rarr;', 'job_manager' )
337
+ ) );
338
+ }
339
+
340
+ /**
341
+ * Submit Step is posted
342
+ */
343
+ public static function submit_handler() {
344
+ try {
345
+
346
+ // Get posted values
347
+ $values = self::get_posted_fields();
348
+
349
+ if ( empty( $_POST['submit_job'] ) || ! wp_verify_nonce( $_POST['_wpnonce'], 'submit_form_posted' ) )
350
+ return;
351
+
352
+ // Validate required
353
+ if ( is_wp_error( ( $return = self::validate_fields( $values ) ) ) )
354
+ throw new Exception( $return->get_error_message() );
355
+
356
+ // Account creation
357
+ if ( ! is_user_logged_in() ) {
358
+ $create_account = false;
359
+
360
+ if ( job_manager_enable_registration() && ! empty( $_POST['create_account_email'] ) )
361
+ $create_account = wp_job_manager_create_account( $_POST['create_account_email'] );
362
+
363
+ if ( is_wp_error( $create_account ) )
364
+ throw new Exception( $create_account->get_error_message() );
365
+ }
366
+
367
+ if ( job_manager_user_requires_account() && ! is_user_logged_in() )
368
+ throw new Exception( __( 'You must be signed in to post a new job listing.' ) );
369
+
370
+ // Update the job
371
+ self::save_job( $values['job']['job_title'], $values['job']['job_description'] );
372
+ self::update_job_data( $values );
373
+
374
+ // Successful, show next step
375
+ self::$step ++;
376
+
377
+ } catch ( Exception $e ) {
378
+ self::add_error( $e->getMessage() );
379
+ return;
380
+ }
381
+ }
382
+
383
+ /**
384
+ * Update or create a job listing from posted data
385
+ *
386
+ * @param string $post_title
387
+ * @param string $post_content
388
+ * @param string $status
389
+ */
390
+ protected function save_job( $post_title, $post_content, $status = 'preview' ) {
391
+ $job_data = array(
392
+ 'post_title' => $post_title,
393
+ 'post_content' => $post_content,
394
+ 'post_status' => $status,
395
+ 'post_type' => 'job_listing',
396
+ 'comment_status' => 'closed'
397
+ );
398
+
399
+ if ( self::$job_id ) {
400
+ $job_data['ID'] = self::$job_id;
401
+ wp_update_post( $job_data );
402
+ } else {
403
+ self::$job_id = wp_insert_post( $job_data );
404
+ }
405
+ }
406
+
407
+ /**
408
+ * Set job meta + terms based on posted values
409
+ *
410
+ * @param array $values
411
+ */
412
+ protected function update_job_data( $values ) {
413
+
414
+ wp_set_object_terms( self::$job_id, array( $values['job']['job_type'] ), 'job_listing_type', false );
415
+
416
+ if ( get_option( 'job_manager_enable_categories' ) && isset( $values['job']['job_category'] ) ) {
417
+ wp_set_object_terms( self::$job_id, array( $values['job']['job_category'] ), 'job_listing_category', false );
418
+ }
419
+
420
+ update_post_meta( self::$job_id, '_application', $values['job']['application'] );
421
+ update_post_meta( self::$job_id, '_job_location', $values['job']['job_location'] );
422
+ update_post_meta( self::$job_id, '_company_name', $values['company']['company_name'] );
423
+ update_post_meta( self::$job_id, '_company_website', $values['company']['company_website'] );
424
+ update_post_meta( self::$job_id, '_company_tagline', $values['company']['company_tagline'] );
425
+ update_post_meta( self::$job_id, '_company_twitter', $values['company']['company_twitter'] );
426
+ update_post_meta( self::$job_id, '_company_logo', $values['company']['company_logo'] );
427
+ update_post_meta( self::$job_id, '_filled', 0 );
428
+
429
+ // And user meta to save time in future
430
+ if ( is_user_logged_in() ) {
431
+ update_user_meta( get_current_user_id(), '_company_name', $values['company']['company_name'] );
432
+ update_user_meta( get_current_user_id(), '_company_website', $values['company']['company_website'] );
433
+ update_user_meta( get_current_user_id(), '_company_tagline', $values['company']['company_tagline'] );
434
+ update_user_meta( get_current_user_id(), '_company_twitter', $values['company']['company_twitter'] );
435
+ update_user_meta( get_current_user_id(), '_company_logo', $values['company']['company_logo'] );
436
+ }
437
+ }
438
+
439
+ /**
440
+ * Preview Step
441
+ */
442
+ public static function preview() {
443
+ global $job_manager, $post;
444
+
445
+ if ( self::$job_id ) {
446
+
447
+ $post = get_post( self::$job_id );
448
+ setup_postdata( $post );
449
+
450
+ ?>
451
+ <form method="post" id="job_preview">
452
+ <h2 class="job_listing_preview_title">
453
+ <input type="submit" name="continue" id="job_preview_submit_button" class="button" value="<?php echo apply_filters( 'submit_job_step_preview_submit_text', __( 'Submit Listing &rarr;', 'job_manager' ) ); ?>" />
454
+ <input type="submit" name="edit_job" class="button" value="<?php _e( '&larr; Edit listing', 'job_manager' ); ?>" />
455
+ <input type="hidden" name="job_id" value="<?php echo esc_attr( self::$job_id ); ?>" />
456
+ <input type="hidden" name="step" value="<?php echo esc_attr( self::$step ); ?>" />
457
+ <input type="hidden" name="job_manager_form" value="<?php echo self::$form_name; ?>" />
458
+ <?php _e( 'Preview', 'job_manager' ); ?>
459
+ </h2>
460
+ <div class="job_listing_preview single_job_listing">
461
+ <h1><?php the_title(); ?></h1>
462
+ <?php get_job_manager_template_part( 'content-single', 'job_listing' ); ?>
463
+ </div>
464
+ </form>
465
+ <?php
466
+
467
+ wp_reset_postdata();
468
+ }
469
+ }
470
+
471
+ /**
472
+ * Preview Step Form handler
473
+ */
474
+ public static function preview_handler() {
475
+ if ( ! $_POST )
476
+ return;
477
+
478
+ // Edit = show submit form again
479
+ if ( ! empty( $_POST['edit_job'] ) ) {
480
+ self::$step --;
481
+ }
482
+ // Continue = change job status then show next screen
483
+ if ( ! empty( $_POST['continue'] ) ) {
484
+
485
+ $job = get_post( self::$job_id );
486
+
487
+ if ( $job->post_status == 'preview' ) {
488
+ $update_job = array();
489
+ $update_job['ID'] = $job->ID;
490
+ $update_job['post_status'] = get_option( 'job_manager_submission_requires_approval' ) ? 'pending' : 'publish';
491
+ wp_update_post( $update_job );
492
+ }
493
+
494
+ self::$step ++;
495
+ }
496
+ }
497
+
498
+ /**
499
+ * Done Step
500
+ */
501
+ public static function done() {
502
+ get_job_manager_template( 'job-submitted.php', array( 'job' => get_post( self::$job_id ) ) );
503
+ }
504
+
505
+ /**
506
+ * Upload Image
507
+ */
508
+ public static function upload_image( $field_key ) {
509
+
510
+ /** WordPress Administration File API */
511
+ include_once( ABSPATH . 'wp-admin/includes/file.php' );
512
+
513
+ /** WordPress Media Administration API */
514
+ include_once( ABSPATH . 'wp-admin/includes/media.php' );
515
+
516
+ if ( isset( $_FILES[ $field_key ] ) && ! empty( $_FILES[ $field_key ] ) && ! empty( $_FILES[ $field_key ]['name'] ) ) {
517
+ $file = $_FILES[ $field_key ];
518
+
519
+ if ( $_FILES[ $field_key ]["type"] != "image/jpeg" && $_FILES[ $field_key ]["type"] != "image/gif" && $_FILES[ $field_key ]["type"] != "image/png" )
520
+ throw new Exception( __( 'Logo needs to be jpg, gif or png.', 'job_manager' ) );
521
+
522
+ add_filter( 'upload_dir', array( __CLASS__, 'upload_dir' ) );
523
+
524
+ $upload = wp_handle_upload( $file, array( 'test_form' => false ) );
525
+
526
+ remove_filter('upload_dir', array( __CLASS__, 'upload_dir' ) );
527
+
528
+ if ( ! empty( $upload['error'] ) ) {
529
+ throw new Exception( $upload['error'] );
530
+ } else {
531
+ return $upload['url'];
532
+ }
533
+ }
534
+ }
535
+
536
+ /**
537
+ * Filter the upload directory
538
+ */
539
+ public static function upload_dir( $pathdata ) {
540
+ $subdir = '/job_listing_images';
541
+ $pathdata['path'] = str_replace( $pathdata['subdir'], $subdir, $pathdata['path'] );
542
+ $pathdata['url'] = str_replace( $pathdata['subdir'], $subdir, $pathdata['url'] );
543
+ $pathdata['subdir'] = str_replace( $pathdata['subdir'], $subdir, $pathdata['subdir'] );
544
+ return $pathdata;
545
+ }
546
+ }
languages/job_manager-pt_PT.mo ADDED
Binary file
languages/job_manager-pt_PT.po ADDED
@@ -0,0 +1,813 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2013 WP Job Manager
2
+ # This file is distributed under the same license as the WP Job Manager package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: WP Job Manager 1.0 Beta 1\n"
6
+ "Report-Msgid-Bugs-To: http://wordpress.org/tag/WP-Job-Manager\n"
7
+ "POT-Creation-Date: 2013-06-25 13:52:15+00:00\n"
8
+ "MIME-Version: 1.0\n"
9
+ "Content-Type: text/plain; charset=UTF-8\n"
10
+ "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2013-06-25 15:38-0000\n"
12
+ "Last-Translator: WordPress Portugal <http;//wp-portugal.com>\n"
13
+ "Language-Team: WordPress Portugal <http://wp-portugal.com>\n"
14
+ "Plural-Forms: nplurals=2; plural=n != 1;\n"
15
+ "Language: pt\n"
16
+ "X-Generator: Poedit 1.5.5\n"
17
+ "X-Poedit-SourceCharset: UTF-8\n"
18
+
19
+ #: includes/admin/class-wp-job-manager-admin.php:49
20
+ msgid "Settings"
21
+ msgstr "Opções"
22
+
23
+ #: includes/admin/class-wp-job-manager-cpt.php:67
24
+ msgid "Select a category"
25
+ msgstr "Escolha uma categoria"
26
+
27
+ #: includes/admin/class-wp-job-manager-cpt.php:100
28
+ msgid "Job position title"
29
+ msgstr "Posição"
30
+
31
+ #: includes/admin/class-wp-job-manager-cpt.php:116
32
+ msgid "Job listing updated. <a href=\"%s\">View Job</a>"
33
+ msgstr "Anúncio actualizado. <a href=\"%s\">Ver anúncio</a>"
34
+
35
+ #: includes/admin/class-wp-job-manager-cpt.php:117
36
+ msgid "Custom field updated."
37
+ msgstr "Campo personalizado actualizado."
38
+
39
+ #: includes/admin/class-wp-job-manager-cpt.php:118
40
+ msgid "Custom field deleted."
41
+ msgstr "Campo personalizado eliminado."
42
+
43
+ #: includes/admin/class-wp-job-manager-cpt.php:119
44
+ msgid "Job listing updated."
45
+ msgstr "Anúncio actualizado."
46
+
47
+ #: includes/admin/class-wp-job-manager-cpt.php:120
48
+ msgid "Job listing restored to revision from %s"
49
+ msgstr "Anúncio reposto para a revisão de %s"
50
+
51
+ #: includes/admin/class-wp-job-manager-cpt.php:121
52
+ msgid "Job listing published. <a href=\"%s\">View Job</a>"
53
+ msgstr "Anúncio publicado. <a href=\"%s\">Ver anúncio</a>"
54
+
55
+ #: includes/admin/class-wp-job-manager-cpt.php:122
56
+ msgid "Job listing saved."
57
+ msgstr "Anúncio guardado."
58
+
59
+ #: includes/admin/class-wp-job-manager-cpt.php:123
60
+ msgid "Job listing submitted. <a target=\"_blank\" href=\"%s\">Preview Job</a>"
61
+ msgstr ""
62
+ "Anúncio submetido. <a target=\"_blank\" href=\"%s\">Pré-visualizar anúncio</"
63
+ "a>"
64
+
65
+ #: includes/admin/class-wp-job-manager-cpt.php:124
66
+ msgid ""
67
+ "Job listing scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href="
68
+ "\"%2$s\">Preview Job</a>"
69
+ msgstr ""
70
+ "Anúncio agendado para: <strong>%1$s</strong>. <a target=\"_blank\" href="
71
+ "\"%2$s\">Pré-visualizar anúncio</a>"
72
+
73
+ #: includes/admin/class-wp-job-manager-cpt.php:125
74
+ msgid "M j, Y @ G:i"
75
+ msgstr "j M, Y @ H:i"
76
+
77
+ #: includes/admin/class-wp-job-manager-cpt.php:126
78
+ msgid ""
79
+ "Job listing draft updated. <a target=\"_blank\" href=\"%s\">Preview Job</a>"
80
+ msgstr ""
81
+ "Rascunho de anúncio actualizado. <a target=\"_blank\" href=\"%2$s\">Pré-"
82
+ "visualizar anúncio</a>"
83
+
84
+ #: includes/admin/class-wp-job-manager-cpt.php:143
85
+ msgid "Type"
86
+ msgstr "Tipo"
87
+
88
+ #: includes/admin/class-wp-job-manager-cpt.php:144
89
+ msgid "Position"
90
+ msgstr "Posição"
91
+
92
+ #: includes/admin/class-wp-job-manager-cpt.php:145
93
+ msgid "Company"
94
+ msgstr "Empresa"
95
+
96
+ #: includes/admin/class-wp-job-manager-cpt.php:146
97
+ #: templates/content-single-job_listing.php:14
98
+ msgid "Posted"
99
+ msgstr "Publicado"
100
+
101
+ #: includes/admin/class-wp-job-manager-cpt.php:147
102
+ #: templates/job-dashboard.php:9
103
+ msgid "Expires"
104
+ msgstr "Expira"
105
+
106
+ #: includes/admin/class-wp-job-manager-cpt.php:149
107
+ msgid "Categories"
108
+ msgstr "Categorias"
109
+
110
+ #: includes/admin/class-wp-job-manager-cpt.php:150
111
+ msgid "Job Status"
112
+ msgstr "Estado"
113
+
114
+ #: includes/admin/class-wp-job-manager-cpt.php:151
115
+ #: templates/job-dashboard.php:10
116
+ msgid "Filled?"
117
+ msgstr "Preenchido?"
118
+
119
+ #: includes/admin/class-wp-job-manager-cpt.php:152
120
+ msgid "Actions"
121
+ msgstr "Acções"
122
+
123
+ #: includes/admin/class-wp-job-manager-cpt.php:199
124
+ msgid "by a guest"
125
+ msgstr "por um convidado"
126
+
127
+ #: includes/admin/class-wp-job-manager-cpt.php:199
128
+ msgid "by %s"
129
+ msgstr "por %s"
130
+
131
+ #: includes/admin/class-wp-job-manager-cpt.php:212
132
+ msgid "View"
133
+ msgstr "Ver"
134
+
135
+ #: includes/admin/class-wp-job-manager-cpt.php:217
136
+ #: includes/class-wp-job-manager-post-types.php:149
137
+ #: templates/job-dashboard.php:29
138
+ msgid "Edit"
139
+ msgstr "Editar"
140
+
141
+ #: includes/admin/class-wp-job-manager-cpt.php:222
142
+ #: templates/job-dashboard.php:39
143
+ msgid "Delete"
144
+ msgstr "Eliminar"
145
+
146
+ #: includes/admin/class-wp-job-manager-settings.php:31
147
+ #: includes/class-wp-job-manager-post-types.php:125
148
+ msgid "Job Listings"
149
+ msgstr "Anúncios"
150
+
151
+ #: includes/admin/class-wp-job-manager-settings.php:37
152
+ msgid "Jobs per page"
153
+ msgstr "Anúncios por página"
154
+
155
+ #: includes/admin/class-wp-job-manager-settings.php:38
156
+ msgid "How many jobs should be shown per page by default?"
157
+ msgstr "Quantos anúncios devem ser mostrados por página, por omissão?"
158
+
159
+ #: includes/admin/class-wp-job-manager-settings.php:43
160
+ msgid "Filled positions"
161
+ msgstr "Posições preenchidas"
162
+
163
+ #: includes/admin/class-wp-job-manager-settings.php:44
164
+ msgid "Hide filled positions"
165
+ msgstr "Esconder posições preenchidas"
166
+
167
+ #: includes/admin/class-wp-job-manager-settings.php:45
168
+ msgid "If enabled, filled positions will be hidden from the job list."
169
+ msgstr "Se activo, as posições preenchidas serão escondidas da lista."
170
+
171
+ #: includes/admin/class-wp-job-manager-settings.php:51
172
+ msgid "Job categories"
173
+ msgstr "Categorias de anúncios"
174
+
175
+ #: includes/admin/class-wp-job-manager-settings.php:52
176
+ msgid "Enable job categories"
177
+ msgstr "Activar categorias de anúncios"
178
+
179
+ #: includes/admin/class-wp-job-manager-settings.php:53
180
+ msgid ""
181
+ "Choose whether to enable job categories. Categories must be setup by an "
182
+ "admin for users to choose during job submission."
183
+ msgstr ""
184
+ "Escolha se quer activar as categorías de anúncios. As categorías deverão ser "
185
+ "criadas por um administrador para que os utilizadores as possam escolher "
186
+ "aquando da submissão de um anúncio."
187
+
188
+ #: includes/admin/class-wp-job-manager-settings.php:59
189
+ msgid "Job Submission"
190
+ msgstr "Submissão de anúncio"
191
+
192
+ #: includes/admin/class-wp-job-manager-settings.php:64
193
+ msgid "Account creation"
194
+ msgstr "Criação de conta"
195
+
196
+ #: includes/admin/class-wp-job-manager-settings.php:65
197
+ msgid "Allow account creation"
198
+ msgstr "Permitir a criação de conta"
199
+
200
+ #: includes/admin/class-wp-job-manager-settings.php:66
201
+ msgid ""
202
+ "If enable, non-logged in users will be able to create an account by entering "
203
+ "their email address on the job submission form."
204
+ msgstr ""
205
+
206
+ #: includes/admin/class-wp-job-manager-settings.php:72
207
+ msgid "Account required"
208
+ msgstr "Conta obrigatória"
209
+
210
+ #: includes/admin/class-wp-job-manager-settings.php:73
211
+ msgid "Job submission requires an account"
212
+ msgstr ""
213
+
214
+ #: includes/admin/class-wp-job-manager-settings.php:74
215
+ msgid ""
216
+ "If disabled, non-logged in users will be able to submit job listings without "
217
+ "creating an account."
218
+ msgstr ""
219
+
220
+ #: includes/admin/class-wp-job-manager-settings.php:80
221
+ msgid "Approval Required"
222
+ msgstr ""
223
+
224
+ #: includes/admin/class-wp-job-manager-settings.php:81
225
+ msgid "New submissions require admin approval"
226
+ msgstr ""
227
+
228
+ #: includes/admin/class-wp-job-manager-settings.php:82
229
+ msgid "If enabled, new submissions will be inactive, pending admin approval."
230
+ msgstr ""
231
+
232
+ #: includes/admin/class-wp-job-manager-settings.php:88
233
+ msgid "Listing duration"
234
+ msgstr ""
235
+
236
+ #: includes/admin/class-wp-job-manager-settings.php:89
237
+ msgid ""
238
+ "How many <strong>days</strong> listings are live before expiring. Can be "
239
+ "left blank to never expire."
240
+ msgstr ""
241
+
242
+ #: includes/admin/class-wp-job-manager-settings.php:141
243
+ msgid "Settings successfully saved"
244
+ msgstr ""
245
+
246
+ #: includes/admin/class-wp-job-manager-settings.php:208
247
+ msgid "Save Changes"
248
+ msgstr ""
249
+
250
+ #: includes/admin/class-wp-job-manager-writepanels.php:19
251
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:88
252
+ msgid "Job location"
253
+ msgstr ""
254
+
255
+ #: includes/admin/class-wp-job-manager-writepanels.php:20
256
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:91
257
+ msgid "e.g. \"London, UK\", \"New York\", \"Anywhere\""
258
+ msgstr ""
259
+
260
+ #: includes/admin/class-wp-job-manager-writepanels.php:23
261
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:118
262
+ msgid "Application email/URL"
263
+ msgstr ""
264
+
265
+ #: includes/admin/class-wp-job-manager-writepanels.php:24
266
+ msgid "URL or email which applicants use to apply"
267
+ msgstr ""
268
+
269
+ #: includes/admin/class-wp-job-manager-writepanels.php:27
270
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:127
271
+ msgid "Company name"
272
+ msgstr ""
273
+
274
+ #: includes/admin/class-wp-job-manager-writepanels.php:31
275
+ msgid "Company website"
276
+ msgstr ""
277
+
278
+ #: includes/admin/class-wp-job-manager-writepanels.php:35
279
+ msgid "Company tagline"
280
+ msgstr ""
281
+
282
+ #: includes/admin/class-wp-job-manager-writepanels.php:36
283
+ msgid "Brief description about the company"
284
+ msgstr ""
285
+
286
+ #: includes/admin/class-wp-job-manager-writepanels.php:39
287
+ msgid "Company Twitter"
288
+ msgstr ""
289
+
290
+ #: includes/admin/class-wp-job-manager-writepanels.php:43
291
+ msgid "Company logo"
292
+ msgstr ""
293
+
294
+ #: includes/admin/class-wp-job-manager-writepanels.php:44
295
+ msgid "URL to the company logo"
296
+ msgstr ""
297
+
298
+ #: includes/admin/class-wp-job-manager-writepanels.php:47
299
+ msgid "Position filled?"
300
+ msgstr ""
301
+
302
+ #: includes/admin/class-wp-job-manager-writepanels.php:60
303
+ msgid "Job Listing Data"
304
+ msgstr ""
305
+
306
+ #: includes/class-wp-job-manager-ajax.php:104
307
+ msgid "No more jobs found matching your selection."
308
+ msgstr ""
309
+
310
+ #: includes/class-wp-job-manager-ajax.php:143
311
+ msgid "Showing %s&ldquo;%s&rdquo; %sjobs"
312
+ msgstr ""
313
+
314
+ #: includes/class-wp-job-manager-ajax.php:145
315
+ msgid "Showing all %s%sjobs"
316
+ msgstr ""
317
+
318
+ #: includes/class-wp-job-manager-ajax.php:148
319
+ msgid "located in &ldquo;%s&rdquo;"
320
+ msgstr ""
321
+
322
+ #: includes/class-wp-job-manager-post-types.php:35
323
+ msgid "Job Category"
324
+ msgstr ""
325
+
326
+ #: includes/class-wp-job-manager-post-types.php:36
327
+ msgid "Job Categories"
328
+ msgstr ""
329
+
330
+ #: includes/class-wp-job-manager-post-types.php:40
331
+ msgctxt "Job category slug - resave permalinks after changing this"
332
+ msgid "job-category"
333
+ msgstr ""
334
+
335
+ #: includes/class-wp-job-manager-post-types.php:57
336
+ #: includes/class-wp-job-manager-post-types.php:100
337
+ #: includes/class-wp-job-manager-post-types.php:154
338
+ msgid "Search %s"
339
+ msgstr ""
340
+
341
+ #: includes/class-wp-job-manager-post-types.php:58
342
+ #: includes/class-wp-job-manager-post-types.php:101
343
+ #: includes/class-wp-job-manager-post-types.php:146
344
+ msgid "All %s"
345
+ msgstr ""
346
+
347
+ #: includes/class-wp-job-manager-post-types.php:59
348
+ #: includes/class-wp-job-manager-post-types.php:102
349
+ #: includes/class-wp-job-manager-post-types.php:157
350
+ msgid "Parent %s"
351
+ msgstr ""
352
+
353
+ #: includes/class-wp-job-manager-post-types.php:60
354
+ #: includes/class-wp-job-manager-post-types.php:103
355
+ msgid "Parent %s:"
356
+ msgstr ""
357
+
358
+ #: includes/class-wp-job-manager-post-types.php:61
359
+ #: includes/class-wp-job-manager-post-types.php:104
360
+ #: includes/class-wp-job-manager-post-types.php:150
361
+ msgid "Edit %s"
362
+ msgstr ""
363
+
364
+ #: includes/class-wp-job-manager-post-types.php:62
365
+ #: includes/class-wp-job-manager-post-types.php:105
366
+ msgid "Update %s"
367
+ msgstr ""
368
+
369
+ #: includes/class-wp-job-manager-post-types.php:63
370
+ #: includes/class-wp-job-manager-post-types.php:106
371
+ msgid "Add New %s"
372
+ msgstr ""
373
+
374
+ #: includes/class-wp-job-manager-post-types.php:64
375
+ #: includes/class-wp-job-manager-post-types.php:107
376
+ msgid "New %s Name"
377
+ msgstr ""
378
+
379
+ #: includes/class-wp-job-manager-post-types.php:79
380
+ msgid "Job Type"
381
+ msgstr ""
382
+
383
+ #: includes/class-wp-job-manager-post-types.php:80
384
+ msgid "Job Types"
385
+ msgstr ""
386
+
387
+ #: includes/class-wp-job-manager-post-types.php:84
388
+ msgctxt "Job type slug - resave permalinks after changing this"
389
+ msgid "job-type"
390
+ msgstr ""
391
+
392
+ #: includes/class-wp-job-manager-post-types.php:124
393
+ msgid "Job Listing"
394
+ msgstr ""
395
+
396
+ #: includes/class-wp-job-manager-post-types.php:128
397
+ msgctxt "Post type archive slug - resave permalinks after changing this"
398
+ msgid "jobs"
399
+ msgstr ""
400
+
401
+ #: includes/class-wp-job-manager-post-types.php:134
402
+ msgctxt "Job permalink - resave permalinks after changing this"
403
+ msgid "job"
404
+ msgstr ""
405
+
406
+ #: includes/class-wp-job-manager-post-types.php:147
407
+ msgid "Add New"
408
+ msgstr ""
409
+
410
+ #: includes/class-wp-job-manager-post-types.php:148
411
+ msgid "Add %s"
412
+ msgstr ""
413
+
414
+ #: includes/class-wp-job-manager-post-types.php:151
415
+ msgid "New %s"
416
+ msgstr ""
417
+
418
+ #: includes/class-wp-job-manager-post-types.php:152
419
+ #: includes/class-wp-job-manager-post-types.php:153
420
+ msgid "View %s"
421
+ msgstr ""
422
+
423
+ #: includes/class-wp-job-manager-post-types.php:155
424
+ msgid "No %s found"
425
+ msgstr ""
426
+
427
+ #: includes/class-wp-job-manager-post-types.php:156
428
+ msgid "No %s found in trash"
429
+ msgstr ""
430
+
431
+ #: includes/class-wp-job-manager-post-types.php:159
432
+ msgid "This is where you can create and manage job listings."
433
+ msgstr ""
434
+
435
+ #: includes/class-wp-job-manager-post-types.php:194
436
+ msgctxt "job_listing"
437
+ msgid "Expired"
438
+ msgstr ""
439
+
440
+ #: includes/class-wp-job-manager-post-types.php:199
441
+ msgid "Expired <span class=\"count\">(%s)</span>"
442
+ msgid_plural "Expired <span class=\"count\">(%s)</span>"
443
+ msgstr[0] ""
444
+ msgstr[1] ""
445
+
446
+ #: includes/class-wp-job-manager-shortcodes.php:61
447
+ msgid "Invalid Job ID"
448
+ msgstr ""
449
+
450
+ #: includes/class-wp-job-manager-shortcodes.php:67
451
+ msgid "This job is already filled"
452
+ msgstr ""
453
+
454
+ #: includes/class-wp-job-manager-shortcodes.php:73
455
+ msgid "%s has been filled"
456
+ msgstr ""
457
+
458
+ #: includes/class-wp-job-manager-shortcodes.php:78
459
+ msgid "This job is already not filled"
460
+ msgstr ""
461
+
462
+ #: includes/class-wp-job-manager-shortcodes.php:84
463
+ msgid "%s has been marked as not filled"
464
+ msgstr ""
465
+
466
+ #: includes/class-wp-job-manager-shortcodes.php:91
467
+ msgid "%s has been deleted"
468
+ msgstr ""
469
+
470
+ #: includes/class-wp-job-manager-shortcodes.php:111
471
+ msgid "You need to be signed in to manage your job listings."
472
+ msgstr ""
473
+
474
+ #: includes/class-wp-job-manager-shortcodes.php:175
475
+ msgid "Load more job listings"
476
+ msgstr ""
477
+
478
+ #: includes/class-wp-job-manager-widgets.php:139
479
+ msgid "Display a list of the most recent jobs on your site."
480
+ msgstr ""
481
+
482
+ #: includes/class-wp-job-manager-widgets.php:141
483
+ msgid "Recent Job Listings"
484
+ msgstr ""
485
+
486
+ #: includes/class-wp-job-manager-widgets.php:145
487
+ msgid "Recent Jobs"
488
+ msgstr ""
489
+
490
+ #: includes/class-wp-job-manager-widgets.php:146
491
+ msgid "Title"
492
+ msgstr ""
493
+
494
+ #: includes/class-wp-job-manager-widgets.php:154
495
+ msgid "Number of jobs to show"
496
+ msgstr ""
497
+
498
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:39
499
+ msgid "Invalid job"
500
+ msgstr ""
501
+
502
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:78
503
+ msgid "Update job listing"
504
+ msgstr ""
505
+
506
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:103
507
+ msgid "Your changes have been saved."
508
+ msgstr ""
509
+
510
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:103
511
+ msgid "View Job Listing &rarr;"
512
+ msgstr ""
513
+
514
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:26
515
+ msgid "Submit Details"
516
+ msgstr ""
517
+
518
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:32
519
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:441
520
+ msgid "Preview"
521
+ msgstr ""
522
+
523
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:38
524
+ msgid "Done"
525
+ msgstr ""
526
+
527
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:81
528
+ msgid "Job title"
529
+ msgstr ""
530
+
531
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:95
532
+ msgid "Job type"
533
+ msgstr ""
534
+
535
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:103
536
+ msgid "Job category"
537
+ msgstr ""
538
+
539
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:111
540
+ msgid "Description"
541
+ msgstr ""
542
+
543
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:121
544
+ msgid "Enter an email address or website URL"
545
+ msgstr ""
546
+
547
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:130
548
+ msgid "Enter the name of the company"
549
+ msgstr ""
550
+
551
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:134
552
+ #: templates/content-single-job_listing.php:25
553
+ msgid "Website"
554
+ msgstr ""
555
+
556
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:137
557
+ msgid "http://"
558
+ msgstr ""
559
+
560
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:141
561
+ msgid "Tagline"
562
+ msgstr ""
563
+
564
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:144
565
+ msgid "Briefly describe your company"
566
+ msgstr ""
567
+
568
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:148
569
+ msgid "Twitter username"
570
+ msgstr ""
571
+
572
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:151
573
+ msgid "@yourcompany"
574
+ msgstr ""
575
+
576
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:155
577
+ msgid "Logo"
578
+ msgstr ""
579
+
580
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:213
581
+ msgid "%s is a required field"
582
+ msgstr ""
583
+
584
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:320
585
+ msgid "Preview job listing &rarr;"
586
+ msgstr ""
587
+
588
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:352
589
+ msgid "You must be signed in to post a new job listing."
590
+ msgstr ""
591
+
592
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:436
593
+ msgid "Submit Listing &rarr;"
594
+ msgstr ""
595
+
596
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:437
597
+ msgid "&larr; Edit listing"
598
+ msgstr ""
599
+
600
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:505
601
+ msgid "Logo needs to be jpg, gif or png."
602
+ msgstr ""
603
+
604
+ #: templates/account-signin.php:4
605
+ msgid "Your account"
606
+ msgstr ""
607
+
608
+ #: templates/account-signin.php:8
609
+ msgid "You are currently signed in as <strong>%s</strong>."
610
+ msgstr ""
611
+
612
+ #: templates/account-signin.php:11
613
+ msgid "Sign out"
614
+ msgstr ""
615
+
616
+ #: templates/account-signin.php:21
617
+ msgid "Have an account?"
618
+ msgstr ""
619
+
620
+ #: templates/account-signin.php:23
621
+ msgid "Sign in"
622
+ msgstr ""
623
+
624
+ #: templates/account-signin.php:27
625
+ msgid ""
626
+ "If you don&lsquo;t have an account you can %screate one below by entering "
627
+ "your email address. A password will be automatically emailed to you."
628
+ msgstr ""
629
+
630
+ #: templates/account-signin.php:27
631
+ msgid "optionally"
632
+ msgstr ""
633
+
634
+ #: templates/account-signin.php:31
635
+ msgid "You must sign in to create a new job listing."
636
+ msgstr ""
637
+
638
+ #: templates/account-signin.php:38
639
+ msgid "Your email"
640
+ msgstr ""
641
+
642
+ #: templates/account-signin.php:38 templates/job-submit.php:21
643
+ #: templates/job-submit.php:32
644
+ msgid "(optional)"
645
+ msgstr ""
646
+
647
+ #: templates/content-job_listing.php:16
648
+ #: templates/content-single-job_listing.php:14
649
+ #: templates/content-summary-job_listing.php:14
650
+ msgid "ago"
651
+ msgstr ""
652
+
653
+ #: templates/content-single-job_listing.php:5
654
+ msgid "This job listing has expired"
655
+ msgstr ""
656
+
657
+ #: templates/content-single-job_listing.php:17
658
+ msgid "This position has been filled"
659
+ msgstr ""
660
+
661
+ #: templates/form-fields/file-field.php:3
662
+ msgid "or"
663
+ msgstr ""
664
+
665
+ #: templates/form-fields/file-field.php:10
666
+ msgid "Max. file size: %s. Allowed images: jpg, gif, png."
667
+ msgstr ""
668
+
669
+ #: templates/job-application.php:5
670
+ msgid "Apply for job"
671
+ msgstr ""
672
+
673
+ #: templates/job-application.php:12
674
+ msgid ""
675
+ "To apply for this job <strong>email your details to</strong> <a class="
676
+ "\"job_application_email\" href=\"mailto:%1$s%2$s\">%1$s</a>"
677
+ msgstr ""
678
+
679
+ #: templates/job-application.php:14
680
+ msgid "Apply using webmail: "
681
+ msgstr ""
682
+
683
+ #: templates/job-application.php:28
684
+ msgid ""
685
+ "To apply for this job please visit the following URL: <a href=\"%1$s\">%1$s "
686
+ "&rarr;</a>"
687
+ msgstr ""
688
+
689
+ #: templates/job-dashboard.php:2
690
+ msgid ""
691
+ "Your job listings are shown in the table below. Expired listings will be "
692
+ "automatically removed after 30 days."
693
+ msgstr ""
694
+
695
+ #: templates/job-dashboard.php:6
696
+ msgid "Job Title"
697
+ msgstr ""
698
+
699
+ #: templates/job-dashboard.php:7
700
+ msgid "Date Posted"
701
+ msgstr ""
702
+
703
+ #: templates/job-dashboard.php:8
704
+ msgid "Status"
705
+ msgstr ""
706
+
707
+ #: templates/job-dashboard.php:16
708
+ msgid "You do not have any active job listings."
709
+ msgstr ""
710
+
711
+ #: templates/job-dashboard.php:32
712
+ msgid "Mark not filled"
713
+ msgstr ""
714
+
715
+ #: templates/job-dashboard.php:34
716
+ msgid "Mark filled"
717
+ msgstr ""
718
+
719
+ #: templates/job-filters.php:6
720
+ msgid "Keywords"
721
+ msgstr ""
722
+
723
+ #: templates/job-filters.php:7
724
+ msgid "All Jobs"
725
+ msgstr ""
726
+
727
+ #: templates/job-filters.php:10
728
+ msgid "Location"
729
+ msgstr ""
730
+
731
+ #: templates/job-filters.php:11
732
+ msgid "Any Location"
733
+ msgstr ""
734
+
735
+ #: templates/job-filters.php:15
736
+ msgid "Category"
737
+ msgstr ""
738
+
739
+ #: templates/job-filters.php:17
740
+ msgid "All Job Categories"
741
+ msgstr ""
742
+
743
+ #: templates/job-filters.php:39
744
+ msgid "Reset"
745
+ msgstr ""
746
+
747
+ #: templates/job-filters.php:40
748
+ msgid "RSS"
749
+ msgstr ""
750
+
751
+ #: templates/job-submit.php:28
752
+ msgid "Company details"
753
+ msgstr ""
754
+
755
+ #: templates/job-submitted.php:3
756
+ msgid ""
757
+ "Job listed successfully. To view your job listing <a href=\"%s\">click here</"
758
+ "a>."
759
+ msgstr ""
760
+
761
+ #: templates/job-submitted.php:7
762
+ msgid ""
763
+ "Job submitted successfully. Your job listing will be visible once approved."
764
+ msgstr ""
765
+
766
+ #: wp-job-manager-functions.php:101
767
+ msgid "Your email address isn&#8217;t correct."
768
+ msgstr ""
769
+
770
+ #: wp-job-manager-functions.php:104
771
+ msgid "This email is already registered, please choose another one."
772
+ msgstr ""
773
+
774
+ #: wp-job-manager-template.php:146
775
+ msgid "Active"
776
+ msgstr ""
777
+
778
+ #: wp-job-manager-template.php:148
779
+ msgid "Expired"
780
+ msgstr ""
781
+
782
+ #: wp-job-manager-template.php:150
783
+ msgid "Pending Review"
784
+ msgstr ""
785
+
786
+ #: wp-job-manager-template.php:152
787
+ msgid "Inactive"
788
+ msgstr ""
789
+
790
+ #: wp-job-manager.php:89
791
+ msgid "Are you sure you want to delete this job?"
792
+ msgstr ""
793
+
794
+ #. Plugin Name of the plugin/theme
795
+ msgid "WP Job Manager"
796
+ msgstr ""
797
+
798
+ #. #-#-#-#-# wp-job-manager.pot (WP Job Manager 1.0 Beta 1) #-#-#-#-#
799
+ #. Plugin URI of the plugin/theme
800
+ #. #-#-#-#-# wp-job-manager.pot (WP Job Manager 1.0 Beta 1) #-#-#-#-#
801
+ #. Author URI of the plugin/theme
802
+ msgid "http://mikejolley.com"
803
+ msgstr ""
804
+
805
+ #. Description of the plugin/theme
806
+ msgid ""
807
+ "Manage job listings from the WordPress admin panel, and allow users to post "
808
+ "jobs directly to your site."
809
+ msgstr ""
810
+
811
+ #. Author of the plugin/theme
812
+ msgid "Mike Jolley"
813
+ msgstr ""
languages/job_manager.pot ADDED
@@ -0,0 +1,800 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2013 WP Job Manager
2
+ # This file is distributed under the same license as the WP Job Manager package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: WP Job Manager 1.0 Beta 1\n"
6
+ "Report-Msgid-Bugs-To: http://wordpress.org/tag/WP-Job-Manager\n"
7
+ "POT-Creation-Date: 2013-06-25 16:39:26+00:00\n"
8
+ "MIME-Version: 1.0\n"
9
+ "Content-Type: text/plain; charset=UTF-8\n"
10
+ "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2013-MO-DA HO:MI+ZONE\n"
12
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
+ "Language-Team: LANGUAGE <LL@li.org>\n"
14
+
15
+ #: includes/admin/class-wp-job-manager-admin.php:49
16
+ msgid "Settings"
17
+ msgstr ""
18
+
19
+ #: includes/admin/class-wp-job-manager-cpt.php:67
20
+ msgid "Select a category"
21
+ msgstr ""
22
+
23
+ #: includes/admin/class-wp-job-manager-cpt.php:100
24
+ msgid "Job position title"
25
+ msgstr ""
26
+
27
+ #: includes/admin/class-wp-job-manager-cpt.php:116
28
+ msgid "Job listing updated. <a href=\"%s\">View Job</a>"
29
+ msgstr ""
30
+
31
+ #: includes/admin/class-wp-job-manager-cpt.php:117
32
+ msgid "Custom field updated."
33
+ msgstr ""
34
+
35
+ #: includes/admin/class-wp-job-manager-cpt.php:118
36
+ msgid "Custom field deleted."
37
+ msgstr ""
38
+
39
+ #: includes/admin/class-wp-job-manager-cpt.php:119
40
+ msgid "Job listing updated."
41
+ msgstr ""
42
+
43
+ #: includes/admin/class-wp-job-manager-cpt.php:120
44
+ msgid "Job listing restored to revision from %s"
45
+ msgstr ""
46
+
47
+ #: includes/admin/class-wp-job-manager-cpt.php:121
48
+ msgid "Job listing published. <a href=\"%s\">View Job</a>"
49
+ msgstr ""
50
+
51
+ #: includes/admin/class-wp-job-manager-cpt.php:122
52
+ msgid "Job listing saved."
53
+ msgstr ""
54
+
55
+ #: includes/admin/class-wp-job-manager-cpt.php:123
56
+ msgid "Job listing submitted. <a target=\"_blank\" href=\"%s\">Preview Job</a>"
57
+ msgstr ""
58
+
59
+ #: includes/admin/class-wp-job-manager-cpt.php:124
60
+ msgid ""
61
+ "Job listing scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href="
62
+ "\"%2$s\">Preview Job</a>"
63
+ msgstr ""
64
+
65
+ #: includes/admin/class-wp-job-manager-cpt.php:125
66
+ msgid "M j, Y @ G:i"
67
+ msgstr ""
68
+
69
+ #: includes/admin/class-wp-job-manager-cpt.php:126
70
+ msgid ""
71
+ "Job listing draft updated. <a target=\"_blank\" href=\"%s\">Preview Job</a>"
72
+ msgstr ""
73
+
74
+ #: includes/admin/class-wp-job-manager-cpt.php:143
75
+ msgid "Type"
76
+ msgstr ""
77
+
78
+ #: includes/admin/class-wp-job-manager-cpt.php:144
79
+ msgid "Position"
80
+ msgstr ""
81
+
82
+ #: includes/admin/class-wp-job-manager-cpt.php:145
83
+ msgid "Company"
84
+ msgstr ""
85
+
86
+ #: includes/admin/class-wp-job-manager-cpt.php:146
87
+ #: templates/content-single-job_listing.php:14
88
+ msgid "Posted"
89
+ msgstr ""
90
+
91
+ #: includes/admin/class-wp-job-manager-cpt.php:147
92
+ #: templates/job-dashboard.php:9
93
+ msgid "Expires"
94
+ msgstr ""
95
+
96
+ #: includes/admin/class-wp-job-manager-cpt.php:149
97
+ msgid "Categories"
98
+ msgstr ""
99
+
100
+ #: includes/admin/class-wp-job-manager-cpt.php:150
101
+ msgid "Job Status"
102
+ msgstr ""
103
+
104
+ #: includes/admin/class-wp-job-manager-cpt.php:151
105
+ #: templates/job-dashboard.php:10
106
+ msgid "Filled?"
107
+ msgstr ""
108
+
109
+ #: includes/admin/class-wp-job-manager-cpt.php:152
110
+ msgid "Actions"
111
+ msgstr ""
112
+
113
+ #: includes/admin/class-wp-job-manager-cpt.php:199
114
+ msgid "by a guest"
115
+ msgstr ""
116
+
117
+ #: includes/admin/class-wp-job-manager-cpt.php:199
118
+ msgid "by %s"
119
+ msgstr ""
120
+
121
+ #: includes/admin/class-wp-job-manager-cpt.php:212
122
+ msgid "View"
123
+ msgstr ""
124
+
125
+ #: includes/admin/class-wp-job-manager-cpt.php:217
126
+ #: includes/class-wp-job-manager-post-types.php:149
127
+ #: templates/job-dashboard.php:29
128
+ msgid "Edit"
129
+ msgstr ""
130
+
131
+ #: includes/admin/class-wp-job-manager-cpt.php:222
132
+ #: templates/job-dashboard.php:39
133
+ msgid "Delete"
134
+ msgstr ""
135
+
136
+ #: includes/admin/class-wp-job-manager-settings.php:31
137
+ #: includes/class-wp-job-manager-post-types.php:125
138
+ msgid "Job Listings"
139
+ msgstr ""
140
+
141
+ #: includes/admin/class-wp-job-manager-settings.php:37
142
+ msgid "Jobs per page"
143
+ msgstr ""
144
+
145
+ #: includes/admin/class-wp-job-manager-settings.php:38
146
+ msgid "How many jobs should be shown per page by default?"
147
+ msgstr ""
148
+
149
+ #: includes/admin/class-wp-job-manager-settings.php:43
150
+ msgid "Filled positions"
151
+ msgstr ""
152
+
153
+ #: includes/admin/class-wp-job-manager-settings.php:44
154
+ msgid "Hide filled positions"
155
+ msgstr ""
156
+
157
+ #: includes/admin/class-wp-job-manager-settings.php:45
158
+ msgid "If enabled, filled positions will be hidden from the job list."
159
+ msgstr ""
160
+
161
+ #: includes/admin/class-wp-job-manager-settings.php:51
162
+ msgid "Job categories"
163
+ msgstr ""
164
+
165
+ #: includes/admin/class-wp-job-manager-settings.php:52
166
+ msgid "Enable job categories"
167
+ msgstr ""
168
+
169
+ #: includes/admin/class-wp-job-manager-settings.php:53
170
+ msgid ""
171
+ "Choose whether to enable job categories. Categories must be setup by an "
172
+ "admin for users to choose during job submission."
173
+ msgstr ""
174
+
175
+ #: includes/admin/class-wp-job-manager-settings.php:59
176
+ msgid "Job Submission"
177
+ msgstr ""
178
+
179
+ #: includes/admin/class-wp-job-manager-settings.php:64
180
+ msgid "Account creation"
181
+ msgstr ""
182
+
183
+ #: includes/admin/class-wp-job-manager-settings.php:65
184
+ msgid "Allow account creation"
185
+ msgstr ""
186
+
187
+ #: includes/admin/class-wp-job-manager-settings.php:66
188
+ msgid ""
189
+ "If enable, non-logged in users will be able to create an account by entering "
190
+ "their email address on the job submission form."
191
+ msgstr ""
192
+
193
+ #: includes/admin/class-wp-job-manager-settings.php:72
194
+ msgid "Account required"
195
+ msgstr ""
196
+
197
+ #: includes/admin/class-wp-job-manager-settings.php:73
198
+ msgid "Job submission requires an account"
199
+ msgstr ""
200
+
201
+ #: includes/admin/class-wp-job-manager-settings.php:74
202
+ msgid ""
203
+ "If disabled, non-logged in users will be able to submit job listings without "
204
+ "creating an account."
205
+ msgstr ""
206
+
207
+ #: includes/admin/class-wp-job-manager-settings.php:80
208
+ msgid "Approval Required"
209
+ msgstr ""
210
+
211
+ #: includes/admin/class-wp-job-manager-settings.php:81
212
+ msgid "New submissions require admin approval"
213
+ msgstr ""
214
+
215
+ #: includes/admin/class-wp-job-manager-settings.php:82
216
+ msgid "If enabled, new submissions will be inactive, pending admin approval."
217
+ msgstr ""
218
+
219
+ #: includes/admin/class-wp-job-manager-settings.php:88
220
+ msgid "Listing duration"
221
+ msgstr ""
222
+
223
+ #: includes/admin/class-wp-job-manager-settings.php:89
224
+ msgid ""
225
+ "How many <strong>days</strong> listings are live before expiring. Can be "
226
+ "left blank to never expire."
227
+ msgstr ""
228
+
229
+ #: includes/admin/class-wp-job-manager-settings.php:141
230
+ msgid "Settings successfully saved"
231
+ msgstr ""
232
+
233
+ #: includes/admin/class-wp-job-manager-settings.php:208
234
+ msgid "Save Changes"
235
+ msgstr ""
236
+
237
+ #: includes/admin/class-wp-job-manager-writepanels.php:19
238
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:88
239
+ msgid "Job location"
240
+ msgstr ""
241
+
242
+ #: includes/admin/class-wp-job-manager-writepanels.php:20
243
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:91
244
+ msgid "e.g. \"London, UK\", \"New York\", \"Anywhere\""
245
+ msgstr ""
246
+
247
+ #: includes/admin/class-wp-job-manager-writepanels.php:23
248
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:118
249
+ msgid "Application email/URL"
250
+ msgstr ""
251
+
252
+ #: includes/admin/class-wp-job-manager-writepanels.php:24
253
+ msgid "URL or email which applicants use to apply"
254
+ msgstr ""
255
+
256
+ #: includes/admin/class-wp-job-manager-writepanels.php:27
257
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:127
258
+ msgid "Company name"
259
+ msgstr ""
260
+
261
+ #: includes/admin/class-wp-job-manager-writepanels.php:31
262
+ msgid "Company website"
263
+ msgstr ""
264
+
265
+ #: includes/admin/class-wp-job-manager-writepanels.php:35
266
+ msgid "Company tagline"
267
+ msgstr ""
268
+
269
+ #: includes/admin/class-wp-job-manager-writepanels.php:36
270
+ msgid "Brief description about the company"
271
+ msgstr ""
272
+
273
+ #: includes/admin/class-wp-job-manager-writepanels.php:39
274
+ msgid "Company Twitter"
275
+ msgstr ""
276
+
277
+ #: includes/admin/class-wp-job-manager-writepanels.php:43
278
+ msgid "Company logo"
279
+ msgstr ""
280
+
281
+ #: includes/admin/class-wp-job-manager-writepanels.php:44
282
+ msgid "URL to the company logo"
283
+ msgstr ""
284
+
285
+ #: includes/admin/class-wp-job-manager-writepanels.php:47
286
+ msgid "Position filled?"
287
+ msgstr ""
288
+
289
+ #: includes/admin/class-wp-job-manager-writepanels.php:60
290
+ msgid "Job Listing Data"
291
+ msgstr ""
292
+
293
+ #: includes/class-wp-job-manager-ajax.php:104
294
+ msgid "No more jobs found matching your selection."
295
+ msgstr ""
296
+
297
+ #: includes/class-wp-job-manager-ajax.php:143
298
+ msgid "Showing %s&ldquo;%s&rdquo; %sjobs"
299
+ msgstr ""
300
+
301
+ #: includes/class-wp-job-manager-ajax.php:145
302
+ msgid "Showing all %s%sjobs"
303
+ msgstr ""
304
+
305
+ #: includes/class-wp-job-manager-ajax.php:148
306
+ msgid "located in &ldquo;%s&rdquo;"
307
+ msgstr ""
308
+
309
+ #: includes/class-wp-job-manager-post-types.php:35
310
+ msgid "Job Category"
311
+ msgstr ""
312
+
313
+ #: includes/class-wp-job-manager-post-types.php:36
314
+ msgid "Job Categories"
315
+ msgstr ""
316
+
317
+ #: includes/class-wp-job-manager-post-types.php:40
318
+ msgctxt "Job category slug - resave permalinks after changing this"
319
+ msgid "job-category"
320
+ msgstr ""
321
+
322
+ #: includes/class-wp-job-manager-post-types.php:57
323
+ #: includes/class-wp-job-manager-post-types.php:100
324
+ #: includes/class-wp-job-manager-post-types.php:154
325
+ msgid "Search %s"
326
+ msgstr ""
327
+
328
+ #: includes/class-wp-job-manager-post-types.php:58
329
+ #: includes/class-wp-job-manager-post-types.php:101
330
+ #: includes/class-wp-job-manager-post-types.php:146
331
+ msgid "All %s"
332
+ msgstr ""
333
+
334
+ #: includes/class-wp-job-manager-post-types.php:59
335
+ #: includes/class-wp-job-manager-post-types.php:102
336
+ #: includes/class-wp-job-manager-post-types.php:157
337
+ msgid "Parent %s"
338
+ msgstr ""
339
+
340
+ #: includes/class-wp-job-manager-post-types.php:60
341
+ #: includes/class-wp-job-manager-post-types.php:103
342
+ msgid "Parent %s:"
343
+ msgstr ""
344
+
345
+ #: includes/class-wp-job-manager-post-types.php:61
346
+ #: includes/class-wp-job-manager-post-types.php:104
347
+ #: includes/class-wp-job-manager-post-types.php:150
348
+ msgid "Edit %s"
349
+ msgstr ""
350
+
351
+ #: includes/class-wp-job-manager-post-types.php:62
352
+ #: includes/class-wp-job-manager-post-types.php:105
353
+ msgid "Update %s"
354
+ msgstr ""
355
+
356
+ #: includes/class-wp-job-manager-post-types.php:63
357
+ #: includes/class-wp-job-manager-post-types.php:106
358
+ msgid "Add New %s"
359
+ msgstr ""
360
+
361
+ #: includes/class-wp-job-manager-post-types.php:64
362
+ #: includes/class-wp-job-manager-post-types.php:107
363
+ msgid "New %s Name"
364
+ msgstr ""
365
+
366
+ #: includes/class-wp-job-manager-post-types.php:79
367
+ msgid "Job Type"
368
+ msgstr ""
369
+
370
+ #: includes/class-wp-job-manager-post-types.php:80
371
+ msgid "Job Types"
372
+ msgstr ""
373
+
374
+ #: includes/class-wp-job-manager-post-types.php:84
375
+ msgctxt "Job type slug - resave permalinks after changing this"
376
+ msgid "job-type"
377
+ msgstr ""
378
+
379
+ #: includes/class-wp-job-manager-post-types.php:124
380
+ msgid "Job Listing"
381
+ msgstr ""
382
+
383
+ #: includes/class-wp-job-manager-post-types.php:128
384
+ msgctxt "Post type archive slug - resave permalinks after changing this"
385
+ msgid "jobs"
386
+ msgstr ""
387
+
388
+ #: includes/class-wp-job-manager-post-types.php:134
389
+ msgctxt "Job permalink - resave permalinks after changing this"
390
+ msgid "job"
391
+ msgstr ""
392
+
393
+ #: includes/class-wp-job-manager-post-types.php:147
394
+ msgid "Add New"
395
+ msgstr ""
396
+
397
+ #: includes/class-wp-job-manager-post-types.php:148
398
+ msgid "Add %s"
399
+ msgstr ""
400
+
401
+ #: includes/class-wp-job-manager-post-types.php:151
402
+ msgid "New %s"
403
+ msgstr ""
404
+
405
+ #: includes/class-wp-job-manager-post-types.php:152
406
+ #: includes/class-wp-job-manager-post-types.php:153
407
+ msgid "View %s"
408
+ msgstr ""
409
+
410
+ #: includes/class-wp-job-manager-post-types.php:155
411
+ msgid "No %s found"
412
+ msgstr ""
413
+
414
+ #: includes/class-wp-job-manager-post-types.php:156
415
+ msgid "No %s found in trash"
416
+ msgstr ""
417
+
418
+ #: includes/class-wp-job-manager-post-types.php:159
419
+ msgid "This is where you can create and manage job listings."
420
+ msgstr ""
421
+
422
+ #: includes/class-wp-job-manager-post-types.php:194
423
+ msgctxt "job_listing"
424
+ msgid "Expired"
425
+ msgstr ""
426
+
427
+ #: includes/class-wp-job-manager-post-types.php:199
428
+ msgid "Expired <span class=\"count\">(%s)</span>"
429
+ msgid_plural "Expired <span class=\"count\">(%s)</span>"
430
+ msgstr[0] ""
431
+ msgstr[1] ""
432
+
433
+ #: includes/class-wp-job-manager-shortcodes.php:61
434
+ msgid "Invalid Job ID"
435
+ msgstr ""
436
+
437
+ #: includes/class-wp-job-manager-shortcodes.php:67
438
+ msgid "This job is already filled"
439
+ msgstr ""
440
+
441
+ #: includes/class-wp-job-manager-shortcodes.php:73
442
+ msgid "%s has been filled"
443
+ msgstr ""
444
+
445
+ #: includes/class-wp-job-manager-shortcodes.php:78
446
+ msgid "This job is already not filled"
447
+ msgstr ""
448
+
449
+ #: includes/class-wp-job-manager-shortcodes.php:84
450
+ msgid "%s has been marked as not filled"
451
+ msgstr ""
452
+
453
+ #: includes/class-wp-job-manager-shortcodes.php:91
454
+ msgid "%s has been deleted"
455
+ msgstr ""
456
+
457
+ #: includes/class-wp-job-manager-shortcodes.php:111
458
+ msgid "You need to be signed in to manage your job listings."
459
+ msgstr ""
460
+
461
+ #: includes/class-wp-job-manager-shortcodes.php:175
462
+ msgid "Load more job listings"
463
+ msgstr ""
464
+
465
+ #: includes/class-wp-job-manager-widgets.php:139
466
+ msgid "Display a list of the most recent jobs on your site."
467
+ msgstr ""
468
+
469
+ #: includes/class-wp-job-manager-widgets.php:141
470
+ msgid "Recent Job Listings"
471
+ msgstr ""
472
+
473
+ #: includes/class-wp-job-manager-widgets.php:145
474
+ msgid "Recent Jobs"
475
+ msgstr ""
476
+
477
+ #: includes/class-wp-job-manager-widgets.php:146
478
+ msgid "Title"
479
+ msgstr ""
480
+
481
+ #: includes/class-wp-job-manager-widgets.php:154
482
+ msgid "Number of jobs to show"
483
+ msgstr ""
484
+
485
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:39
486
+ msgid "Invalid job"
487
+ msgstr ""
488
+
489
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:78
490
+ msgid "Update job listing"
491
+ msgstr ""
492
+
493
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:103
494
+ msgid "Your changes have been saved."
495
+ msgstr ""
496
+
497
+ #: includes/forms/class-wp-job-manager-form-edit-job.php:103
498
+ msgid "View Job Listing &rarr;"
499
+ msgstr ""
500
+
501
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:26
502
+ msgid "Submit Details"
503
+ msgstr ""
504
+
505
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:32
506
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:441
507
+ msgid "Preview"
508
+ msgstr ""
509
+
510
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:38
511
+ msgid "Done"
512
+ msgstr ""
513
+
514
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:81
515
+ msgid "Job title"
516
+ msgstr ""
517
+
518
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:95
519
+ msgid "Job type"
520
+ msgstr ""
521
+
522
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:103
523
+ msgid "Job category"
524
+ msgstr ""
525
+
526
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:111
527
+ msgid "Description"
528
+ msgstr ""
529
+
530
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:121
531
+ msgid "Enter an email address or website URL"
532
+ msgstr ""
533
+
534
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:130
535
+ msgid "Enter the name of the company"
536
+ msgstr ""
537
+
538
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:134
539
+ #: templates/content-single-job_listing.php:25
540
+ msgid "Website"
541
+ msgstr ""
542
+
543
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:137
544
+ msgid "http://"
545
+ msgstr ""
546
+
547
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:141
548
+ msgid "Tagline"
549
+ msgstr ""
550
+
551
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:144
552
+ msgid "Briefly describe your company"
553
+ msgstr ""
554
+
555
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:148
556
+ msgid "Twitter username"
557
+ msgstr ""
558
+
559
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:151
560
+ msgid "@yourcompany"
561
+ msgstr ""
562
+
563
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:155
564
+ msgid "Logo"
565
+ msgstr ""
566
+
567
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:213
568
+ msgid "%s is a required field"
569
+ msgstr ""
570
+
571
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:320
572
+ msgid "Preview job listing &rarr;"
573
+ msgstr ""
574
+
575
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:352
576
+ msgid "You must be signed in to post a new job listing."
577
+ msgstr ""
578
+
579
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:436
580
+ msgid "Submit Listing &rarr;"
581
+ msgstr ""
582
+
583
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:437
584
+ msgid "&larr; Edit listing"
585
+ msgstr ""
586
+
587
+ #: includes/forms/class-wp-job-manager-form-submit-job.php:505
588
+ msgid "Logo needs to be jpg, gif or png."
589
+ msgstr ""
590
+
591
+ #: templates/account-signin.php:4
592
+ msgid "Your account"
593
+ msgstr ""
594
+
595
+ #: templates/account-signin.php:8
596
+ msgid "You are currently signed in as <strong>%s</strong>."
597
+ msgstr ""
598
+
599
+ #: templates/account-signin.php:11
600
+ msgid "Sign out"
601
+ msgstr ""
602
+
603
+ #: templates/account-signin.php:21
604
+ msgid "Have an account?"
605
+ msgstr ""
606
+
607
+ #: templates/account-signin.php:23
608
+ msgid "Sign in"
609
+ msgstr ""
610
+
611
+ #: templates/account-signin.php:27
612
+ msgid ""
613
+ "If you don&lsquo;t have an account you can %screate one below by entering "
614
+ "your email address. A password will be automatically emailed to you."
615
+ msgstr ""
616
+
617
+ #: templates/account-signin.php:27
618
+ msgid "optionally"
619
+ msgstr ""
620
+
621
+ #: templates/account-signin.php:31
622
+ msgid "You must sign in to create a new job listing."
623
+ msgstr ""
624
+
625
+ #: templates/account-signin.php:38
626
+ msgid "Your email"
627
+ msgstr ""
628
+
629
+ #: templates/account-signin.php:38 templates/job-submit.php:21
630
+ #: templates/job-submit.php:32
631
+ msgid "(optional)"
632
+ msgstr ""
633
+
634
+ #: templates/content-job_listing.php:16
635
+ #: templates/content-single-job_listing.php:14
636
+ #: templates/content-summary-job_listing.php:14
637
+ msgid "ago"
638
+ msgstr ""
639
+
640
+ #: templates/content-single-job_listing.php:5
641
+ msgid "This job listing has expired"
642
+ msgstr ""
643
+
644
+ #: templates/content-single-job_listing.php:17
645
+ msgid "This position has been filled"
646
+ msgstr ""
647
+
648
+ #: templates/form-fields/file-field.php:3
649
+ msgid "or"
650
+ msgstr ""
651
+
652
+ #: templates/form-fields/file-field.php:10
653
+ msgid "Max. file size: %s. Allowed images: jpg, gif, png."
654
+ msgstr ""
655
+
656
+ #: templates/job-application.php:5
657
+ msgid "Apply for job"
658
+ msgstr ""
659
+
660
+ #: templates/job-application.php:12
661
+ msgid ""
662
+ "To apply for this job <strong>email your details to</strong> <a class="
663
+ "\"job_application_email\" href=\"mailto:%1$s%2$s\">%1$s</a>"
664
+ msgstr ""
665
+
666
+ #: templates/job-application.php:14
667
+ msgid "Apply using webmail: "
668
+ msgstr ""
669
+
670
+ #: templates/job-application.php:28
671
+ msgid ""
672
+ "To apply for this job please visit the following URL: <a href=\"%1$s\">%1$s "
673
+ "&rarr;</a>"
674
+ msgstr ""
675
+
676
+ #: templates/job-dashboard.php:2
677
+ msgid ""
678
+ "Your job listings are shown in the table below. Expired listings will be "
679
+ "automatically removed after 30 days."
680
+ msgstr ""
681
+
682
+ #: templates/job-dashboard.php:6
683
+ msgid "Job Title"
684
+ msgstr ""
685
+
686
+ #: templates/job-dashboard.php:7
687
+ msgid "Date Posted"
688
+ msgstr ""
689
+
690
+ #: templates/job-dashboard.php:8
691
+ msgid "Status"
692
+ msgstr ""
693
+
694
+ #: templates/job-dashboard.php:16
695
+ msgid "You do not have any active job listings."
696
+ msgstr ""
697
+
698
+ #: templates/job-dashboard.php:32
699
+ msgid "Mark not filled"
700
+ msgstr ""
701
+
702
+ #: templates/job-dashboard.php:34
703
+ msgid "Mark filled"
704
+ msgstr ""
705
+
706
+ #: templates/job-filters.php:6
707
+ msgid "Keywords"
708
+ msgstr ""
709
+
710
+ #: templates/job-filters.php:7
711
+ msgid "All Jobs"
712
+ msgstr ""
713
+
714
+ #: templates/job-filters.php:10
715
+ msgid "Location"
716
+ msgstr ""
717
+
718
+ #: templates/job-filters.php:11
719
+ msgid "Any Location"
720
+ msgstr ""
721
+
722
+ #: templates/job-filters.php:15
723
+ msgid "Category"
724
+ msgstr ""
725
+
726
+ #: templates/job-filters.php:17
727
+ msgid "All Job Categories"
728
+ msgstr ""
729
+
730
+ #: templates/job-filters.php:39
731
+ msgid "Reset"
732
+ msgstr ""
733
+
734
+ #: templates/job-filters.php:40
735
+ msgid "RSS"
736
+ msgstr ""
737
+
738
+ #: templates/job-submit.php:28
739
+ msgid "Company details"
740
+ msgstr ""
741
+
742
+ #: templates/job-submitted.php:3
743
+ msgid ""
744
+ "Job listed successfully. To view your job listing <a href=\"%s\">click here</"
745
+ "a>."
746
+ msgstr ""
747
+
748
+ #: templates/job-submitted.php:7
749
+ msgid ""
750
+ "Job submitted successfully. Your job listing will be visible once approved."
751
+ msgstr ""
752
+
753
+ #: wp-job-manager-functions.php:101
754
+ msgid "Your email address isn&#8217;t correct."
755
+ msgstr ""
756
+
757
+ #: wp-job-manager-functions.php:104
758
+ msgid "This email is already registered, please choose another one."
759
+ msgstr ""
760
+
761
+ #: wp-job-manager-template.php:146
762
+ msgid "Active"
763
+ msgstr ""
764
+
765
+ #: wp-job-manager-template.php:148
766
+ msgid "Expired"
767
+ msgstr ""
768
+
769
+ #: wp-job-manager-template.php:150
770
+ msgid "Pending Review"
771
+ msgstr ""
772
+
773
+ #: wp-job-manager-template.php:152
774
+ msgid "Inactive"
775
+ msgstr ""
776
+
777
+ #: wp-job-manager.php:89
778
+ msgid "Are you sure you want to delete this job?"
779
+ msgstr ""
780
+
781
+ #. Plugin Name of the plugin/theme
782
+ msgid "WP Job Manager"
783
+ msgstr ""
784
+
785
+ #. #-#-#-#-# job_manager.pot (WP Job Manager 1.0 Beta 1) #-#-#-#-#
786
+ #. Plugin URI of the plugin/theme
787
+ #. #-#-#-#-# job_manager.pot (WP Job Manager 1.0 Beta 1) #-#-#-#-#
788
+ #. Author URI of the plugin/theme
789
+ msgid "http://mikejolley.com"
790
+ msgstr ""
791
+
792
+ #. Description of the plugin/theme
793
+ msgid ""
794
+ "Manage job listings from the WordPress admin panel, and allow users to post "
795
+ "jobs directly to your site."
796
+ msgstr ""
797
+
798
+ #. Author of the plugin/theme
799
+ msgid "Mike Jolley"
800
+ msgstr ""
readme.txt ADDED
@@ -0,0 +1,76 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === WP Job Manager ===
2
+ Contributors: mikejolley
3
+ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&business=mike.jolley@me.com&currency_code=&amount=&return=&item_name=Buy+me+a+coffee+for+A+New+Job+Board+Plugin+for+WordPress
4
+ Tags: job listing, job board, job, jobs, company
5
+ Requires at least: 3.5
6
+ Tested up to: 3.5
7
+ Stable tag: 1.0.0
8
+
9
+ Manage job listings from the WordPress admin panel, and allow users to post jobs directly to your site.
10
+
11
+ == Description ==
12
+
13
+ WP Job Manager is a _lightweight_ plugin for adding job-board functionality to your WordPress site. Being shortcode based, it can work with any theme (given a bit of CSS styling) and is really simple to setup.
14
+
15
+ = Features =
16
+
17
+ * Add, manage and categorise job listings using the familiar WordPress UI.
18
+ * Searchable & filterable ajax powered job listings added through shortcodes.
19
+ * Frontend forms for guests and registered users to submit & manage job listings.
20
+ * Allow job listers to preview their listing before it goes live. The preview matches the appearance of a live job listing.
21
+ * Each listing can be tied to an email or website address so that job seekers can apply to the jobs.
22
+ * Searches also display RSS links to allow job seekers to be alerted to new jobs matching their search.
23
+ * Allow logged in employers to view, edit, mark filled, or delete their active job listings.
24
+ * Developer friendly code — Custom Post Types, endpoints & template files.
25
+
26
+ The plugin comes with several shortcodes to output jobs in various formats, and since its built with Custom Post Types you are free to extend it further through themes.
27
+
28
+ [Read more about WP Job Manager](http://mikejolley.com/projects/wp-job-manager/).
29
+
30
+ = Documentation =
31
+
32
+ Documentation will be maintained on the [GitHub Wiki here](https://github.com/mikejolley/wp-job-manager/wiki).
33
+
34
+ = Add-ons =
35
+
36
+ Add-ons, such as __simple paid listings__ can be [found here](http://mikejolley.com/projects/wp-job-manager/add-ons/). Take a look!
37
+
38
+ = Contributing and reporting bugs =
39
+
40
+ You can contribute code and localizations to this plugin via GitHub: [https://github.com/mikejolley/wp-job-manager](https://github.com/mikejolley/wp-job-manager)
41
+
42
+ = Support =
43
+
44
+ Use the WordPress.org forums for community support - I cannot offer support directly for free. If you spot a bug, you can of course log it on [Github](https://github.com/mikejolley/wp-job-manager) instead where I can act upon it more efficiently.
45
+
46
+ If you want help with a customisation, hire a developer!
47
+
48
+ == Installation ==
49
+
50
+ = Automatic installation =
51
+
52
+ Automatic installation is the easiest option as WordPress handles the file transfers itself and you don't even need to leave your web browser. To do an automatic install, log in to your WordPress admin panel, navigate to the Plugins menu and click Add New.
53
+
54
+ In the search field type "WP Job Manager" and click Search Plugins. Once you've found the plugin you can view details about it such as the the point release, rating and description. Most importantly of course, you can install it by clicking _Install Now_.
55
+
56
+ = Manual installation =
57
+
58
+ The manual installation method involves downloading the plugin and uploading it to your webserver via your favourite FTP application.
59
+
60
+ * Download the plugin file to your computer and unzip it
61
+ * Using an FTP program, or your hosting control panel, upload the unzipped plugin folder to your WordPress installation's `wp-content/plugins/` directory.
62
+ * Activate the plugin from the Plugins menu within the WordPress admin.
63
+
64
+ == Screenshots ==
65
+
66
+ 1. The submit job form.
67
+ 2. Submit job preview.
68
+ 3. A single job listing.
69
+ 4. Job dashboard.
70
+ 5. Job listings and filters.
71
+ 6. Job listings in admin.
72
+
73
+ == Changelog ==
74
+
75
+ = 1.0.0 =
76
+ * First stable release.
templates/account-signin.php ADDED
@@ -0,0 +1,45 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php if ( is_user_logged_in() ) : ?>
2
+
3
+ <fieldset>
4
+ <label><?php _e( 'Your account', 'job_manager' ); ?></label>
5
+ <div class="field account-sign-in">
6
+ <?php
7
+ $user = wp_get_current_user();
8
+ printf( __( 'You are currently signed in as <strong>%s</strong>.', 'job_manager' ), $user->user_login );
9
+ ?>
10
+
11
+ <a class="button" href="<?php echo apply_filters( 'submit_job_form_logout_url', wp_logout_url( get_permalink() ) ); ?>"><?php _e( 'Sign out', 'job_manager' ); ?></a>
12
+ </div>
13
+ </fieldset>
14
+
15
+ <?php else :
16
+
17
+ $account_required = job_manager_user_requires_account();
18
+ $registration_enabled = job_manager_enable_registration();
19
+ ?>
20
+ <fieldset>
21
+ <label><?php _e( 'Have an account?', 'job_manager' ); ?></label>
22
+ <div class="field account-sign-in">
23
+ <a class="button" href="<?php echo apply_filters( 'submit_job_form_login_url', wp_login_url( get_permalink() ) ); ?>"><?php _e( 'Sign in', 'job_manager' ); ?></a>
24
+
25
+ <?php if ( $registration_enabled ) : ?>
26
+
27
+ <?php printf( __( 'If you don&lsquo;t have an account you can %screate one below by entering your email address. A password will be automatically emailed to you.', 'job_manager' ), $account_required ? '' : __( 'optionally', 'job_manager' ) . ' ' ); ?>
28
+
29
+ <?php elseif ( $account_required ) : ?>
30
+
31
+ <?php echo apply_filters( 'submit_job_form_login_required_message', __('You must sign in to create a new job listing.', 'job_manager' ) ); ?>
32
+
33
+ <?php endif; ?>
34
+ </div>
35
+ </fieldset>
36
+ <?php if ( $registration_enabled ) : ?>
37
+ <fieldset>
38
+ <label><?php _e( 'Your email', 'job_manager' ); ?> <?php if ( ! $account_required ) echo '<small>' . __( '(optional)', 'job_manager' ) . '</small>'; ?></label>
39
+ <div class="field">
40
+ <input type="email" class="input-text" name="create_account_email" id="account_email" placeholder="you@yourdomain.com" value="<?php if ( ! empty( $_POST['create_account_email'] ) ) echo sanitize_text_field( stripslashes( $_POST['create_account_email'] ) ); ?>" />
41
+ </div>
42
+ </fieldset>
43
+ <?php endif; ?>
44
+
45
+ <?php endif; ?>
templates/content-job_listing.php ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <li <?php job_listing_class(); ?>>
2
+ <a href="<?php the_job_permalink(); ?>">
3
+ <?php the_company_logo(); ?>
4
+ <div class="position">
5
+ <h3><?php the_title(); ?></h3>
6
+ <div class="company">
7
+ <?php the_company_name( '<strong>', '</strong> ' ); ?>
8
+ <?php the_company_tagline( '<span class="tagline">', '</span>' ); ?>
9
+ </div>
10
+ </div>
11
+ <div class="location">
12
+ <?php the_job_location( false ); ?>
13
+ </div>
14
+ <ul class="meta">
15
+ <li class="job-type <?php echo get_the_job_type() ? sanitize_title( get_the_job_type()->slug ) : ''; ?>"><?php the_job_type(); ?></li>
16
+ <li class="date"><date><?php echo human_time_diff( get_the_time( 'U' ), current_time( 'timestamp' ) ) . ' ' . __( 'ago', 'job_manager' ); ?></date></li>
17
+ </ul>
18
+ </a>
19
+ </li>
templates/content-single-job_listing.php ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php global $job_manager; ?>
2
+ <div class="single_job_listing">
3
+ <?php if ( $post->post_status == 'expired' ) : ?>
4
+
5
+ <div class="job-manager-info"><?php _e( 'This job listing has expired', 'job_manager' ); ?></div>
6
+
7
+ <?php else : ?>
8
+
9
+ <ul class="meta">
10
+ <li class="job-type <?php echo get_the_job_type() ? sanitize_title( get_the_job_type()->slug ) : ''; ?>"><?php the_job_type(); ?></li>
11
+
12
+ <li class="location"><?php the_job_location(); ?></li>
13
+
14
+ <li class="date-posted"><?php _e( 'Posted', 'job_manager' ); ?> <date><?php echo human_time_diff( get_the_time( 'U' ), current_time( 'timestamp' ) ) . ' ' . __( 'ago', 'job_manager' ); ?></date></li>
15
+
16
+ <?php if ( is_position_filled() ) : ?>
17
+ <li class="position-filled"><?php _e( 'This position has been filled', 'job_manager' ); ?></li>
18
+ <?php endif; ?>
19
+ </ul>
20
+
21
+ <div class="company" itemscope itemtype="http://data-vocabulary.org/Organization">
22
+ <?php the_company_logo(); ?>
23
+
24
+ <p class="name">
25
+ <a class="website" href="<?php echo get_the_company_website(); ?>" itemprop="url"><?php _e( 'Website', 'job_manager' ); ?></a>
26
+ <?php the_company_twitter(); ?>
27
+ <?php the_company_name( '<strong itemprop="name">', '</strong>' ); ?>
28
+ </p>
29
+ <?php the_company_tagline( '<p class="tagline">', '</p>' ); ?>
30
+ </div>
31
+
32
+ <?php echo apply_filters( 'the_job_description', get_the_content() ); ?>
33
+
34
+ <?php if ( ! is_position_filled() && $post->post_status !== 'preview' ) get_job_manager_template( 'job-application.php' ); ?>
35
+
36
+ <?php endif; ?>
37
+ </div>
templates/content-summary-job_listing.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php global $job_manager; ?>
2
+
3
+ <a href="<?php the_permalink(); ?>">
4
+ <div class="job-type <?php echo get_the_job_type() ? sanitize_title( get_the_job_type()->slug ) : ''; ?>"><?php the_job_type(); ?></div>
5
+
6
+ <?php if ( $logo = get_the_company_logo() ) : ?>
7
+ <img src="<?php echo $logo; ?>" alt="<?php the_company_name(); ?>" title="<?php the_company_name(); ?> - <?php the_company_tagline(); ?>" />
8
+ <?php endif; ?>
9
+
10
+ <div class="job_summary_content">
11
+
12
+ <h1><?php the_title(); ?></h1>
13
+
14
+ <p class="meta"><?php the_job_location( false ); ?> &mdash; <date><?php echo human_time_diff( get_the_time( 'U' ), current_time( 'timestamp' ) ) . ' ' . __( 'ago', 'job_manager' ); ?></date></p>
15
+
16
+ </div>
17
+ </a>
templates/content-widget-job_listing.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <li <?php job_listing_class(); ?>>
2
+ <a href="<?php the_job_permalink(); ?>">
3
+ <div class="position">
4
+ <h3><?php the_title(); ?></h3>
5
+ </div>
6
+ <ul class="meta">
7
+ <li class="location"><?php the_job_location( false ); ?></li>
8
+ <li class="company"><?php the_company_name(); ?></span>
9
+ <li class="job-type <?php echo get_the_job_type() ? sanitize_title( get_the_job_type()->slug ) : ''; ?>"><?php the_job_type(); ?></li>
10
+ </ul>
11
+ </a>
12
+ </li>
templates/form-fields/file-field.php ADDED
@@ -0,0 +1,11 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php if ( ! empty( $field['value'] ) ) : ?>
2
+ <div class="uploaded_image">
3
+ <img src="<?php echo $field['value']; ?>" /> <?php echo '<code>' . basename( $field['value'] ) . '</code> ' . __( 'or', 'job_manager' ) . '&hellip;'; ?>
4
+ <input type="hidden" class="input-text" name="<?php echo esc_attr( $key ); ?>" value="<?php echo isset( $field['value'] ) ? esc_attr( $field['value'] ) : ''; ?>" />
5
+ </div>
6
+ <?php endif; ?>
7
+
8
+ <input type="file" class="input-text" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" placeholder="<?php echo esc_attr( $field['placeholder'] ); ?>" />
9
+ <small class="description">
10
+ <?php printf( __( 'Max. file size: %s. Allowed images: jpg, gif, png.', 'job_manager' ), size_format( wp_max_upload_size() ) ); ?>
11
+ </small>
templates/form-fields/job-description-field.php ADDED
@@ -0,0 +1,14 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ $editor = array(
3
+ 'media_buttons' => false,
4
+ 'textarea_rows' => 8,
5
+ 'quicktags' => false,
6
+ 'tinymce' => array(
7
+ 'plugins' => '',
8
+ 'theme_advanced_buttons1' => 'bold,italic,|,bullist,numlist,|,undo,redo,|,|,code',
9
+ 'theme_advanced_buttons2' => '',
10
+ 'theme_advanced_buttons3' => '',
11
+ 'theme_advanced_buttons4' => ''
12
+ ),
13
+ );
14
+ wp_editor( isset( $field['value'] ) ? esc_textarea( $field['value'] ) : '', $key, $editor );
templates/form-fields/select-field.php ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
1
+ <select name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>">
2
+ <?php foreach ( $field['options'] as $key => $value ) : ?>
3
+ <option value="<?php echo esc_attr( $key ); ?>" <?php if ( isset( $field['value'] ) ) selected( $field['value'], $key ); ?>><?php echo esc_html( $value ); ?></option>
4
+ <?php endforeach; ?>
5
+ </select>
templates/form-fields/text-field.php ADDED
@@ -0,0 +1,2 @@
 
 
1
+ <input type="text" class="input-text" name="<?php echo esc_attr( $key ); ?>" id="<?php echo esc_attr( $key ); ?>" placeholder="<?php echo esc_attr( $field['placeholder'] ); ?>" value="<?php echo isset( $field['value'] ) ? esc_attr( $field['value'] ) : ''; ?>" maxlength="<?php echo ! empty( $field['maxlength'] ) ? $field['maxlength'] : ''; ?>" />
2
+ <?php if ( ! empty( $field['description'] ) ) : ?><small class="description"><?php echo $field['description']; ?></small><?php endif; ?>
templates/job-application.php ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php if ( $apply = get_the_job_application_method() ) :
2
+ wp_enqueue_script( 'wp-job-manager-job-application' );
3
+ ?>
4
+ <div class="application">
5
+ <input class="application_button" type="button" value="<?php _e( 'Apply for job', 'job_manager' ); ?>" />
6
+
7
+ <div class="application_details">
8
+ <?php
9
+ switch ( $apply->type ) {
10
+ case 'email' :
11
+
12
+ echo '<p>' . sprintf( __( 'To apply for this job <strong>email your details to</strong> <a class="job_application_email" href="mailto:%1$s%2$s">%1$s</a>', 'job_manager' ), $apply->email, '?subject=' . rawurlencode( $apply->subject ) ) . '</p>';
13
+
14
+ echo '<p>' . __( 'Apply using webmail: ', 'job_manager' );
15
+
16
+ echo '<a href="' . 'https://mail.google.com/mail/?view=cm&fs=1&to=' . $apply->email . '&su=' . urlencode( $apply->subject ) .'" target="_blank" class="job_application_email">Gmail</a> / ';
17
+
18
+ echo '<a href="' . 'http://webmail.aol.com/Mail/ComposeMessage.aspx?to=' . $apply->email . '&subject=' . urlencode( $apply->subject ) .'" target="_blank" class="job_application_email">AOL</a> / ';
19
+
20
+ echo '<a href="' . 'http://compose.mail.yahoo.com/?to=' . $apply->email . '&subject=' . urlencode( $apply->subject ) .'" target="_blank" class="job_application_email">Yahoo</a> / ';
21
+
22
+ echo '<a href="' . 'http://mail.live.com/mail/EditMessageLight.aspx?n=&to=' . $apply->email . '&subject=' . urlencode( $apply->subject ) .'" target="_blank" class="job_application_email">Outlook</a>';
23
+
24
+ echo '</p>';
25
+
26
+ break;
27
+ case 'url' :
28
+ echo '<p>' . sprintf( __( 'To apply for this job please visit the following URL: <a href="%1$s">%1$s &rarr;</a>', 'job_manager' ), $apply->url ) . '</p>';
29
+ break;
30
+ }
31
+ ?>
32
+ </div>
33
+ </div>
34
+ <?php endif; ?>
templates/job-dashboard.php ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <div id="job-manager-job-dashboard">
2
+ <p><?php _e( 'Your job listings are shown in the table below. Expired listings will be automatically removed after 30 days.', 'job_manager' ); ?></p>
3
+ <table class="job-manager-jobs">
4
+ <thead>
5
+ <tr>
6
+ <th class="job_title"><?php _e( 'Job Title', 'job_manager' ); ?></th>
7
+ <th class="date"><?php _e( 'Date Posted', 'job_manager' ); ?></th>
8
+ <th class="status"><?php _e( 'Status', 'job_manager' ); ?></th>
9
+ <th class="expires"><?php _e( 'Expires', 'job_manager' ); ?></th>
10
+ <th class="filled"><?php _e( 'Filled?', 'job_manager' ); ?></th>
11
+ </tr>
12
+ </thead>
13
+ <tbody>
14
+ <?php if ( ! $jobs ) : ?>
15
+ <tr>
16
+ <td colspan="6"><?php _e( 'You do not have any active job listings.', 'job_manager' ); ?></td>
17
+ </tr>
18
+ <?php else : ?>
19
+ <?php foreach ( $jobs as $job ) : ?>
20
+ <tr>
21
+ <td class="job_title">
22
+ <a href="<?php echo get_permalink( $job->ID ); ?>"><?php echo $job->post_title; ?></a>
23
+ <ul class="job-dashboard-actions">
24
+ <?php
25
+ $actions = array();
26
+
27
+ switch ( $job->post_status ) {
28
+ case 'publish' :
29
+ $actions['edit'] = array( 'label' => __( 'Edit', 'job_manager' ), 'nonce' => false );
30
+
31
+ if ( is_position_filled( $job ) )
32
+ $actions['mark_not_filled'] = array( 'label' => __( 'Mark not filled', 'job_manager' ), 'nonce' => true );
33
+ else
34
+ $actions['mark_filled'] = array( 'label' => __( 'Mark filled', 'job_manager' ), 'nonce' => true );
35
+
36
+ break;
37
+ }
38
+
39
+ $actions['delete'] = array( 'label' => __( 'Delete', 'job_manager' ), 'nonce' => true );
40
+ $actions = apply_filters( 'job_manager_my_job_actions', $actions, $job );
41
+
42
+ foreach ( $actions as $action => $value ) {
43
+ $action_url = add_query_arg( array( 'action' => $action, 'job_id' => $job->ID ) );
44
+ if ( $value['nonce'] )
45
+ $action_url = wp_nonce_url( $action_url, 'job_manager_my_job_actions' );
46
+ echo '<li><a href="' . $action_url . '" class="job-dashboard-action-' . $action . '">' . $value['label'] . '</a></li>';
47
+ }
48
+ ?>
49
+ </ul>
50
+ </td>
51
+ <td class="date"><?php echo date_i18n( get_option( 'date_format' ), strtotime( $job->post_date ) ); ?></td>
52
+ <td class="status"><?php the_job_status( $job ); ?></td>
53
+ <td class="expires"><?php
54
+ $expires = $job->_job_expires;
55
+
56
+ echo $expires ? date_i18n( get_option( 'date_format' ), strtotime( $expires ) ) : '&ndash;';
57
+ ?></td>
58
+ <td class="filled"><?php if ( is_position_filled( $job ) ) echo '&#10004;'; else echo '&ndash;'; ?></td>
59
+ </tr>
60
+ <?php endforeach; ?>
61
+ <?php endif; ?>
62
+ </tbody>
63
+ </table>
64
+ </div>
templates/job-filters.php ADDED
@@ -0,0 +1,49 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php wp_enqueue_script( 'wp-job-manager-ajax-filters' ); ?>
2
+ <form class="job_filters">
3
+
4
+ <div class="search_jobs">
5
+ <div class="search_keywords">
6
+ <label for="search_keywords"><?php _e( 'Keywords', 'job_manager' ); ?></label>
7
+ <input type="text" name="search_keywords" id="search_keywords" placeholder="<?php _e( 'All Jobs', 'job_manager' ); ?>" />
8
+ </div>
9
+
10
+ <div class="search_location">
11
+ <label for="search_location"><?php _e( 'Location', 'job_manager' ); ?></label>
12
+ <input type="text" name="search_location" id="search_location" placeholder="<?php _e( 'Any Location', 'job_manager' ); ?>" />
13
+ </div>
14
+
15
+ <?php if ( $categories ) : ?>
16
+ <?php foreach ( $categories as $category ) : ?>
17
+ <input type="hidden" name="search_categories[]" value="<?php echo sanitize_title( $category ); ?>" />
18
+ <?php endforeach; ?>
19
+ <?php elseif ( $show_categories && get_option( 'job_manager_enable_categories' ) && ! is_tax( 'job_listing_category' ) ) : ?>
20
+ <div class="search_categories">
21
+ <label for="search_categories"><?php _e( 'Category', 'job_manager' ); ?></label>
22
+ <select name="search_categories" id="search_categories">
23
+ <option value=""><?php _e( 'All Job Categories', 'job_manager' ); ?></option>
24
+ <?php foreach ( get_job_listing_categories() as $category ) : ?>
25
+ <option value="<?php echo $category->slug; ?>"><?php echo $category->name; ?></option>
26
+ <?php endforeach; ?>
27
+ </select>
28
+ </div>
29
+ <?php endif; ?>
30
+
31
+ <input type="hidden" name="per_page" value="<?php echo esc_attr( $per_page ) ; ?>" />
32
+ <input type="hidden" name="orderby" value="<?php echo esc_attr( $orderby ) ; ?>" />
33
+ <input type="hidden" name="order" value="<?php echo esc_attr( $order ) ; ?>" />
34
+ </div>
35
+
36
+ <?php if ( ! is_tax( 'job_listing_type' ) ) : ?>
37
+ <ul class="job_types">
38
+ <?php foreach ( get_job_listing_types() as $type ) : ?>
39
+ <li><label for="job_type_<?php echo $type->slug; ?>" class="<?php echo sanitize_title( $type->name ); ?>"><input type="checkbox" name="filter_job_type[]" value="<?php echo $type->slug; ?>" <?php checked( 1, 1 ); ?> id="job_type_<?php echo $type->slug; ?>" /> <?php echo $type->name; ?></label></li>
40
+ <?php endforeach; ?>
41
+ </ul>
42
+ <?php endif; ?>
43
+
44
+ <div class="showing_jobs">
45
+ <a href="#" class="reset"><?php _e( 'Reset', 'job_manager' ); ?></a>
46
+ <a href="#" class="rss_link"><?php _e( 'RSS', 'job_manager' ); ?></a>
47
+ <span></span>
48
+ </div>
49
+ </form>
templates/job-submit.php ADDED
@@ -0,0 +1,61 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Job Submission Form
4
+ */
5
+ if ( ! defined( 'ABSPATH' ) ) exit;
6
+
7
+ global $job_manager;
8
+ ?>
9
+ <form action="<?php echo $action; ?>" method="post" id="submit-job-form" class="job-manager-form" enctype="multipart/form-data">
10
+
11
+ <?php if ( apply_filters( 'submit_job_form_show_signin', true ) ) : ?>
12
+
13
+ <?php get_job_manager_template( 'account-signin.php' ); ?>
14
+
15
+ <?php endif; ?>
16
+
17
+ <?php if ( job_manager_user_can_post_job() ) : ?>
18
+
19
+ <!-- Job Information Fields -->
20
+ <?php do_action( 'submit_job_form_job_fields_start' ); ?>
21
+
22
+ <?php foreach ( $job_fields as $key => $field ) : ?>
23
+ <fieldset class="fieldset-<?php esc_attr_e( $key ); ?>">
24
+ <label for="<?php esc_attr_e( $key ); ?>"><?php echo $field['label'] . ( $field['required'] ? '' : ' <small>' . __( '(optional)', 'job_manager' ) . '</small>' ); ?></label>
25
+ <div class="field">
26
+ <?php get_job_manager_template( 'form-fields/' . $field['type'] . '-field.php', array( 'key' => $key, 'field' => $field ) ); ?>
27
+ </div>
28
+ </fieldset>
29
+ <?php endforeach; ?>
30
+
31
+ <?php do_action( 'submit_job_form_job_fields_end' ); ?>
32
+
33
+ <!-- Company Information Fields -->
34
+ <h2><?php _e( 'Company details', 'job_manager' ); ?></h2>
35
+
36
+ <?php do_action( 'submit_job_form_company_fields_start' ); ?>
37
+
38
+ <?php foreach ( $company_fields as $key => $field ) : ?>
39
+ <fieldset class="fieldset-<?php esc_attr_e( $key ); ?>">
40
+ <label for="<?php esc_attr_e( $key ); ?>"><?php echo $field['label'] . ( $field['required'] ? '' : ' <small>' . __( '(optional)', 'job_manager' ) . '</small>' ); ?></label>
41
+ <div class="field">
42
+ <?php get_job_manager_template( 'form-fields/' . $field['type'] . '-field.php', array( 'key' => $key, 'field' => $field ) ); ?>
43
+ </div>
44
+ </fieldset>
45
+ <?php endforeach; ?>
46
+
47
+ <?php do_action( 'submit_job_form_company_fields_end' ); ?>
48
+
49
+ <p>
50
+ <?php wp_nonce_field( 'submit_form_posted' ); ?>
51
+ <input type="hidden" name="job_manager_form" value="<?php echo $form; ?>" />
52
+ <input type="hidden" name="job_id" value="<?php echo esc_attr( $job_id ); ?>" />
53
+ <input type="submit" name="submit_job" class="button" value="<?php esc_attr_e( $submit_button_text ); ?>" />
54
+ </p>
55
+
56
+ <?php else : ?>
57
+
58
+ <?php do_action( 'submit_job_form_disabled' ); ?>
59
+
60
+ <?php endif; ?>
61
+ </form>
templates/job-submitted.php ADDED
@@ -0,0 +1,12 @@
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ switch ( $job->post_status ) :
3
+ case 'publish' :
4
+ printf( __( 'Job listed successfully. To view your job listing <a href="%s">click here</a>.', 'job_manager' ), get_permalink( $job->ID ) );
5
+ break;
6
+ case 'pending' :
7
+ printf( __( 'Job submitted successfully. Your job listing will be visible once approved.', 'job_manager' ), get_permalink( $job->ID ) );
8
+ break;
9
+ default :
10
+ do_action( 'job_manager_job_submitted_content_' . str_replace( '-', '_', sanitize_title( $job->post_status ) ), $job );
11
+ break;
12
+ endswitch;
uninstall.php ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ <?php
2
+
3
+ wp_clear_scheduled_hook( 'job_manager_check_for_expired_jobs' );
wp-job-manager-functions.php ADDED
@@ -0,0 +1,148 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ if ( ! function_exists( 'get_job_listing_types' ) ) :
3
+ /**
4
+ * Outputs a form to submit a new job to the site from the frontend.
5
+ *
6
+ * @access public
7
+ * @return void
8
+ */
9
+ function get_job_listing_types() {
10
+ return get_terms( "job_listing_type", array(
11
+ 'orderby' => 'name',
12
+ 'order' => 'ASC',
13
+ 'hide_empty' => false,
14
+ ) );
15
+ }
16
+ endif;
17
+
18
+ if ( ! function_exists( 'get_job_listing_categories' ) ) :
19
+ /**
20
+ * Outputs a form to submit a new job to the site from the frontend.
21
+ *
22
+ * @access public
23
+ * @return array
24
+ */
25
+ function get_job_listing_categories() {
26
+ if ( ! get_option( 'job_manager_enable_categories' ) )
27
+ return array();
28
+
29
+ return get_terms( "job_listing_category", array(
30
+ 'orderby' => 'name',
31
+ 'order' => 'ASC',
32
+ 'hide_empty' => false,
33
+ ) );
34
+ }
35
+ endif;
36
+
37
+ if ( ! function_exists( 'job_manager_encode_email' ) ) :
38
+ /**
39
+ * Munge an email address
40
+ *
41
+ * @param string $email
42
+ * @return string
43
+ */
44
+ function wp_job_manager_encode_email( $email ) {
45
+ $encmail = "";
46
+ for ( $i = 0; $i < strlen( $email ); $i++ ) {
47
+ $char = substr( $email, $i, 1 );
48
+
49
+ if ( $char == '@' ) {
50
+ $encmail .= ' [at] ';
51
+ } elseif ( $char == '.' ) {
52
+ $encmail .= ' [dot] ';
53
+ } else {
54
+ $encMod = rand( 0, 2 );
55
+ switch ( $encMod ) {
56
+ case 0: // None
57
+ $encmail .= $char;
58
+ break;
59
+ case 1: // Decimal
60
+ $encmail .= "&#" . ord( $char ) . ';';
61
+ break;
62
+ case 2: // Hexadecimal
63
+ $encmail .= "&#x" . dechex( ord( $char ) ) . ';';
64
+ break;
65
+ }
66
+ }
67
+ }
68
+ return $encmail;
69
+ }
70
+ endif;
71
+
72
+ if ( ! function_exists( 'get_job_listing_rss_link' ) ) :
73
+ /**
74
+ * Get the Job Listing RSS link
75
+ *
76
+ * @return string
77
+ */
78
+ function get_job_listing_rss_link( $args = array() ) {
79
+ $rss_link = add_query_arg( array_merge( array( 'feed' => 'job_feed' ), $args ), home_url() );
80
+
81
+ return $rss_link;
82
+ }
83
+ endif;
84
+
85
+ if ( ! function_exists( 'job_manager_create_account' ) ) :
86
+ /**
87
+ * Handle account creation.
88
+ *
89
+ * @param [type] $account_email
90
+ * @return WP_error | bool was an account created?
91
+ */
92
+ function wp_job_manager_create_account( $account_email ) {
93
+ global $current_user;
94
+
95
+ $user_email = apply_filters( 'user_registration_email', sanitize_email( $account_email ) );
96
+
97
+ if ( empty( $user_email ) )
98
+ return false;
99
+
100
+ if ( ! is_email( $user_email ) )
101
+ return new WP_Error( 'validation-error', __( 'Your email address isn&#8217;t correct.', 'job_manager' ) );
102
+
103
+ if ( email_exists( $user_email ) )
104
+ return new WP_Error( 'validation-error', __( 'This email is already registered, please choose another one.', 'job_manager' ) );
105
+
106
+ // Email is good to go - use it to create a user name
107
+ $username = sanitize_user( current( explode( '@', $user_email ) ) );
108
+ $password = wp_generate_password();
109
+
110
+ // Ensure username is unique
111
+ $append = 1;
112
+ $o_username = $username;
113
+
114
+ while( username_exists( $username ) ) {
115
+ $username = $o_username . $append;
116
+ $append ++;
117
+ }
118
+
119
+ // Final error check
120
+ $reg_errors = new WP_Error();
121
+ do_action( 'register_post', $username, $user_email, $reg_errors );
122
+ $reg_errors = apply_filters( 'registration_errors', $reg_errors, $username, $user_email );
123
+
124
+ if ( $reg_errors->get_error_code() )
125
+ return $reg_errors;
126
+
127
+ // Create account
128
+ $new_user = array(
129
+ 'user_login' => $username,
130
+ 'user_pass' => $password,
131
+ 'user_email' => $user_email
132
+ );
133
+
134
+ $user_id = wp_insert_user( apply_filters( 'job_manager_create_account_data', $new_user ) );
135
+
136
+ if ( is_wp_error( $user_id ) )
137
+ return $user_id;
138
+
139
+ // Notify
140
+ wp_new_user_notification( $user_id, $password );
141
+
142
+ // Login
143
+ wp_set_auth_cookie( $user_id, true, is_ssl() );
144
+ $current_user = get_user_by( 'id', $user_id );
145
+
146
+ return true;
147
+ }
148
+ endif;
wp-job-manager-template.php ADDED
@@ -0,0 +1,495 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Template Functions
4
+ *
5
+ * Template functions specifically created for job listings
6
+ *
7
+ * @author Mike Jolley
8
+ * @category Core
9
+ * @package Job Manager/Template
10
+ * @version 1.0.0
11
+ */
12
+
13
+ /**
14
+ * Get and include template files.
15
+ *
16
+ * @param mixed $template_name
17
+ * @param array $args (default: array())
18
+ * @param string $template_path (default: '')
19
+ * @param string $default_path (default: '')
20
+ * @return void
21
+ */
22
+ function get_job_manager_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {
23
+ if ( $args && is_array($args) )
24
+ extract( $args );
25
+
26
+ include( locate_job_manager_template( $template_name, $template_path, $default_path ) );
27
+ }
28
+
29
+ /**
30
+ * Locate a template and return the path for inclusion.
31
+ *
32
+ * This is the load order:
33
+ *
34
+ * yourtheme / $template_path / $template_name
35
+ * yourtheme / $template_name
36
+ * $default_path / $template_name
37
+ *
38
+ * @param mixed $template_name
39
+ * @param string $template_path (default: '')
40
+ * @param string $default_path (default: '')
41
+ * @return string
42
+ */
43
+ function locate_job_manager_template( $template_name, $template_path = '', $default_path = '' ) {
44
+ if ( ! $template_path )
45
+ $template_path = 'job_manager';
46
+ if ( ! $default_path )
47
+ $default_path = JOB_MANAGER_PLUGIN_DIR . '/templates/';
48
+
49
+ // Look within passed path within the theme - this is priority
50
+ $template = locate_template(
51
+ array(
52
+ trailingslashit( $template_path ) . $template_name,
53
+ $template_name
54
+ )
55
+ );
56
+
57
+ // Get default template
58
+ if ( ! $template )
59
+ $template = $default_path . $template_name;
60
+
61
+ // Return what we found
62
+ return apply_filters( 'job_manager_locate_template', $template, $template_name, $template_path );
63
+ }
64
+
65
+ /**
66
+ * Get template part (for templates in loops).
67
+ *
68
+ * @param mixed $slug
69
+ * @param string $name (default: '')
70
+ * @return void
71
+ */
72
+ function get_job_manager_template_part( $slug, $name = '' ) {
73
+ $template = '';
74
+
75
+ // Look in yourtheme/slug-name.php and yourtheme/job_manager/slug-name.php
76
+ if ( $name )
77
+ $template = locate_template( array ( "{$slug}-{$name}.php", "job_manager/{$slug}-{$name}.php" ) );
78
+
79
+ // Get default slug-name.php
80
+ if ( ! $template && $name && file_exists( JOB_MANAGER_PLUGIN_DIR . "/templates/{$slug}-{$name}.php" ) )
81
+ $template = JOB_MANAGER_PLUGIN_DIR . "/templates/{$slug}-{$name}.php";
82
+
83
+ // If template file doesn't exist, look in yourtheme/slug.php and yourtheme/job_manager/slug.php
84
+ if ( ! $template )
85
+ $template = locate_template( array ( "{$slug}.php", "job_manager/{$slug}.php" ) );
86
+
87
+ if ( $template )
88
+ load_template( $template, false );
89
+ }
90
+
91
+ /**
92
+ * True if an the user can post a job. If accounts are required, and reg is enabled, users can post (they signup at the same time).
93
+ *
94
+ * @return bool
95
+ */
96
+ function job_manager_user_can_post_job() {
97
+ $can_post = true;
98
+
99
+ if ( ! is_user_logged_in() ) {
100
+ if ( job_manager_user_requires_account() && ! job_manager_enable_registration() ) {
101
+ $can_post = false;
102
+ }
103
+ }
104
+
105
+ return apply_filters( 'job_manager_user_can_post_job', $can_post );
106
+ }
107
+
108
+ /**
109
+ * True if registration is enabled.
110
+ *
111
+ * @return bool
112
+ */
113
+ function job_manager_enable_registration() {
114
+ return apply_filters( 'job_manager_enable_registration', get_option( 'job_manager_enable_registration' ) == 1 ? true : false );
115
+ }
116
+
117
+ /**
118
+ * True if an account is required to post a job.
119
+ *
120
+ * @return bool
121
+ */
122
+ function job_manager_user_requires_account() {
123
+ return apply_filters( 'job_manager_user_requires_account', get_option( 'job_manager_user_requires_account' ) == 1 ? true : false );
124
+ }
125
+
126
+ /**
127
+ * Outputs the jobs status
128
+ *
129
+ * @return void
130
+ */
131
+ function the_job_status( $post = null ) {
132
+ echo get_the_job_status( $post );
133
+ }
134
+
135
+ /**
136
+ * Gets the jobs status
137
+ *
138
+ * @return string
139
+ */
140
+ function get_the_job_status( $post = null ) {
141
+ $post = get_post( $post );
142
+
143
+ $status = $post->post_status;
144
+
145
+ if ( $status == 'publish' )
146
+ $status = __( 'Active', 'job_manager' );
147
+ elseif ( $status == 'expired' )
148
+ $status = __( 'Expired', 'job_manager' );
149
+ elseif ( $status == 'pending' )
150
+ $status = __( 'Pending Review', 'job_manager' );
151
+ else
152
+ $status = __( 'Inactive', 'job_manager' );
153
+
154
+ return apply_filters( 'the_job_status', $status, $post );
155
+ }
156
+
157
+ /**
158
+ * Return whether or not the position has been marked as filled
159
+ *
160
+ * @param object $post
161
+ * @return boolean
162
+ */
163
+ function is_position_filled( $post = null ) {
164
+ $post = get_post( $post );
165
+
166
+ return $post->_filled ? true : false;
167
+ }
168
+
169
+ /**
170
+ * the_job_permalink function.
171
+ *
172
+ * @access public
173
+ * @return void
174
+ */
175
+ function the_job_permalink( $post = null ) {
176
+ echo get_the_job_permalink( $post );
177
+ }
178
+
179
+ /**
180
+ * get_the_job_permalink function.
181
+ *
182
+ * @access public
183
+ * @param mixed $post (default: null)
184
+ * @return string
185
+ */
186
+ function get_the_job_permalink( $post = null ) {
187
+ $post = get_post( $post );
188
+ $link = get_permalink( $post );
189
+
190
+ return apply_filters( 'the_job_permalink', $link, $post );
191
+ }
192
+
193
+ /**
194
+ * get_the_job_application_method function.
195
+ *
196
+ * @access public
197
+ * @param mixed $post (default: null)
198
+ * @return object
199
+ */
200
+ function get_the_job_application_method( $post = null ) {
201
+ $post = get_post( $post );
202
+ if ( $post->post_type !== 'job_listing' )
203
+ return;
204
+
205
+ $method = new stdClass();
206
+ $apply = $post->_application;
207
+
208
+ if ( strstr( $apply, '@' ) && is_email( $apply ) ) {
209
+ $method->type = 'email';
210
+ $method->raw_email = $apply;
211
+ $method->email = wp_job_manager_encode_email( $apply );
212
+ $method->subject = 'Job Application via "' . $post->post_title . '" listing on ' . home_url();
213
+ } else {
214
+ if ( strpos( $apply, 'http' ) !== 0 )
215
+ $apply = 'http://' . $apply;
216
+ $method->type = 'url';
217
+ $method->url = $apply;
218
+ }
219
+
220
+ return apply_filters( 'the_job_application_method', $method, $post );
221
+ }
222
+ /**
223
+ * the_job_type function.
224
+ *
225
+ * @access public
226
+ * @return void
227
+ */
228
+ function the_job_type( $post = null ) {
229
+ if ( $job_type = get_the_job_type( $post ) )
230
+ echo $job_type->name;
231
+ }
232
+
233
+ /**
234
+ * get_the_job_type function.
235
+ *
236
+ * @access public
237
+ * @param mixed $post (default: null)
238
+ * @return void
239
+ */
240
+ function get_the_job_type( $post = null ) {
241
+ $post = get_post( $post );
242
+ if ( $post->post_type !== 'job_listing' )
243
+ return;
244
+
245
+ $types = wp_get_post_terms( $post->ID, 'job_listing_type' );
246
+
247
+ if ( $types )
248
+ $type = current( $types );
249
+ else
250
+ $type = false;
251
+
252
+ return apply_filters( 'the_job_type', $type, $post );
253
+ }
254
+
255
+
256
+ /**
257
+ * the_job_location function.
258
+ * @param boolean $map_link whether or not to link to the map on google maps
259
+ * @return [type]
260
+ */
261
+ function the_job_location( $map_link = true, $post = null ) {
262
+ $location = get_the_job_location( $post );
263
+
264
+ if ( $location ) {
265
+ if ( $map_link )
266
+ echo '<a class="google_map_link" href="http://maps.google.com/maps?q=' . urlencode( $location ) . '&zoom=14&size=512x512&maptype=roadmap&sensor=false">' . $location . '</a>';
267
+ else
268
+ echo $location;
269
+ } else {
270
+ echo apply_filters( 'the_job_location_anywhere_text', __( 'Anywhere', 'job_manager' ) );
271
+ }
272
+ }
273
+
274
+ /**
275
+ * get_the_job_location function.
276
+ *
277
+ * @access public
278
+ * @param mixed $post (default: null)
279
+ * @return void
280
+ */
281
+ function get_the_job_location( $post = null ) {
282
+ $post = get_post( $post );
283
+ if ( $post->post_type !== 'job_listing' )
284
+ return;
285
+
286
+ return apply_filters( 'the_job_location', $post->_job_location, $post );
287
+ }
288
+
289
+ /**
290
+ * the_company_logo function.
291
+ *
292
+ * @access public
293
+ * @param string $size (default: 'thumbnail')
294
+ * @param mixed $default (default: null)
295
+ * @return void
296
+ */
297
+ function the_company_logo( $size = 'thumbnail', $default = null, $post = null ) {
298
+ global $job_manager;
299
+
300
+ $logo = get_the_company_logo( $post );
301
+ if ( $logo )
302
+ echo '<img src="' . $logo . '" alt="Logo" />';
303
+ elseif ( $default )
304
+ echo '<img src="' . $default . '" alt="Logo" />';
305
+ else
306
+ echo '<img src="' . JOB_MANAGER_PLUGIN_URL . '/assets/images/company.png' . '" alt="Logo" />';
307
+ }
308
+
309
+ /**
310
+ * get_the_company_logo function.
311
+ *
312
+ * @access public
313
+ * @param mixed $post (default: null)
314
+ * @return string
315
+ */
316
+ function get_the_company_logo( $post = null ) {
317
+ $post = get_post( $post );
318
+ if ( $post->post_type !== 'job_listing' )
319
+ return;
320
+
321
+ return apply_filters( 'the_company_logo', $post->_company_logo, $post );
322
+ }
323
+
324
+ /**
325
+ * Display or retrieve the current company name with optional content.
326
+ *
327
+ * @access public
328
+ * @param mixed $id (default: null)
329
+ * @return void
330
+ */
331
+ function the_company_name( $before = '', $after = '', $echo = true, $post = null ) {
332
+ $company_name = get_the_company_name( $post );
333
+
334
+ if ( strlen( $company_name ) == 0 )
335
+ return;
336
+
337
+ $company_name = esc_attr( strip_tags( $company_name ) );
338
+ $company_name = $before . $company_name . $after;
339
+
340
+ if ( $echo )
341
+ echo $company_name;
342
+ else
343
+ return $company_name;
344
+ }
345
+
346
+ /**
347
+ * get_the_company_name function.
348
+ *
349
+ * @access public
350
+ * @param int $post (default: null)
351
+ * @return void
352
+ */
353
+ function get_the_company_name( $post = null ) {
354
+ $post = get_post( $post );
355
+ if ( $post->post_type !== 'job_listing' )
356
+ return;
357
+
358
+ return apply_filters( 'the_company_name', $post->_company_name, $post );
359
+ }
360
+
361
+ /**
362
+ * get_the_company_website function.
363
+ *
364
+ * @access public
365
+ * @param int $post (default: null)
366
+ * @return void
367
+ */
368
+ function get_the_company_website( $post = null ) {
369
+ $post = get_post( $post );
370
+ if ( $post->post_type !== 'job_listing' )
371
+ return;
372
+
373
+ return apply_filters( 'the_company_website', $post->_company_website, $post );
374
+ }
375
+
376
+ /**
377
+ * Display or retrieve the current company tagline with optional content.
378
+ *
379
+ * @access public
380
+ * @param mixed $id (default: null)
381
+ * @return void
382
+ */
383
+ function the_company_tagline( $before = '', $after = '', $echo = true, $post = null ) {
384
+ $company_tagline = get_the_company_tagline( $post );
385
+
386
+ if ( strlen( $company_tagline ) == 0 )
387
+ return;
388
+
389
+ $company_tagline = esc_attr( strip_tags( $company_tagline ) );
390
+ $company_tagline = $before . $company_tagline . $after;
391
+
392
+ if ( $echo )
393
+ echo $company_tagline;
394
+ else
395
+ return $company_tagline;
396
+ }
397
+
398
+ /**
399
+ * get_the_company_tagline function.
400
+ *
401
+ * @access public
402
+ * @param int $post (default: 0)
403
+ * @return void
404
+ */
405
+ function get_the_company_tagline( $post = null ) {
406
+ $post = get_post( $post );
407
+
408
+ if ( $post->post_type !== 'job_listing' )
409
+ return;
410
+
411
+ return apply_filters( 'the_company_tagline', $post->_company_tagline, $post );
412
+ }
413
+
414
+ /**
415
+ * Display or retrieve the current company twitter link with optional content.
416
+ *
417
+ * @access public
418
+ * @param mixed $id (default: null)
419
+ * @return void
420
+ */
421
+ function the_company_twitter( $before = '', $after = '', $echo = true, $post = null ) {
422
+ $company_twitter = get_the_company_twitter( $post );
423
+
424
+ if ( strlen( $company_twitter ) == 0 )
425
+ return;
426
+
427
+ $company_twitter = esc_attr( strip_tags( $company_twitter ) );
428
+ $company_twitter = $before . '<a href="http://twitter.com/' . $company_twitter . '" class="company_twitter">' . $company_twitter . '</a>' . $after;
429
+
430
+ if ( $echo )
431
+ echo $company_twitter;
432
+ else
433
+ return $company_twitter;
434
+ }
435
+
436
+ /**
437
+ * get_the_company_twitter function.
438
+ *
439
+ * @access public
440
+ * @param int $post (default: 0)
441
+ * @return void
442
+ */
443
+ function get_the_company_twitter( $post = null ) {
444
+ $post = get_post( $post );
445
+ if ( $post->post_type !== 'job_listing' )
446
+ return;
447
+
448
+ $company_twitter = $post->_company_twitter;
449
+
450
+ if ( strlen( $company_twitter ) == 0 )
451
+ return;
452
+
453
+ if ( strpos( $company_twitter, '@' ) === 0 )
454
+ $company_twitter = substr( $company_twitter, 1 );
455
+
456
+ return apply_filters( 'the_company_twitter', $company_twitter, $post );
457
+ }
458
+
459
+ /**
460
+ * job_listing_class function.
461
+ *
462
+ * @access public
463
+ * @param string $class (default: '')
464
+ * @param mixed $post_id (default: null)
465
+ * @return void
466
+ */
467
+ function job_listing_class( $class = '', $post_id = null ) {
468
+ // Separates classes with a single space, collates classes for post DIV
469
+ echo 'class="' . join( ' ', get_job_listing_class( $class, $post_id ) ) . '"';
470
+ }
471
+
472
+ /**
473
+ * get_job_listing_class function.
474
+ *
475
+ * @access public
476
+ * @return array
477
+ */
478
+ function get_job_listing_class( $class = '', $post_id = null ) {
479
+ $post = get_post( $post_id );
480
+ if ( $post->post_type !== 'job_listing' )
481
+ return array();
482
+
483
+ $classes = array();
484
+
485
+ if ( empty( $post ) )
486
+ return $classes;
487
+
488
+ $classes[] = 'job_listing';
489
+ $classes[] = 'job-type-' . sanitize_title( get_the_job_type()->name );
490
+
491
+ if ( is_position_filled( $post ) )
492
+ $classes[] = 'job_position_filled';
493
+
494
+ return get_post_class( $classes, $post->ID );
495
+ }
wp-job-manager.php ADDED
@@ -0,0 +1,96 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /*
3
+ Plugin Name: WP Job Manager
4
+ Plugin URI: http://mikejolley.com/projects/wp-job-manager/
5
+ Description: Manage job listings from the WordPress admin panel, and allow users to post jobs directly to your site.
6
+ Version: 1.0.0
7
+ Author: Mike Jolley
8
+ Author URI: http://mikejolley.com
9
+ Requires at least: 3.5
10
+ Tested up to: 3.5
11
+
12
+ Copyright: 2013 Mike Jolley
13
+ License: GNU General Public License v3.0
14
+ License URI: http://www.gnu.org/licenses/gpl-3.0.html
15
+ */
16
+
17
+ // Exit if accessed directly
18
+ if ( ! defined( 'ABSPATH' ) )
19
+ exit;
20
+
21
+ /**
22
+ * WP_Job_Manager class.
23
+ */
24
+ class WP_Job_Manager {
25
+
26
+ /**
27
+ * __construct function.
28
+ */
29
+ public function __construct() {
30
+ // Define constants
31
+ define( 'JOB_MANAGER_VERSION', '1.0.0' );
32
+ define( 'JOB_MANAGER_PLUGIN_DIR', untrailingslashit( plugin_dir_path( __FILE__ ) ) );
33
+ define( 'JOB_MANAGER_PLUGIN_URL', untrailingslashit( plugins_url( basename( plugin_dir_path( __FILE__ ) ), basename( __FILE__ ) ) ) );
34
+
35
+ // Includes
36
+ include( 'wp-job-manager-functions.php' );
37
+ include( 'wp-job-manager-template.php' );
38
+ include( 'includes/class-wp-job-manager-post-types.php' );
39
+ include( 'includes/class-wp-job-manager-ajax.php' );
40
+ include( 'includes/class-wp-job-manager-shortcodes.php' );
41
+ include( 'includes/class-wp-job-manager-api.php' );
42
+ include( 'includes/class-wp-job-manager-forms.php' );
43
+
44
+ if ( is_admin() )
45
+ include( 'includes/admin/class-wp-job-manager-admin.php' );
46
+
47
+ // Init classes
48
+ $this->forms = new WP_Job_Manager_Forms();
49
+ $this->post_types = new WP_Job_Manager_Post_Types();
50
+
51
+ // Activation - works with symlinks
52
+ register_activation_hook( basename( dirname( __FILE__ ) ) . '/' . basename( __FILE__ ), array( $this->post_types, 'register_post_types' ), 10 );
53
+ register_activation_hook( basename( dirname( __FILE__ ) ) . '/' . basename( __FILE__ ), create_function( "", "include( 'includes/class-wp-job-manager-install.php' );" ), 10 );
54
+ register_activation_hook( basename( dirname( __FILE__ ) ) . '/' . basename( __FILE__ ), 'flush_rewrite_rules', 15 );
55
+
56
+ // Actions
57
+ add_action( 'plugins_loaded', array( $this, 'load_plugin_textdomain' ) );
58
+ add_action( 'switch_theme', array( $this->post_types, 'register_post_types' ), 10 );
59
+ add_action( 'switch_theme', 'flush_rewrite_rules', 15 );
60
+ add_action( 'widgets_init', create_function( "", "include_once( 'includes/class-wp-job-manager-widgets.php' );" ) );
61
+ add_action( 'wp_enqueue_scripts', array( $this, 'frontend_scripts' ) );
62
+ }
63
+
64
+ /**
65
+ * Localisation
66
+ *
67
+ * @access private
68
+ * @return void
69
+ */
70
+ public function load_plugin_textdomain() {
71
+ load_plugin_textdomain( 'job_manager', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
72
+ }
73
+
74
+ /**
75
+ * frontend_scripts function.
76
+ *
77
+ * @access public
78
+ * @return void
79
+ */
80
+ public function frontend_scripts() {
81
+ wp_register_script( 'wp-job-manager-ajax-filters', JOB_MANAGER_PLUGIN_URL . '/assets/js/ajax-filters.min.js', array( 'jquery' ), JOB_MANAGER_VERSION, true );
82
+ wp_register_script( 'wp-job-manager-job-dashboard', JOB_MANAGER_PLUGIN_URL . '/assets/js/job-dashboard.min.js', array( 'jquery' ), JOB_MANAGER_VERSION, true );
83
+ wp_register_script( 'wp-job-manager-job-application', JOB_MANAGER_PLUGIN_URL . '/assets/js/job-application.min.js', array( 'jquery' ), JOB_MANAGER_VERSION, true );
84
+
85
+ wp_localize_script( 'wp-job-manager-ajax-filters', 'job_manager_ajax_filters', array(
86
+ 'ajax_url' => admin_url('admin-ajax.php')
87
+ ) );
88
+ wp_localize_script( 'wp-job-manager-job-dashboard', 'job_manager_job_dashboard', array(
89
+ 'i18n_confirm_delete' => __( 'Are you sure you want to delete this job?', 'job_manager' )
90
+ ) );
91
+
92
+ wp_enqueue_style( 'wp-job-manager-frontend', JOB_MANAGER_PLUGIN_URL . '/assets/css/frontend.css' );
93
+ }
94
+ }
95
+
96
+ $GLOBALS['job_manager'] = new WP_Job_Manager();