Revive Old Posts – Auto Post to Social Media - Version 7.3.8

Version Description

Download this release

Release Info

Developer codeinwp
Plugin Icon 128x128 Revive Old Posts – Auto Post to Social Media
Version 7.3.8
Comparing to
See all releases

Code changes from version 7.3.7 to 7.3.8

css/chosen.min.css ADDED
@@ -0,0 +1,3 @@
 
 
 
1
+ /* Chosen v1.5.1 | (c) 2011-2016 by Harvest | MIT License, https://github.com/harvesthq/chosen/blob/master/LICENSE.md */
2
+
3
+ .chosen-container{position:relative;display:inline-block;vertical-align:middle;font-size:13px;-webkit-user-select:none;-moz-user-select:none;user-select:none}.chosen-container *{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.chosen-container .chosen-drop{position:absolute;top:100%;left:-9999px;z-index:1010;width:100%;border:1px solid #aaa;border-top:0;background:#fff;box-shadow:0 4px 5px rgba(0,0,0,.15)}.chosen-container.chosen-with-drop .chosen-drop{left:0}.chosen-container a{cursor:pointer}.chosen-container .search-choice .group-name,.chosen-container .chosen-single .group-name{margin-right:4px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-weight:400;color:#999}.chosen-container .search-choice .group-name:after,.chosen-container .chosen-single .group-name:after{content:":";padding-left:2px;vertical-align:top}.chosen-container-single .chosen-single{position:relative;display:block;overflow:hidden;padding:0 0 0 8px;height:25px;border:1px solid #aaa;border-radius:5px;background-color:#fff;background:-webkit-gradient(linear,50% 0,50% 100%,color-stop(20%,#fff),color-stop(50%,#f6f6f6),color-stop(52%,#eee),color-stop(100%,#f4f4f4));background:-webkit-linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background:-moz-linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background:-o-linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background:linear-gradient(#fff 20%,#f6f6f6 50%,#eee 52%,#f4f4f4 100%);background-clip:padding-box;box-shadow:0 0 3px #fff inset,0 1px 1px rgba(0,0,0,.1);color:#444;text-decoration:none;white-space:nowrap;line-height:24px}.chosen-container-single .chosen-default{color:#999}.chosen-container-single .chosen-single span{display:block;overflow:hidden;margin-right:26px;text-overflow:ellipsis;white-space:nowrap}.chosen-container-single .chosen-single-with-deselect span{margin-right:38px}.chosen-container-single .chosen-single abbr{position:absolute;top:6px;right:26px;display:block;width:12px;height:12px;background:url(../img/chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-single .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single.chosen-disabled .chosen-single abbr:hover{background-position:-42px -10px}.chosen-container-single .chosen-single div{position:absolute;top:0;right:0;display:block;width:18px;height:100%}.chosen-container-single .chosen-single div b{display:block;width:100%;height:100%;background:url(../img/chosen-sprite.png) no-repeat 0 2px}.chosen-container-single .chosen-search{position:relative;z-index:1010;margin:0;padding:3px 4px;white-space:nowrap}.chosen-container-single .chosen-search input[type=text]{margin:1px 0;padding:4px 20px 4px 5px;width:100%;height:auto;outline:0;border:1px solid #aaa;background:#fff url(../img/chosen-sprite.png) no-repeat 100% -20px;background:url(../img/chosen-sprite.png) no-repeat 100% -20px;font-size:1em;font-family:sans-serif;line-height:normal;border-radius:0}.chosen-container-single .chosen-drop{margin-top:-1px;border-radius:0 0 4px 4px;background-clip:padding-box}.chosen-container-single.chosen-container-single-nosearch .chosen-search{position:absolute;left:-9999px}.chosen-container .chosen-results{color:#444;position:relative;overflow-x:hidden;overflow-y:auto;margin:0 4px 4px 0;padding:0 0 0 4px;max-height:240px;-webkit-overflow-scrolling:touch}.chosen-container .chosen-results li{display:none;margin:0;padding:5px 6px;list-style:none;line-height:15px;word-wrap:break-word;-webkit-touch-callout:none}.chosen-container .chosen-results li.active-result{display:list-item;cursor:pointer}.chosen-container .chosen-results li.disabled-result{display:list-item;color:#ccc;cursor:default}.chosen-container .chosen-results li.highlighted{background-color:#3875d7;background-image:-webkit-gradient(linear,50% 0,50% 100%,color-stop(20%,#3875d7),color-stop(90%,#2a62bc));background-image:-webkit-linear-gradient(#3875d7 20%,#2a62bc 90%);background-image:-moz-linear-gradient(#3875d7 20%,#2a62bc 90%);background-image:-o-linear-gradient(#3875d7 20%,#2a62bc 90%);background-image:linear-gradient(#3875d7 20%,#2a62bc 90%);color:#fff}.chosen-container .chosen-results li.no-results{color:#777;display:list-item;background:#f4f4f4}.chosen-container .chosen-results li.group-result{display:list-item;font-weight:700;cursor:default}.chosen-container .chosen-results li.group-option{padding-left:15px}.chosen-container .chosen-results li em{font-style:normal;text-decoration:underline}.chosen-container-multi .chosen-choices{position:relative;overflow:hidden;margin:0;padding:0 5px;width:100%;height:auto!important;height:1%;border:1px solid #aaa;background-color:#fff;background-image:-webkit-gradient(linear,50% 0,50% 100%,color-stop(1%,#eee),color-stop(15%,#fff));background-image:-webkit-linear-gradient(#eee 1%,#fff 15%);background-image:-moz-linear-gradient(#eee 1%,#fff 15%);background-image:-o-linear-gradient(#eee 1%,#fff 15%);background-image:linear-gradient(#eee 1%,#fff 15%);cursor:text}.chosen-container-multi .chosen-choices li{float:left;list-style:none}.chosen-container-multi .chosen-choices li.search-field{margin:0;padding:0;white-space:nowrap}.chosen-container-multi .chosen-choices li.search-field input[type=text]{margin:1px 0;padding:0;height:25px;outline:0;border:0!important;background:transparent!important;box-shadow:none;color:#999;font-size:100%;font-family:sans-serif;line-height:normal;border-radius:0}.chosen-container-multi .chosen-choices li.search-choice{position:relative;margin:3px 5px 3px 0;padding:3px 20px 3px 5px;border:1px solid #aaa;max-width:100%;border-radius:3px;background-color:#eee;background-image:-webkit-gradient(linear,50% 0,50% 100%,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),color-stop(100%,#eee));background-image:-webkit-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:-moz-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:-o-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-size:100% 19px;background-repeat:repeat-x;background-clip:padding-box;box-shadow:0 0 2px #fff inset,0 1px 0 rgba(0,0,0,.05);color:#333;line-height:13px;cursor:default}.chosen-container-multi .chosen-choices li.search-choice span{word-wrap:break-word}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close{position:absolute;top:4px;right:3px;display:block;width:12px;height:12px;background:url(../img/chosen-sprite.png) -42px 1px no-repeat;font-size:1px}.chosen-container-multi .chosen-choices li.search-choice .search-choice-close:hover{background-position:-42px -10px}.chosen-container-multi .chosen-choices li.search-choice-disabled{padding-right:5px;border:1px solid #ccc;background-color:#e4e4e4;background-image:-webkit-gradient(linear,50% 0,50% 100%,color-stop(20%,#f4f4f4),color-stop(50%,#f0f0f0),color-stop(52%,#e8e8e8),color-stop(100%,#eee));background-image:-webkit-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:-moz-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:-o-linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);background-image:linear-gradient(#f4f4f4 20%,#f0f0f0 50%,#e8e8e8 52%,#eee 100%);color:#666}.chosen-container-multi .chosen-choices li.search-choice-focus{background:#d4d4d4}.chosen-container-multi .chosen-choices li.search-choice-focus .search-choice-close{background-position:-42px -10px}.chosen-container-multi .chosen-results{margin:0;padding:0}.chosen-container-multi .chosen-drop .result-selected{display:list-item;color:#ccc;cursor:default}.chosen-container-active .chosen-single{border:1px solid #5897fb;box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active.chosen-with-drop .chosen-single{border:1px solid #aaa;-moz-border-radius-bottomright:0;border-bottom-right-radius:0;-moz-border-radius-bottomleft:0;border-bottom-left-radius:0;background-image:-webkit-gradient(linear,50% 0,50% 100%,color-stop(20%,#eee),color-stop(80%,#fff));background-image:-webkit-linear-gradient(#eee 20%,#fff 80%);background-image:-moz-linear-gradient(#eee 20%,#fff 80%);background-image:-o-linear-gradient(#eee 20%,#fff 80%);background-image:linear-gradient(#eee 20%,#fff 80%);box-shadow:0 1px 0 #fff inset}.chosen-container-active.chosen-with-drop .chosen-single div{border-left:0;background:transparent}.chosen-container-active.chosen-with-drop .chosen-single div b{background-position:-18px 2px}.chosen-container-active .chosen-choices{border:1px solid #5897fb;box-shadow:0 0 5px rgba(0,0,0,.3)}.chosen-container-active .chosen-choices li.search-field input[type=text]{color:#222!important}.chosen-disabled{opacity:.5!important;cursor:default}.chosen-disabled .chosen-single{cursor:default}.chosen-disabled .chosen-choices .search-choice .search-choice-close{cursor:default}.chosen-rtl{text-align:right}.chosen-rtl .chosen-single{overflow:visible;padding:0 8px 0 0}.chosen-rtl .chosen-single span{margin-right:0;margin-left:26px;direction:rtl}.chosen-rtl .chosen-single-with-deselect span{margin-left:38px}.chosen-rtl .chosen-single div{right:auto;left:3px}.chosen-rtl .chosen-single abbr{right:auto;left:26px}.chosen-rtl .chosen-choices li{float:right}.chosen-rtl .chosen-choices li.search-field input[type=text]{direction:rtl}.chosen-rtl .chosen-choices li.search-choice{margin:3px 5px 3px 0;padding:3px 5px 3px 19px}.chosen-rtl .chosen-choices li.search-choice .search-choice-close{right:auto;left:4px}.chosen-rtl.chosen-container-single-nosearch .chosen-search,.chosen-rtl .chosen-drop{left:9999px}.chosen-rtl.chosen-container-single .chosen-results{margin:0 0 4px 4px;padding:0 4px 0 0}.chosen-rtl .chosen-results li.group-option{padding-right:15px;padding-left:0}.chosen-rtl.chosen-container-active.chosen-with-drop .chosen-single div{border-right:0}.chosen-rtl .chosen-search input[type=text]{padding:4px 5px 4px 20px;background:#fff url(../img/chosen-sprite.png) no-repeat -30px -20px;background:url(../img/chosen-sprite.png) no-repeat -30px -20px;direction:rtl}.chosen-rtl.chosen-container-single .chosen-single div b{background-position:6px 2px}.chosen-rtl.chosen-container-single.chosen-with-drop .chosen-single div b{background-position:-12px 2px}@media only screen and (-webkit-min-device-pixel-ratio:1.5),only screen and (min-resolution:144dpi),only screen and (min-resolution:1.5dppx){.chosen-rtl .chosen-search input[type=text],.chosen-container-single .chosen-single abbr,.chosen-container-single .chosen-single div b,.chosen-container-single .chosen-search input[type=text],.chosen-container-multi .chosen-choices .search-choice .search-choice-close,.chosen-container .chosen-results-scroll-down span,.chosen-container .chosen-results-scroll-up span{background-image:url(../img/chosen-sprite@2x.png)!important;background-size:52px 37px!important;background-repeat:no-repeat!important}}
css/style.css CHANGED
@@ -1,3 +1,7 @@
 
 
 
 
1
  /* Clearfix */
2
  .clearfix:after { content: "\00A0"; display: block; clear: both; visibility: hidden; line-height: 0; height: 0;}
3
  .clearfix{ display: inline-block;}
@@ -142,7 +146,7 @@ strong {
142
  .cwp_top_wrapper .option .left .select-all { float: right; background: none; border: none; background:#ddd; border-radius: 3px; padding: 5px 10px; }
143
  .cwp_top_wrapper .option .left .select-all:hover { cursor: pointer; }
144
  .cwp_top_wrapper .option label { font-family: "Helvetica Neue", HelveticaNeue, sans-serif; font-size: 15px; color:#525252; }
145
- .cwp_top_wrapper .option input[type=text], .cwp_top_wrapper .cwp_top_container form .option select { height: 35px; border-radius: 3px; border: 1px solid #d7d7d7; box-shadow: none; font-family: "Roboto", sans-serif; }
146
  .cwp_top_wrapper .option input[type=text] { width: 90%; }
147
  .cwp_top_wrapper .option .left * { display: block; text-align: right; }
148
  .cwp_top_wrapper .option .right { float: left; width: 55%; padding-left: 20px; }
@@ -186,16 +190,15 @@ strong {
186
  .cwp_top_wrapper a { margin: 0 !important; padding: 0; margin-right: 10px !important; margin-bottom:10px!important;}
187
 
188
  /* Sample Tweet Preview Modal */
189
- .cwp_top_wrapper .cwp_lkapp_preview, .cwp_top_wrapper .cwp_xingapp_preview, .cwp_top_wrapper .cwp_tumblrapp_preview, .cwp_top_wrapper .cwp_not_version_preview,.cwp_top_wrapper .cwp_user_pages { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
190
 
191
- .cwp_top_wrapper .cwp_fbapp_preview,.cwp_top_wrapper .cwp_user_pages { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
192
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner h2 { text-align: center; font-weight: bold;color:#7d7d7d; font-family: "HelveticaNeue", "Helvetica Neue", sans-serif; }
193
- .cwp_top_wrapper .cwp_sample_tweet_preview_inner { background:#fff; width: 80%; margin: 0 auto; margin-top: 109px; padding: 20px; border-radius: 5px;box-shadow: 0px 5px 5px rgba(0,0,0,0.1); }
194
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner .sample_tweet { min-height:60px; display: block; width: 100%; border: 1px solid #e8e8e8; padding: 10px; border-radius: 5px; font-family: "Helvetica Neue", HelveticaNeue, sans-serif; font-size: 14px;}
195
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner .sample_tweet a { text-decoration: none; }
196
- .cwp_top_wrapper .cwp_sample_tweet_preview_inner button { display: block; margin-top: 17px; background:#52c4ef; border: none; border-radius: 3px; padding: 5px 10px; margin-left:10px;margin-right:10px;color:#fff; font-family: "Open Sans", sans-serif; color:#fff; text-transform: uppercase; font-weight: bold; }
197
- .cwp_top_wrapper .cwp_sample_tweet_preview_inner button:hover { cursor: pointer; }
198
-
199
  .cwp_top_wrapper .cwp_sample_tweet_preview { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
200
 
201
 
@@ -245,24 +248,49 @@ float: left;}
245
  float: left;
246
  border-right: none;
247
  }
248
-
249
-
250
  .top_left_instructions {
251
  float: left;
252
- width: 50%;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
253
  }
254
  .top_auth_form {
255
- width:50%;
 
 
256
  float: left;
257
  }
258
  .top_sample_auth{
259
- height: 370px;
 
260
  }
261
  .top_auth_inner {
262
- height: 500px;
263
  }
264
  .top_authorize{
265
- margin-left:50px;
 
266
  }
267
  @media all and (max-width:1280px) {
268
  .cwp_top_wrapper {
@@ -819,10 +847,8 @@ button.login{
819
  }
820
  .cwp_top_wrapper .cwp_not_version_preview .top_close_popup
821
  {
822
-
823
  margin: auto;
824
  float: none;
825
-
826
  }
827
  .cwp_top_wrapper .cwp_not_version_preview h2{
828
  line-height: 26px;
@@ -1037,8 +1063,58 @@ button.login{
1037
  font-size: 14px;
1038
  }
1039
 
1040
- @media (max-width: 1200px) {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1041
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1042
  #cwp-top-container-form {
1043
  width: 100%;
1044
  }
@@ -1139,3 +1215,12 @@ button.login{
1139
  font-weight: bold;
1140
  }
1141
 
 
 
 
 
 
 
 
 
 
1
+ /*
2
+ # Version: 7.3.8
3
+ */
4
+
5
  /* Clearfix */
6
  .clearfix:after { content: "\00A0"; display: block; clear: both; visibility: hidden; line-height: 0; height: 0;}
7
  .clearfix{ display: inline-block;}
146
  .cwp_top_wrapper .option .left .select-all { float: right; background: none; border: none; background:#ddd; border-radius: 3px; padding: 5px 10px; }
147
  .cwp_top_wrapper .option .left .select-all:hover { cursor: pointer; }
148
  .cwp_top_wrapper .option label { font-family: "Helvetica Neue", HelveticaNeue, sans-serif; font-size: 15px; color:#525252; }
149
+ .cwp_top_wrapper .option input[type=text], .cwp_top_wrapper .cwp_top_container form .option select, ul.chosen-choices { height: 35px !important; border-radius: 3px; border: 1px solid #d7d7d7 !important; box-shadow: none; font-family: "Roboto", sans-serif; }
150
  .cwp_top_wrapper .option input[type=text] { width: 90%; }
151
  .cwp_top_wrapper .option .left * { display: block; text-align: right; }
152
  .cwp_top_wrapper .option .right { float: left; width: 55%; padding-left: 20px; }
190
  .cwp_top_wrapper a { margin: 0 !important; padding: 0; margin-right: 10px !important; margin-bottom:10px!important;}
191
 
192
  /* Sample Tweet Preview Modal */
193
+ .cwp_top_wrapper .cwp_lkapp_preview, .cwp_top_wrapper .cwp_xingapp_preview, .cwp_top_wrapper .cwp_tumblrapp_preview, .cwp_top_wrapper .cwp_not_version_preview,.cwp_top_wrapper .cwp_user_pages { z-index: 200; position: absolute; top: 0; left: -20px; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
194
 
195
+ .cwp_top_wrapper .cwp_fbapp_preview,.cwp_top_wrapper .cwp_user_pages { z-index: 200; position: absolute; top: 0; left: -20px; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
196
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner h2 { text-align: center; font-weight: bold;color:#7d7d7d; font-family: "HelveticaNeue", "Helvetica Neue", sans-serif; }
197
+ .cwp_top_wrapper .cwp_sample_tweet_preview_inner { background:#fff; width: 80%; margin: 0 auto; margin-top: 50px; padding: 20px; border-radius: 5px;box-shadow: 0px 5px 5px rgba(0,0,0,0.1); }
198
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner .sample_tweet { min-height:60px; display: block; width: 100%; border: 1px solid #e8e8e8; padding: 10px; border-radius: 5px; font-family: "Helvetica Neue", HelveticaNeue, sans-serif; font-size: 14px;}
199
  .cwp_top_wrapper .cwp_sample_tweet_preview_inner .sample_tweet a { text-decoration: none; }
200
+ .cwp_top_wrapper .cwp_sample_tweet_preview_inner button { margin-top: 17px; background:#52c4ef; border: none; float:none; border-radius: 3px; padding: 5px 10px; margin: 10px 0 0 0; color:#fff; font-family: "Open Sans", sans-serif; color:#fff; text-transform: uppercase; font-weight: bold; transition: .2s ease all;}
201
+ .cwp_top_wrapper .cwp_sample_tweet_preview_inner button:hover { cursor: pointer; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.06), 0 2px 7px 0 rgba(0, 0, 0, 0.05); background-color: #489def; }
 
202
  .cwp_top_wrapper .cwp_sample_tweet_preview { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background:rgba(0,0,0,0.2); display: none; }
203
 
204
 
248
  float: left;
249
  border-right: none;
250
  }
 
 
251
  .top_left_instructions {
252
  float: left;
253
+ width: 48%;
254
+ padding-right: 2%;
255
+ border-right: 1px solid #eee;
256
+ }
257
+ .top_left_instructions ol li{
258
+ text-align: justify;
259
+ margin-bottom: 10px;
260
+ border-bottom: 1px solid #eee;
261
+ padding-bottom: 5px;
262
+ line-height: 21px;
263
+ }
264
+ .video-tutorial-link {
265
+ text-align: center;
266
+ margin-bottom:10px;
267
+ }
268
+ .video-tutorial-link a {
269
+ margin-right: 0 !important;
270
+ }
271
+
272
+ .cwp_tumblrapp_preview .top_auth_form, .cwp_xingapp_preview .top_auth_form {
273
+ margin-top: 90px;
274
+ }
275
+ .cwp_fbapp_preview .top_auth_form, .cwp_lkapp_preview .top_auth_form {
276
+ margin-top: 200px;
277
  }
278
  .top_auth_form {
279
+ text-align: center;
280
+ width:48%;
281
+ padding-left: 2%;
282
  float: left;
283
  }
284
  .top_sample_auth{
285
+ height: auto;
286
+ overflow: overlay;
287
  }
288
  .top_auth_inner {
289
+ height: auto;
290
  }
291
  .top_authorize{
292
+ margin: 0 auto;
293
+ text-align: center;
294
  }
295
  @media all and (max-width:1280px) {
296
  .cwp_top_wrapper {
847
  }
848
  .cwp_top_wrapper .cwp_not_version_preview .top_close_popup
849
  {
 
850
  margin: auto;
851
  float: none;
 
852
  }
853
  .cwp_top_wrapper .cwp_not_version_preview h2{
854
  line-height: 26px;
1063
  font-size: 14px;
1064
  }
1065
 
1066
+ #top_exc_inc_radio > label.ui-button.ui-state-default.ui-state-active > span {
1067
+ color: #fff;
1068
+ box-shadow: none;
1069
+ background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #44b0e7), color-stop(100%, #3198de));
1070
+ background-image: -webkit-linear-gradient(top, #44b0e7, #3198de);
1071
+ background-image: -moz-linear-gradient(top, #44b0e7, #3198de);
1072
+ background-image: -ms-linear-gradient(top, #44b0e7, #3198de);
1073
+ background-image: -o-linear-gradient(top, #44b0e7, #3198de);
1074
+ background-image: linear-gradient(top, #44b0e7, #3198de);
1075
+ }
1076
+
1077
+ #top_exc_inc_radio > label.ui-button.ui-state-default > span {
1078
+ position: relative;
1079
+ z-index: 2;
1080
+ float: left;
1081
+ width: 112px;
1082
+ line-height: 27px;
1083
+ font-size: 14px;
1084
+ color: #333;
1085
+ padding: 0px;
1086
+ text-align: center;
1087
+ text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
1088
+ cursor: pointer;
1089
+ }
1090
+ #top_exc_inc_radio{
1091
+ text-align: center;
1092
+ margin-top: 23px;
1093
+ }
1094
+ .ui-buttonset {
1095
+ margin-bottom: 10px;
1096
+ }
1097
+
1098
+ .option.twptop_opt_omit_cats .left {
1099
+ padding-top: 20px;
1100
+ }
1101
 
1102
+ @media (max-width: 1200px) {
1103
+ .cwp_top_wrapper .cwp_sample_tweet_preview_inner {
1104
+ margin-top: 20px;
1105
+ }
1106
+ .top_left_instructions {
1107
+ width: 100%;
1108
+ float: none;
1109
+ border: none;
1110
+ }
1111
+ .top_auth_form {
1112
+ margin-top: 10px !important;
1113
+ padding-top: 20px;
1114
+ border-top: 2px solid #3eaed8;
1115
+ width: 100%;
1116
+ padding-left: 0px;
1117
+ }
1118
  #cwp-top-container-form {
1119
  width: 100%;
1120
  }
1215
  font-weight: bold;
1216
  }
1217
 
1218
+
1219
+ /* jquery.chosen */
1220
+ .chosen-container-multi .chosen-choices li.search-choice .search-choice-close {
1221
+ margin: 0 !important;
1222
+ }
1223
+ ul.chosen-choices {
1224
+ background-image: none !important;
1225
+ }
1226
+ /* jquery.chosen */
img/chosen-sprite.png ADDED
Binary file
img/chosen-sprite@2x.png ADDED
Binary file
inc/config.php CHANGED
@@ -25,8 +25,8 @@ $cwp_rop_self_endpoint = "rop_checking_schedule";
25
  $cwp_top_global_schedule = array();
26
  if(!defined('ROP_PRO_VERSION'))
27
  $cwp_top_networks = array();
28
- define("CWP_TOP_PRO_STRING",'<span class="cwp-pro-string">'.__("This is only available in the",'tweet-old-post')."<a href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true' target='_blank'> ".__("PRO version")."</a></span>");
29
- define("CWP_TOP_PRO_BUSINESS_STRING",'<span class="cwp-pro-string">'.__("This is only available in the",'tweet-old-post')."<a href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true' target='_blank'> ".__("BUSINESS version")."</a></span>");
30
 
31
  $cwp_rop_all_networks = array("twitter"=>false,"facebook"=>false,"linkedin"=>true, "xing"=>true,"tumblr"=>true);
32
  $cwp_rop_restricted_show = array("bitly-key","bitly-user");
@@ -165,19 +165,19 @@ $cwp_format_fields = array(
165
  'description' => __('Shorten the link to your post.', 'tweet-old-post'),
166
  'options' => array(
167
  'wp_short_url' => __('wp short url', 'tweet-old-post'),
168
- //'t.co' => __('t.co', 'tweet-old-post'),
169
  'is.gd' => __('is.gd', 'tweet-old-post'),
170
  'bit.ly' => __('bit.ly', 'tweet-old-post'),
171
- //'tr.im' => __('tr.im', 'tweet-old-post'),
172
- //'3.ly' => __('3.ly', 'tweet-old-post'),
173
- //'u.nu' => __('u.nu', 'tweet-old-post'),
174
- //'1click.at' => __('1click.at', 'tweet-old-post'),
175
- //'tinyurl' => __('TinyUrl', 'tweet-old-post')
176
 
177
  ),
178
  'dependency'=> array(
 
179
  "bitly-key"=>"bit.ly",
180
- "bitly-user"=>"bit.ly"
 
 
181
  ),
182
  'default_value'=>'wp_short_url'
183
  ),
@@ -203,6 +203,36 @@ $cwp_format_fields = array(
203
  'options' => '',
204
  'default_value' => '',
205
  ),
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
206
 
207
  'custom-hashtag-option' => array(
208
  'id' => '10',
@@ -329,7 +359,8 @@ $cwp_top_fields = array(
329
  'slug' => 'tweet-multiple-times',
330
  'option' => 'top_opt_tweet_multiple_times',
331
  'description' => __('By default once a post is shared it will not be shared again until you stop/start the plugin', 'tweet-old-post'),
332
- 'options' => array()
 
333
  ),
334
 
335
 
@@ -358,11 +389,11 @@ $cwp_top_fields = array(
358
 
359
  'exclude-specific-categories' => array(
360
  'id' => '21',
361
- 'name' => __('Exclude Specific Categories', 'tweet-old-post'),
362
  'type' => 'categories-list',
363
  'slug' => 'exclude-specific-category',
364
  'option' => 'top_opt_omit_cats',
365
- 'description' => __('Select which categories do you want to exclude to share from? Blank - None', 'tweet-old-post'),
366
  'options' => array()
367
  ),
368
  'image-size'=>array(
25
  $cwp_top_global_schedule = array();
26
  if(!defined('ROP_PRO_VERSION'))
27
  $cwp_top_networks = array();
28
+ define("CWP_TOP_PRO_STRING",'<span class="cwp-pro-string">'.__("This is only available in the",'tweet-old-post')."<a href='http://revive.social/plugins/revive-old-post/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true' target='_blank'> ".__("PRO version")."</a></span>");
29
+ define("CWP_TOP_PRO_BUSINESS_STRING",'<span class="cwp-pro-string">'.__("This is only available in the",'tweet-old-post')."<a href='http://revive.social/plugins/revive-old-post/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true' target='_blank'> ".__("BUSINESS version")."</a></span>");
30
 
31
  $cwp_rop_all_networks = array("twitter"=>false,"facebook"=>false,"linkedin"=>true, "xing"=>true,"tumblr"=>true);
32
  $cwp_rop_restricted_show = array("bitly-key","bitly-user");
165
  'description' => __('Shorten the link to your post.', 'tweet-old-post'),
166
  'options' => array(
167
  'wp_short_url' => __('wp short url', 'tweet-old-post'),
 
168
  'is.gd' => __('is.gd', 'tweet-old-post'),
169
  'bit.ly' => __('bit.ly', 'tweet-old-post'),
170
+ 'shorte.st' => __('shorte.st', 'tweet-old-post'),
171
+ 'goo.gl' => __('goo.gl', 'tweet-old-post'),
172
+ 'ow.ly' => __('ow.ly', 'tweet-old-post'),
 
 
173
 
174
  ),
175
  'dependency'=> array(
176
+ "bitly-user"=>"bit.ly",
177
  "bitly-key"=>"bit.ly",
178
+ "shortest-key"=>"shorte.st",
179
+ "googl-key"=>"goo.gl",
180
+ "owly-key"=>"ow.ly",
181
  ),
182
  'default_value'=>'wp_short_url'
183
  ),
203
  'options' => '',
204
  'default_value' => '',
205
  ),
206
+ 'shortest-key' => array(
207
+ 'id' => '100',
208
+ 'name' => __('Shortest API Key', 'tweet-old-post'),
209
+ 'type' => 'text',
210
+ 'slug' => 'shortest-key',
211
+ 'option' => 'top_opt_shortest_key',
212
+ 'description' => '',
213
+ 'options' => '',
214
+ 'default_value' => '',
215
+ ),
216
+ 'googl-key' => array(
217
+ 'id' => '101',
218
+ 'name' => __('Google API Key', 'tweet-old-post'),
219
+ 'type' => 'text',
220
+ 'slug' => 'googl-key',
221
+ 'option' => 'top_opt_googl_key',
222
+ 'description' => '',
223
+ 'options' => '',
224
+ 'default_value' => '',
225
+ ),
226
+ 'owly-key' => array(
227
+ 'id' => '102',
228
+ 'name' => __('Ow.ly API Key', 'tweet-old-post'),
229
+ 'type' => 'text',
230
+ 'slug' => 'owly-key',
231
+ 'option' => 'top_opt_owly_key',
232
+ 'description' => '',
233
+ 'options' => '',
234
+ 'default_value' => '',
235
+ ),
236
 
237
  'custom-hashtag-option' => array(
238
  'id' => '10',
359
  'slug' => 'tweet-multiple-times',
360
  'option' => 'top_opt_tweet_multiple_times',
361
  'description' => __('By default once a post is shared it will not be shared again until you stop/start the plugin', 'tweet-old-post'),
362
+ 'options' => array(),
363
+ 'default_value' => "on",
364
  ),
365
 
366
 
389
 
390
  'exclude-specific-categories' => array(
391
  'id' => '21',
392
+ 'name' => __('Exclude/Include Specific Categories', 'tweet-old-post'),
393
  'type' => 'categories-list',
394
  'slug' => 'exclude-specific-category',
395
  'option' => 'top_opt_omit_cats',
396
+ 'description' => __('Select which categories do you want to exclude/include to share from? Blank - None', 'tweet-old-post'),
397
  'options' => array()
398
  ),
399
  'image-size'=>array(
inc/core.php CHANGED
@@ -6,6 +6,7 @@ require_once(ROPPLUGINPATH."/inc/oAuth/twitteroauth.php");
6
 
7
  // Added by Ash/Upwork
8
  define("ROP_IS_TEST", false);
 
9
  // Added by Ash/Upwork
10
 
11
 
@@ -40,6 +41,8 @@ if (!class_exists('CWP_TOP_Core')) {
40
  public $cwp_twitter;
41
  public static $date_format;
42
  public function __construct() {
 
 
43
  // Get all fields
44
  global $cwp_top_fields;
45
  global $cwp_top_networks;
@@ -275,7 +278,7 @@ if (!class_exists('CWP_TOP_Core')) {
275
  $excluded = array_merge($tweetedPosts,$postQueryExcludedPosts);
276
  $excluded = array_unique($excluded);
277
  $excluded = array_filter($excluded);
278
- $postQueryExcludedCategories = $this->getExcludedCategories();
279
  $somePostType = $this->getTweetPostType();
280
  // Generate dynamic query.
281
  $query = "
@@ -298,12 +301,13 @@ if (!class_exists('CWP_TOP_Core')) {
298
  // $query .= "AND (wp_term_relationships.term_taxonomy_id IN ({$postQueryCategories})) ";
299
  // }
300
 
301
- if(!empty($postQueryExcludedCategories)) {
302
- $query .= "AND ( {$wpdb->prefix}posts.ID NOT IN (
 
303
  SELECT object_id
304
  FROM {$wpdb->prefix}term_relationships
305
  INNER JOIN {$wpdb->prefix}term_taxonomy ON ( {$wpdb->prefix}term_relationships.term_taxonomy_id = {$wpdb->prefix}term_taxonomy.term_taxonomy_id )
306
- WHERE {$wpdb->prefix}term_taxonomy.term_id IN ({$postQueryExcludedCategories}))) ";
307
  }
308
 
309
  if(!empty($excluded)) {
@@ -335,7 +339,7 @@ if (!class_exists('CWP_TOP_Core')) {
335
 
336
  $returnedPost = $wpdb->get_results( $query);
337
 
338
- //self::addLog("rows " . count($returnedPost) . " from " . $query);
339
 
340
  // Added by Ash/Upwork
341
  // If the number of posts found is zero and a post can be shared multiple times, lets clear the buffer and fetch again
@@ -687,7 +691,7 @@ if (!class_exists('CWP_TOP_Core')) {
687
  elseif ( stripos($tweetContent, $hashtag . ' ') === 0 ) { // see if the hashtag is at the beginning
688
  $location = 0;
689
  }
690
- elseif ( stripos($tweetContent, ' ' . $hashtag) + strlen(' ' . $hashtag) == strlen($tweetContent) ) { // see if the hashtag is at the end
691
  $location = stripos($tweetContent, ' ' . $hashtag) + 1;
692
  }
693
  if ( $location !== false ) {
@@ -722,8 +726,6 @@ if (!class_exists('CWP_TOP_Core')) {
722
  $common_hashtags = isset($formats[$network."_"."top_opt_hashtags"]) ? $formats[$network."_"."top_opt_hashtags"] : get_option( 'top_opt_hashtags' );
723
  $maximum_hashtag_length = isset($formats[$network."_"."top_opt_hashtag_length"]) ? $formats[$network."_"."top_opt_hashtag_length"] : get_option( 'top_opt_hashtag_length' );
724
  $hashtag_custom_field = isset($formats[$network."_"."top_opt_custom_hashtag_field"]) ? $formats[$network."_"."top_opt_custom_hashtag_field"] : get_option( 'top_opt_custom_hashtag_field' );
725
- $bitly_key = isset($formats[$network."_"."top_opt_bitly_key"]) ? $formats[$network."_"."top_opt_bitly_key"] : get_option( 'top_opt_bitly_key' );
726
- $bitly_user = isset($formats[$network."_"."top_opt_bitly_user"]) ? $formats[$network."_"."top_opt_bitly_user"] : get_option( 'top_opt_bitly_user' );
727
  $post_with_image = isset($formats[$network."_". 'top_opt_post_with_image']) ? $formats[$network."_". 'top_opt_post_with_image'] : get_option( 'top_opt_bitly_user' );
728
  $ga_tracking = get_option( 'top_opt_ga_tracking' );
729
  $additionalTextBeginning = "";
@@ -794,7 +796,7 @@ if (!class_exists('CWP_TOP_Core')) {
794
  // Added by Ash/Upwork
795
  }
796
  // $fromManageQueue Added by Ash/Upwork
797
- $post_url = "" . self::shortenURL( $post_url, $url_shortner_service, $postQuery->ID, $bitly_key, $bitly_user, $fromManageQueue );
798
  // $fromManageQueue Added by Ash/Upwork
799
  }
800
  if ( $post_url == "" ) {
@@ -845,6 +847,10 @@ if (!class_exists('CWP_TOP_Core')) {
845
  }
846
  break;
847
  case 'custom':
 
 
 
 
848
  $newHashtags = get_post_meta( $postQuery->ID, $hashtag_custom_field, true );
849
  if($maximum_hashtag_length != 0){
850
  if(strlen( $newHashtags ) <= $maximum_hashtag_length)
@@ -1909,10 +1915,10 @@ endif;
1909
  $response = array();
1910
 
1911
  if($allnetworks[$social_network] && !CWP_TOP_PRO){
1912
- self::addNotice("You need to <a target='_blank' href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add a ".ucwords($social_network)." account, fellow pirate!",'error');
1913
 
1914
  }else if(in_array($social_network,$networks) && !CWP_TOP_PRO) {
1915
- self::addNotice("You need to <a target='_blank' href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!",'error');
1916
 
1917
 
1918
  }else{
@@ -1984,8 +1990,8 @@ endif;
1984
  $CWP_TOP_Core_PRO->topProAddNewAccount($_POST['social_network']);
1985
  }
1986
  else{
1987
- update_option('cwp_topnew_notice',"You need to <a target='_blank' href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!");
1988
- echo "You need to <a target='_blank' href='https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!";
1989
 
1990
  }
1991
  die(); // Required
@@ -2335,6 +2341,11 @@ endif;
2335
  'top_opt_posts_buffer_linkedin' => '',
2336
  'top_opt_posts_buffer_tumblr' => '',
2337
  'top_opt_posts_buffer_xing' => '',
 
 
 
 
 
2338
  // Added by Ash/Upwork
2339
  );
2340
 
@@ -2522,6 +2533,7 @@ endif;
2522
  $post_types["post"] = get_post_type_object( 'post' );
2523
  $post_types["page"] = get_post_type_object( 'page' );
2524
 
 
2525
  foreach($post_types as $pt=>$pd){
2526
  foreach($taxs as $tx){
2527
 
@@ -2533,39 +2545,23 @@ endif;
2533
 
2534
  ) );
2535
  if(!empty($terms)){
2536
- print "<div class='categories-list cwp-hidden cwp-tax-".$pt."'><p class='rop-category-header'>".$tx->labels->name." </p>";
 
2537
  foreach ($terms as $t) {
2538
-
2539
- if (!is_array(get_option('top_opt_omit_cats')))
2540
- $top_opt_omit_specific_cats = explode(',',get_option('top_opt_omit_cats'));
2541
- else
2542
- $top_opt_omit_specific_cats = get_option('top_opt_omit_cats');
2543
-
2544
- print "<div class='cwp-cat'>";
2545
- print "<input type='checkbox' data-posttype='".$pt."' name='".$field['option']."[]' value='".$t->term_id."' id='".$field['option']."_cat_".$t->term_id."'";
2546
-
2547
- if($field['option'] == 'top_opt_omit_cats') {
2548
- if(is_array($top_opt_omit_specific_cats)) {
2549
- if(in_array($t->term_id, $top_opt_omit_specific_cats)) {
2550
- print "checked=checked";
2551
- }
2552
- }
2553
- }
2554
-
2555
-
2556
- print ">";
2557
- print "<label for='".$field['option']."_cat_".$t->term_id."'>".$t->name."</label>";
2558
- print "</div>";
2559
- }
2560
- print "<div class='clear'></div></div>";
2561
  }
2562
-
2563
  }
2564
-
2565
  }
2566
-
2567
  }
2568
 
 
 
 
 
 
2569
 
2570
  break;
2571
 
@@ -2716,7 +2712,7 @@ endif;
2716
  set_transient( 'rop_remote_calls', "done", 24 * HOUR_IN_SECONDS );
2717
  }
2718
  if(!defined("VERSION_CHECK") && function_exists('topProImage')){
2719
- $this->notices[] = "You need to have the latest version of the Revive Old Post Pro addon in order to use it. Please download it from the themeisle.com account";
2720
 
2721
  }
2722
  $all = $this->getAllNetworks();
@@ -3116,8 +3112,19 @@ endif;
3116
  if(isset($_GET['page'])) {
3117
  if ($_GET['page'] == $cwp_top_settings['slug'] || $_GET['page'] == "ExcludePosts") {
3118
 
3119
- // Enqueue and Register Main CSS File
3120
- wp_register_style( 'cwp_top_stylesheet', ROPCSSFILE, false, time() );
 
 
 
 
 
 
 
 
 
 
 
3121
  wp_enqueue_style( 'cwp_top_stylesheet' );
3122
 
3123
  // Register Main JS File
@@ -3219,82 +3226,88 @@ endif;
3219
  require_once(plugin_dir_path( __FILE__ )."view.php");
3220
  }
3221
 
3222
- // Sends a request to the passed URL
3223
- public static function sendRequest($url, $method='GET', $data='', $auth_user='', $auth_pass='') {
3224
-
3225
- $ch = curl_init($url);
3226
-
3227
- if (strtoupper($method) == "POST") {
3228
- curl_setopt($ch, CURLOPT_POST, 1);
3229
- curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
3230
- }
3231
-
3232
- if (ini_get('open_basedir') == '' && ini_get('safe_mode') == 'Off') {
3233
- curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
3234
- }
3235
-
3236
- curl_setopt($ch, CURLOPT_HEADER, 0);
3237
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
3238
-
3239
- if ($auth_user != '' && $auth_pass != '') {
3240
- curl_setopt($ch, CURLOPT_USERPWD, "{$auth_user}:{$auth_pass}");
3241
- }
3242
-
3243
- $response = curl_exec($ch);
3244
-
3245
- $httpcode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
3246
-
3247
- curl_close($ch);
3248
-
3249
- if ($httpcode != 200) {
3250
- self::addNotice("Error for request: " . $url . " : ". $response,'error');
3251
- return $httpcode;
3252
- }
3253
-
3254
- return $response;
3255
- }
3256
-
3257
  // Shortens the url.
3258
- public static function shortenURL($url, $service, $id, $bitly_key, $bitly_user, $showPlaceholder=false) {
3259
  // Added by Ash/Upwork
3260
  if ($showPlaceholder) {
3261
  return "[$service]";
3262
  }
3263
  // Added by Ash/Upwork
3264
- $url = urlencode($url);
3265
- if ($service == "bit.ly") {
3266
-
3267
- //$shortURL = $url;
3268
- $url = trim($url);
3269
- $bitly_key = trim($bitly_key);
3270
- $bitly_user = trim($bitly_user);
3271
- $shortURL = "http://api.bit.ly/v3/shorten?format=txt&login=".$bitly_user."&apiKey=".$bitly_key."&longUrl={$url}";
3272
- $shortURL = self::sendRequest($shortURL, 'GET');
3273
-
3274
- } elseif ($service == "tr.im") {
3275
- $shortURL = "http://api.tr.im/api/trim_simple?url={$url}";
3276
- $shortURL = self::sendRequest($shortURL, 'GET');
3277
- } elseif ($service == "3.ly") {
3278
- $shortURL = "http://3.ly/?api=em5893833&u={$url}";
3279
- $shortURL = self::sendRequest($shortURL, 'GET');
3280
- } elseif ($service == "tinyurl") {
3281
- $shortURL = "http://tinyurl.com/api-create.php?url=" . $url;
3282
- $shortURL = self::sendRequest($shortURL, 'GET');
3283
- } elseif ($service == "u.nu") {
3284
- $shortURL = "http://u.nu/unu-api-simple?url={$url}";
3285
- $shortURL = self::sendRequest($shortURL, 'GET');
3286
- } elseif ($service == "1click.at") {
3287
- $shortURL = "http://1click.at/api.php?action=shorturl&url={$url}&format=simple";
3288
- $shortURL = self::sendRequest($shortURL, 'GET');
3289
- } elseif ($service == "is.gd") {
3290
-
3291
- $shortURL = "https://is.gd/api.php?longurl={$url}";
3292
- $shortURL = self::sendRequest($shortURL, 'GET');
3293
- } elseif ($service == "t.co") {
3294
- $shortURL = "http://twitter.com/share?url={$url}";
3295
- $shortURL = self::sendRequest($shortURL, 'GET');
3296
- } else {
3297
- $shortURL = wp_get_shortlink($id);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3298
  }
3299
  if($shortURL != ' 400 '&& $shortURL!="500" && $shortURL!="0") {
3300
  return $shortURL;
@@ -3310,6 +3323,81 @@ endif;
3310
 
3311
  }
3312
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3313
  }
3314
  }
3315
 
6
 
7
  // Added by Ash/Upwork
8
  define("ROP_IS_TEST", false);
9
+ define("ROP_IS_DEBUG", false);
10
  // Added by Ash/Upwork
11
 
12
 
41
  public $cwp_twitter;
42
  public static $date_format;
43
  public function __construct() {
44
+ if (ROP_IS_DEBUG) @mkdir(ROPPLUGINPATH . "/tmp");
45
+
46
  // Get all fields
47
  global $cwp_top_fields;
48
  global $cwp_top_networks;
278
  $excluded = array_merge($tweetedPosts,$postQueryExcludedPosts);
279
  $excluded = array_unique($excluded);
280
  $excluded = array_filter($excluded);
281
+ $specificCategories = $this->getExcludedCategories();
282
  $somePostType = $this->getTweetPostType();
283
  // Generate dynamic query.
284
  $query = "
301
  // $query .= "AND (wp_term_relationships.term_taxonomy_id IN ({$postQueryCategories})) ";
302
  // }
303
 
304
+ if(!empty($specificCategories)) {
305
+ $categoryFilter = get_option("top_opt_cat_filter", "exclude") == "exclude" ? "NOT IN" : "IN";
306
+ $query .= "AND ( {$wpdb->prefix}posts.ID {$categoryFilter} (
307
  SELECT object_id
308
  FROM {$wpdb->prefix}term_relationships
309
  INNER JOIN {$wpdb->prefix}term_taxonomy ON ( {$wpdb->prefix}term_relationships.term_taxonomy_id = {$wpdb->prefix}term_taxonomy.term_taxonomy_id )
310
+ WHERE {$wpdb->prefix}term_taxonomy.term_id IN ({$specificCategories}))) ";
311
  }
312
 
313
  if(!empty($excluded)) {
339
 
340
  $returnedPost = $wpdb->get_results( $query);
341
 
342
+ self::writeDebug("rows " . count($returnedPost) . " from " . $query);
343
 
344
  // Added by Ash/Upwork
345
  // If the number of posts found is zero and a post can be shared multiple times, lets clear the buffer and fetch again
691
  elseif ( stripos($tweetContent, $hashtag . ' ') === 0 ) { // see if the hashtag is at the beginning
692
  $location = 0;
693
  }
694
+ elseif ( stripos($tweetContent, ' ' . $hashtag) !== FALSE && stripos($tweetContent, ' ' . $hashtag) + strlen(' ' . $hashtag) == strlen($tweetContent) ) { // see if the hashtag is at the end
695
  $location = stripos($tweetContent, ' ' . $hashtag) + 1;
696
  }
697
  if ( $location !== false ) {
726
  $common_hashtags = isset($formats[$network."_"."top_opt_hashtags"]) ? $formats[$network."_"."top_opt_hashtags"] : get_option( 'top_opt_hashtags' );
727
  $maximum_hashtag_length = isset($formats[$network."_"."top_opt_hashtag_length"]) ? $formats[$network."_"."top_opt_hashtag_length"] : get_option( 'top_opt_hashtag_length' );
728
  $hashtag_custom_field = isset($formats[$network."_"."top_opt_custom_hashtag_field"]) ? $formats[$network."_"."top_opt_custom_hashtag_field"] : get_option( 'top_opt_custom_hashtag_field' );
 
 
729
  $post_with_image = isset($formats[$network."_". 'top_opt_post_with_image']) ? $formats[$network."_". 'top_opt_post_with_image'] : get_option( 'top_opt_bitly_user' );
730
  $ga_tracking = get_option( 'top_opt_ga_tracking' );
731
  $additionalTextBeginning = "";
796
  // Added by Ash/Upwork
797
  }
798
  // $fromManageQueue Added by Ash/Upwork
799
+ $post_url = "" . self::shortenURL( $post_url, $url_shortner_service, $postQuery->ID, $formats, $network, $fromManageQueue );
800
  // $fromManageQueue Added by Ash/Upwork
801
  }
802
  if ( $post_url == "" ) {
847
  }
848
  break;
849
  case 'custom':
850
+ if(empty($hashtag_custom_field)){
851
+ self::addNotice("You need to add a custom field name in order to fetch the hashtags. Please set it from Post Format > $network > Hashtag Custom Field ",'error');
852
+ break;
853
+ }
854
  $newHashtags = get_post_meta( $postQuery->ID, $hashtag_custom_field, true );
855
  if($maximum_hashtag_length != 0){
856
  if(strlen( $newHashtags ) <= $maximum_hashtag_length)
1915
  $response = array();
1916
 
1917
  if($allnetworks[$social_network] && !CWP_TOP_PRO){
1918
+ self::addNotice("You need to <a target='_blank' href='http://revive.social/plugins/revive-old-post/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add a ".ucwords($social_network)." account, fellow pirate!",'error');
1919
 
1920
  }else if(in_array($social_network,$networks) && !CWP_TOP_PRO) {
1921
+ self::addNotice("You need to <a target='_blank' href='http://revive.social/plugins/revive-old-post/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!",'error');
1922
 
1923
 
1924
  }else{
1990
  $CWP_TOP_Core_PRO->topProAddNewAccount($_POST['social_network']);
1991
  }
1992
  else{
1993
+ update_option('cwp_topnew_notice',"You need to <a target='_blank' href='http://revive.sociahttp://revive.social/plugins/revive-old-post/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!");
1994
+ echo "You need to <a target='_blank' href='http://revive.social/plugins/revive-old-post/?utm_source=topplusacc&utm_medium=announce&utm_campaign=top&upgrade=true'>upgrade to the PRO version</a> in order to add more accounts, fellow pirate!";
1995
 
1996
  }
1997
  die(); // Required
2341
  'top_opt_posts_buffer_linkedin' => '',
2342
  'top_opt_posts_buffer_tumblr' => '',
2343
  'top_opt_posts_buffer_xing' => '',
2344
+ 'top_opt_shortest_key' =>'',
2345
+ 'top_opt_googl_key' =>'',
2346
+ 'top_opt_owly_key' =>'',
2347
+ 'top_opt_tweet_multiple_times' => 'on',
2348
+ 'rop_opt_cat_filter' => 'exclude',
2349
  // Added by Ash/Upwork
2350
  );
2351
 
2533
  $post_types["post"] = get_post_type_object( 'post' );
2534
  $post_types["page"] = get_post_type_object( 'page' );
2535
 
2536
+ $taxonomies = array();
2537
  foreach($post_types as $pt=>$pd){
2538
  foreach($taxs as $tx){
2539
 
2545
 
2546
  ) );
2547
  if(!empty($terms)){
2548
+ // Added by Ash/Upwork
2549
+ $options = array();
2550
  foreach ($terms as $t) {
2551
+ $options[$t->name] = $t->term_id;
2552
+ }
2553
+ $taxonomies[$tx->labels->name] = $options;
2554
+ // Added by Ash/Upwork
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2555
  }
 
2556
  }
 
2557
  }
 
2558
  }
2559
 
2560
+ // Added by Ash/Upwork
2561
+ ob_start();
2562
+ include_once ROPPLUGINPATH . "/inc/view-categories-list.php";
2563
+ echo ob_get_clean();
2564
+ // Added by Ash/Upwork
2565
 
2566
  break;
2567
 
2712
  set_transient( 'rop_remote_calls', "done", 24 * HOUR_IN_SECONDS );
2713
  }
2714
  if(!defined("VERSION_CHECK") && function_exists('topProImage')){
2715
+ $this->notices[] = "You need to have the latest version of the Revive Old Post Pro addon in order to use it. Please download it from the revive.social account";
2716
 
2717
  }
2718
  $all = $this->getAllNetworks();
3112
  if(isset($_GET['page'])) {
3113
  if ($_GET['page'] == $cwp_top_settings['slug'] || $_GET['page'] == "ExcludePosts") {
3114
 
3115
+ // Added by Ash/Upwork
3116
+ wp_enqueue_script("jquery");
3117
+ wp_enqueue_script("jquery-ui-button");
3118
+ wp_register_script("jquery.chosen", ROP_ROOT . "js/chosen.jquery.min.js", array("jquery"), time(), true);
3119
+ wp_enqueue_script("jquery.chosen");
3120
+ wp_register_style("jquery.chosen", ROP_ROOT . "css/chosen.min.css", array(), time());
3121
+ wp_enqueue_style("jquery.chosen");
3122
+ wp_register_style("jquery.ui-smoothness", "//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css");
3123
+ wp_enqueue_style("jquery.ui-smoothness");
3124
+ // Added by Ash/Upwork
3125
+
3126
+ // Enqueue and Register Main CSS File
3127
+ wp_register_style( 'cwp_top_stylesheet', ROPCSSFILE, array("jquery.chosen"), time());
3128
  wp_enqueue_style( 'cwp_top_stylesheet' );
3129
 
3130
  // Register Main JS File
3226
  require_once(plugin_dir_path( __FILE__ )."view.php");
3227
  }
3228
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3229
  // Shortens the url.
3230
+ public static function shortenURL($url, $service, $id, $formats, $network, $showPlaceholder=false) {
3231
  // Added by Ash/Upwork
3232
  if ($showPlaceholder) {
3233
  return "[$service]";
3234
  }
3235
  // Added by Ash/Upwork
3236
+ if (ROP_IS_TEST) {
3237
+ $url = "http://www.google.com/" . time();
3238
+ }
3239
+
3240
+ $shortURL = trim($url);
3241
+ $url = urlencode($shortURL);
3242
+ switch ($service) {
3243
+ case "bit.ly":
3244
+ $key = trim(isset($formats[$network."_"."top_opt_bitly_key"]) ? $formats[$network."_"."top_opt_bitly_key"] : get_option( 'top_opt_bitly_key' ));
3245
+ $user = trim(isset($formats[$network."_"."top_opt_bitly_user"]) ? $formats[$network."_"."top_opt_bitly_user"] : get_option( 'top_opt_bitly_user' ));
3246
+ $response = self::callAPI(
3247
+ "http://api.bit.ly/v3/shorten",
3248
+ array("method" => "get"),
3249
+ array("longUrl" => $url, "format" => "txt", "login" => $user, "apiKey" => $key),
3250
+ null
3251
+ );
3252
+
3253
+ if (intval($response["error"]) == 200) {
3254
+ $shortURL = $response["response"];
3255
+ }
3256
+ break;
3257
+ case "shorte.st":
3258
+ $key = trim(isset($formats[$network."_"."top_opt_shortest_key"]) ? $formats[$network."_"."top_opt_shortest_key"] : get_option( 'top_opt_shortest_key' ));
3259
+ $response = self::callAPI(
3260
+ "https://api.shorte.st/v1/data/url",
3261
+ array("method" => "put", "json" => true),
3262
+ array("urlToShorten" => $url),
3263
+ array("public-api-token" => $key)
3264
+ );
3265
+
3266
+ if (intval($response["error"]) == 200 && $response["response"]["status"] == "ok") {
3267
+ $shortURL = $response["response"]["shortenedUrl"];
3268
+ }
3269
+ break;
3270
+ case "goo.gl":
3271
+ $key = trim(isset($formats[$network."_"."top_opt_googl_key"]) ? $formats[$network."_"."top_opt_googl_key"] : get_option( 'top_opt_googl_key' ));
3272
+ $response = self::callAPI(
3273
+ "https://www.googleapis.com/urlshortener/v1/url?key=" . $key,
3274
+ array("method" => "json", "json" => true),
3275
+ array("longUrl" => urldecode($url)),
3276
+ array("Content-Type" => "application/json")
3277
+ );
3278
+
3279
+ if (intval($response["error"]) == 200 && !isset($response["response"]["error"])) {
3280
+ $shortURL = $response["response"]["id"];
3281
+ }
3282
+ break;
3283
+ case "ow.ly":
3284
+ $key = trim(isset($formats[$network."_"."top_opt_owly_key"]) ? $formats[$network."_"."top_opt_owly_key"] : get_option( 'top_opt_owly_key' ));
3285
+ $response = self::callAPI(
3286
+ "http://ow.ly/api/1.1/url/shorten",
3287
+ array("method" => "get", "json" => true),
3288
+ array("longUrl" => $url, "apiKey" => $key),
3289
+ null
3290
+ );
3291
+
3292
+ if (intval($response["error"]) == 200 && !isset($response["response"]["error"])) {
3293
+ $shortURL = $response["response"]["results"]["shortUrl"];
3294
+ }
3295
+ break;
3296
+ case "is.gd":
3297
+ $response = self::callAPI(
3298
+ "https://is.gd/api.php",
3299
+ array("method" => "get"),
3300
+ array("longurl" => $url),
3301
+ null
3302
+ );
3303
+
3304
+ if (intval($response["error"]) == 200) {
3305
+ $shortURL = $response["response"];
3306
+ }
3307
+ break;
3308
+ default:
3309
+ $shortURL = wp_get_shortlink($id);
3310
+ break;
3311
  }
3312
  if($shortURL != ' 400 '&& $shortURL!="500" && $shortURL!="0") {
3313
  return $shortURL;
3323
 
3324
  }
3325
 
3326
+ private static function callAPI($url, $props=array(), $params=array(), $headers=array())
3327
+ {
3328
+ $body = null;
3329
+ $error = null;
3330
+ if ($props && isset($props["method"]) && $props["method"] === "get") {
3331
+ $url .= "?";
3332
+ foreach ($params as $k=>$v) {
3333
+ $url .= "$k=$v&";
3334
+ }
3335
+ }
3336
+ $conn = curl_init($url);
3337
+
3338
+ curl_setopt($conn, CURLOPT_SSL_VERIFYPEER, false);
3339
+ curl_setopt($conn, CURLOPT_FRESH_CONNECT, true);
3340
+ curl_setopt($conn, CURLOPT_RETURNTRANSFER, 1);
3341
+ curl_setopt($conn, CURLOPT_FOLLOWLOCATION, 1);
3342
+ curl_setopt($conn, CURLOPT_HEADER, 0);
3343
+ curl_setopt($conn, CURLOPT_NOSIGNAL, 1);
3344
+
3345
+ if ($headers) {
3346
+ $header = array();
3347
+ foreach ($headers as $key=>$val) {
3348
+ $header[] = "$key: $val";
3349
+ }
3350
+ curl_setopt($conn, CURLOPT_HTTPHEADER, $header);
3351
+ }
3352
+
3353
+ if ($props && isset($props["method"])) {
3354
+ if (in_array($props["method"], array("post", "put"))) {
3355
+ curl_setopt($conn, CURLOPT_POSTFIELDS, urldecode(http_build_query($params)));
3356
+ }
3357
+
3358
+ if ($props["method"] === "json") {
3359
+ curl_setopt($conn, CURLOPT_POSTFIELDS, json_encode($params));
3360
+ }
3361
+
3362
+ if (!in_array($props["method"], array("get", "post", "json"))) {
3363
+ curl_setopt($conn, CURLOPT_CUSTOMREQUEST, strtoupper($props["method"]));
3364
+ }
3365
+ }
3366
+
3367
+ try {
3368
+ $body = curl_exec($conn);
3369
+ $error = curl_getinfo($conn, CURLINFO_HTTP_CODE);
3370
+ } catch (Exception $e) {
3371
+ self::writeDebug("Exception " . $e->getMessage());
3372
+ }
3373
+
3374
+ if (curl_errno($conn)) {
3375
+ self::addNotice("Error for request: " . $url . " : ". curl_error($conn), 'error');
3376
+ self::writeDebug("curl_errno ".curl_error($conn));
3377
+ }
3378
+
3379
+ curl_close($conn);
3380
+
3381
+ if ($props && isset($props["json"]) && $props["json"]) {
3382
+ $body = json_decode($body, true);
3383
+ }
3384
+
3385
+ $array = array(
3386
+ "response" => $body,
3387
+ "error" => $error,
3388
+ );
3389
+
3390
+ self::writeDebug("Calling ". $url. " with headers = " . print_r($header, true) . ", fields = " . print_r($params, true) . " returning raw response " . print_r($body,true) . " and finally returning " . print_r($array,true));
3391
+
3392
+ return $array;
3393
+ }
3394
+
3395
+ public static function writeDebug($msg)
3396
+ {
3397
+ if (ROP_IS_DEBUG) file_put_contents(ROPPLUGINPATH . "/tmp/log.log", date("F j, Y H:i:s", current_time("timestamp")) . " - " . $msg."\n", FILE_APPEND);
3398
+ }
3399
+
3400
+
3401
  }
3402
  }
3403
 
inc/view-advancedscheduling.php CHANGED
@@ -1,6 +1,7 @@
1
  <?php
2
  $cfgnets = $this->getAllNetworks(true);
3
  $available = $this->getAvailableNetworks();
 
4
  ?>
5
  <div class="cwp_top_tabs_vertical <?php echo (count($available) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?> ">
6
  <?php
1
  <?php
2
  $cfgnets = $this->getAllNetworks(true);
3
  $available = $this->getAvailableNetworks();
4
+ if(empty($available)) $available[] = "twitter";
5
  ?>
6
  <div class="cwp_top_tabs_vertical <?php echo (count($available) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?> ">
7
  <?php
inc/view-categories-list.php ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ if (!is_array(get_option('top_opt_omit_cats'))) {
4
+ $top_opt_omit_specific_cats = explode(',',get_option('top_opt_omit_cats'));
5
+ } else {
6
+ $top_opt_omit_specific_cats = get_option('top_opt_omit_cats');
7
+ }
8
+
9
+ $filterType = get_option("top_opt_cat_filter", "exclude");
10
+ ?>
11
+
12
+ <div id="top_exc_inc_radio">
13
+ <input type="radio" name="top_opt_cat_filter" value="exclude" <?php echo $filterType == "exclude" ? "checked" : ""?> id="top_opt_category_exclude"><label for="top_opt_category_exclude"><?php _e("Exclude", "tweet-old-post");?></label>
14
+ <input type="radio" name="top_opt_cat_filter" value="include" <?php echo $filterType == "include" ? "checked" : ""?> id="top_opt_category_include"><label for="top_opt_category_include"><?php _e("Include", "tweet-old-post");?></label>
15
+ </div>
16
+ <select name="<?php echo $field['option'];?>[]" data-placeholder="<?php _e("Categories", "tweet-old-post");?>" class="top-chosen-select" multiple>
17
+ <option value=""></option>
18
+ <?php
19
+ foreach ($taxonomies as $type=>$options) {
20
+ ?>
21
+ <optgroup label="<?php echo $type?>">
22
+ <?php
23
+ foreach ($options as $label=>$id) {
24
+ $extra = in_array($id, $top_opt_omit_specific_cats) ? "selected" : "";
25
+ ?>
26
+ <option value="<?php echo $id;?>" <?php echo $extra;?>><?php echo $label;?></option>
27
+ <?php
28
+ }
29
+ ?>
30
+ </optgroup>
31
+ <?php
32
+ }
33
+ ?>
34
+ </select>
35
+ <div class="clear"></div>
inc/view-exclude.php CHANGED
@@ -1,9 +1,5 @@
1
  <?php $twp_obj = new CWP_TOP_Core; ?>
2
  <div class="cwp_top_wrapper_full cwp_top_wrapper">
3
- <div class="announcement clearfix">
4
- <h2><?php _e("After 6 months of hard work, we have just released", 'tweet-old-post'); ?> <b>ThemeIsle</b>, <?php _e("the island of WordPress themes.", 'tweet-old-post'); ?></h2>
5
- <a class="show-me" href="https://themeisle.com/?utm_source=topadmin&utm_medium=announce&utm_campaign=top"><?php _e("Show Me", 'tweet-old-post'); ?></a>
6
- </div><!-- end .announcement -->
7
 
8
  <header id="cwp_top_header" class='clearfix'>
9
  <h1 class="top-logo" style="float:left">
@@ -12,10 +8,10 @@
12
  } else echo "Revive Old Post"; ?>
13
 
14
  </h1>
15
- <span class="slogan"><?php _e("by", 'tweet-old-post'); ?> <a href="https://themeisle.com/?utm_source=topadmin&utm_medium=announce&utm_campaign=top">ThemeIsle</a></span>
16
 
17
  <div class="cwp_top_actions">
18
- <a href="https://twitter.com/intent/tweet?text=Check-out%20this%20awesome%20plugin%20-%20&url=http%3A%2F%2Fthemeisle.com%2Fplugins%2Ftweet-old-post-lite%2F&via=themeisle" class="tweet-about-it"><span></span> <?php _e("Show your love", 'tweet-old-post'); ?></a>
19
  <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/tweet-old-post#postform" class="leave-a-review"><span></span> <?php _e("Leave A Review", 'tweet-old-post'); ?></a>
20
  </div><!-- end .cwp_top_actions -->
21
  </header><!-- end .cwp_top_header -->
1
  <?php $twp_obj = new CWP_TOP_Core; ?>
2
  <div class="cwp_top_wrapper_full cwp_top_wrapper">
 
 
 
 
3
 
4
  <header id="cwp_top_header" class='clearfix'>
5
  <h1 class="top-logo" style="float:left">
8
  } else echo "Revive Old Post"; ?>
9
 
10
  </h1>
11
+ <span class="slogan"><?php _e("by", 'tweet-old-post'); ?> <a href="https://revive.social/?utm_source=topadmin&utm_medium=announce&utm_campaign=top">ReviveSocial</a></span>
12
 
13
  <div class="cwp_top_actions">
14
+ <a href="https://twitter.com/intent/tweet?text=Check-out%20this%20awesome%20plugin%20-%20&url=http%3A%2F%2Frevive.social%2Fplugins%2Frevive-old-post%2F&via=ReviveSocial" class="tweet-about-it"><span></span> <?php _e("Show your love", 'tweet-old-post'); ?></a>
15
  <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/tweet-old-post#postform" class="leave-a-review"><span></span> <?php _e("Leave A Review", 'tweet-old-post'); ?></a>
16
  </div><!-- end .cwp_top_actions -->
17
  </header><!-- end .cwp_top_header -->
inc/view-postformat.php CHANGED
@@ -2,6 +2,7 @@
2
  global $cwp_global_schedule;
3
  $cfgnets = $this->getAllNetworks(true);
4
  $networks = $this->getAvailableNetworks();
 
5
  ?><div class="cwp_top_tabs_vertical <?php echo (count($networks) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?>" >
6
  <?php if(count($networks) > 1): ?>
7
  <ul class="cwp_top_tabs_btns">
@@ -25,11 +26,6 @@
25
  <span class="description"> <?php _e( $field['description'], 'tweet-old-post' ); ?> <?php if($field['type'] == 'number'):
26
  ?>(<?php _e("Max",'tweet-old-post'); ?>: <?php echo $field['max-length']; ?>)<?php
27
  endif;?> </span>
28
-
29
- <?php if($field['type'] == 'categories-list') { ?>
30
- <button class='select-all'><?php _e( "Select All", 'tweet-old-post' );?></button>
31
- <?php } ?>
32
-
33
  </div><!-- end .left -->
34
  <div class="right">
35
  <?php CWP_TOP_Core::generateFieldType( $field ); ?>
2
  global $cwp_global_schedule;
3
  $cfgnets = $this->getAllNetworks(true);
4
  $networks = $this->getAvailableNetworks();
5
+ if(empty($networks))$networks[] = "twitter";
6
  ?><div class="cwp_top_tabs_vertical <?php echo (count($networks) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?>" >
7
  <?php if(count($networks) > 1): ?>
8
  <ul class="cwp_top_tabs_btns">
26
  <span class="description"> <?php _e( $field['description'], 'tweet-old-post' ); ?> <?php if($field['type'] == 'number'):
27
  ?>(<?php _e("Max",'tweet-old-post'); ?>: <?php echo $field['max-length']; ?>)<?php
28
  endif;?> </span>
 
 
 
 
 
29
  </div><!-- end .left -->
30
  <div class="right">
31
  <?php CWP_TOP_Core::generateFieldType( $field ); ?>
inc/view-postschedule.php CHANGED
@@ -1,6 +1,7 @@
1
  <?php
2
  global $cwp_top_global_schedule;
3
  $networks = $this->getAvailableNetworks();
 
4
  ?>
5
  <div class="cwp_top_tabs_vertical <?php echo (count($networks) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?> ">
6
  <?php if(count($networks) > 1) : ?>
1
  <?php
2
  global $cwp_top_global_schedule;
3
  $networks = $this->getAvailableNetworks();
4
+ if(empty($networks))$networks[] = "twitter";
5
  ?>
6
  <div class="cwp_top_tabs_vertical <?php echo (count($networks) > 1) ? "rop-tab-with-sidebar" : "rop-tab-full-width"; ?> ">
7
  <?php if(count($networks) > 1) : ?>
inc/view.php CHANGED
@@ -10,10 +10,7 @@
10
 
11
  </script>
12
  <div class="cwp_top_wrapper">
13
- <!--<div class="announcement clearfix">
14
- <h2><?php _e("After 6 months of hard work, we have just released", 'tweet-old-post'); ?> <b>ThemeIsle</b>, <?php _e("the island of WordPress themes.", 'tweet-old-post'); ?></h2>
15
- <a class="show-me" href="https://themeisle.com/?utm_source=topadmin&utm_medium=announce&utm_campaign=top"><?php _e("Show Me", 'tweet-old-post'); ?></a>
16
- </div> end .announcement -->
17
 
18
  <header id="cwp_top_header" class='clearfix'>
19
  <h1 class="top_logo">
@@ -22,11 +19,11 @@
22
  } else echo "Revive Old Post"; ?>
23
 
24
  </h1>
25
- <span class="slogan"><?php _e("by", 'tweet-old-post'); ?> <a href="https://themeisle.com/?utm_source=topadmin&utm_medium=announce&utm_campaign=top">ThemeIsle</a></span>
26
 
27
  <div class="cwp_top_actions">
28
 
29
- <a href="https://twitter.com/intent/tweet?text=Check-out%20this%20awesome%20plugin%20-%20&url=http%3A%2F%2Fthemeisle.com%2Fplugins%2Ftweet-old-post-lite%2F&via=themeisle" class="tweet-about-it"><span></span> <?php _e("Show your love", 'tweet-old-post'); ?></a>
30
  <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/tweet-old-post#postform" class="leave-a-review"><span></span> <?php _e("Leave A Review", 'tweet-old-post'); ?></a>
31
  </div><!-- end .cwp_top_actions -->
32
  </header><!-- end .cwp_top_header -->
@@ -91,11 +88,6 @@
91
  <div class="left">
92
  <label for="<?php echo $field['option']; ?>"> <?php _e($field['name'],'tweet-old-post'); ?> </label>
93
  <span class="description"> <?php _e($field['description'],'tweet-old-post'); ?> </span>
94
-
95
- <?php if($field['type'] == 'categories-list') { ?>
96
- <button class='select-all'><?php _e("Select All",'tweet-old-post');?></button>
97
- <?php } ?>
98
-
99
  </div><!-- end .left -->
100
  <div class="right">
101
  <?php CWP_TOP_Core::generateFieldType( $field ); ?>
@@ -151,7 +143,7 @@
151
  <?php endif; ?>
152
  <li class="rop-beta-user"><div class="rop-left"><?php _e("Beta user",'tweet-old-post');?> </div><a href="#" id="rop-beta-button" class="rop-right <?php echo $beta_user; ?>"></a><div class="rop-clear" ></div><span class="rop-beta-desc"><?php _e("As a beta user you will have access to the latest stable releases before going to production",'tweet-old-post');?></span></li>
153
  <li class="rop-beta-user"><div class="rop-left"><?php _e("Remote check",'tweet-old-post');?></div><a href="#" id="cwp_remote_check" class="<?php echo $remote_check; ?> rop-right "></a><div class="rop-clear" ></div><span class="rop-beta-desc"><?php _e("We will send you a ping each 15 minutes in order to assure that posts will be sent to social networks on time. ",'tweet-old-post');?> </span> </li>
154
- <li class="upgrade"><a target="_blank" href="https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=bannerright&utm_medium=announce&utm_campaign=top&upgrade=true"> <?php _e("Upgrade Tweet Old Post for only $9.99 - Upgrade To Pro Now!", 'tweet-old-post'); ?></a></li>
155
 
156
  </ul>
157
  </aside><!-- end .sidebar -->
@@ -188,16 +180,18 @@
188
  <span class="sample_tweet top_sample_auth">
189
  <div class="top_left_instructions">
190
  <ol>
191
- <li><?php _e('Go on','tweet-old-post');?> <a href="https://developers.facebook.com/apps/" target="_blank">developers.facebook.com/apps</a> </li>
192
- <li><?php _e('Click on <strong>Create New App</strong> from the top right corner','tweet-old-post');?> </li>
193
- <li><?php _e('Enter a <strong>Display Name</strong> and <strong>Namespace</strong> and click on Create App','tweet-old-post');?> </li>
194
- <li><?php _e('Once you arrive on the app dashboard, copy your <strong>App ID</strong> and <strong>App Secret</strong> in the fields on the right','tweet-old-post');?> </li>
195
- <li><?php _e('Go on Settings tab from the left sidebar menu add the contact email and click on <strong>Add Platform</strong> and select <strong>Website</strong>','tweet-old-post');?> </li>
196
- <li><?php printf(__('Copy/Paste this url : <strong>%s</strong> into App Domains and Site URL fields and <strong>Save</strong>','tweet-old-post'),top_settings_url());?> </li>
197
- <li><?php _e('Go on Status & Review tab and set your app live from the top-right switch.','tweet-old-post');?> </li>
198
- <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?> </li>
 
 
199
  </ol>
200
- <h3><?php _e('You can follow this <a target="_blank" href="http://docs.themeisle.com/article/66-how-to-create-a-facebook-application" > tutorial</a> for more detailed instructions','tweet-old-post'); ?></h3>
201
  </div>
202
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
203
  <fieldset class="option twptop_opt_app_id">
@@ -231,7 +225,7 @@
231
 
232
  <div class="cwp_not_version_preview">
233
  <div class="cwp_sample_tweet_preview_inner top_auth_inner">
234
- <h2><?php _e('You need to have the latest version of Revive Old Post Pro in order to use this feature. Please update it or download for your account here <a href="https://themeisle.com/purchase-history" target="_blank">https://themeisle.com/purchase-history</a>','tweet-old-post');?></h2>
235
 
236
  </span><button class="top_close_popup"><?php _e('Close','tweet-old-post');?></button>
237
  </div><!-- end .cwp_sample_tweet_preview_inner -->
@@ -243,23 +237,21 @@
243
  <span class="sample_tweet top_sample_auth">
244
  <div class="top_left_instructions">
245
  <ol>
246
- <li><?php _e('Go on','tweet-old-post');?> <a href="https://www.linkedin.com/secure/developer?newapp=" target="_blank">linkedin.com/secure/developer?newapp=</a></li>
247
- <li><?php _e('Enter the required details and pay special attention to the further fields :','tweet-old-post');?></li>
248
- <li><?php _e('Make sure you set Live Status to LIVE','tweet-old-post');?> </li>
249
- <li><?php _e('Default Scope should have r_basicprofile and w_share checked','tweet-old-post');?></li>
250
- <li><?php printf(__('Copy/Paste this url : <strong>%s</strong> into OAuth 2.0 Redirect URLs field and <strong>Save</strong>','tweet-old-post'),top_settings_url());?> </li>
251
- <li><?php _e('Once all required fields are filled click on Add Application button, get the API Key and Secret Key and paste them in the fields on the right','tweet-old-post');?></li>
252
-
253
- <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?></li>
254
  </ol>
 
255
  </div>
256
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
257
  <fieldset class="option twptop_opt_app_id">
258
  <div class="left">
259
  <label for="top_opt_app_id"><?php _e('Linkedin API Key','tweet-old-post');?> </label>
260
  <span class="description"><?php _e('API Key that you get once you create an app','tweet-old-post');?> </span>
261
-
262
-
263
  </div><!-- end .left -->
264
  <div class="right">
265
  <input type="text" placeholder="1487991504767913" value="<?php get_option('cwp_top_lk_app_id');?>" name="top_opt_app_id" id="top_opt_app_id_lk">
@@ -290,12 +282,12 @@
290
  <span class="sample_tweet top_sample_auth">
291
  <div class="top_left_instructions">
292
  <ol>
293
- <li><?php _e('Go on','tweet-old-post');?> <a href="https://dev.xing.com/applications/dashboard" target="_blank"> https://dev.xing.com/applications/dashboard</a></li>
294
- <li><?php _e('If you already made an application you will see it’s info here, otherwise click “Create app” button.','tweet-old-post');?></li>
295
- <li><?php _e("Fill 'Application Name', click 'Save'",'tweet-old-post');?> </li>
296
- <li><?php printf(__('Copy/Paste the Consumer Key and Consumer Secret in the fields from the right. ','tweet-old-post'),top_settings_url());?> </li>
297
 
298
- <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?></li>
299
  </ol>
300
  </div>
301
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
@@ -334,11 +326,11 @@
334
  <span class="sample_tweet top_sample_auth">
335
  <div class="top_left_instructions">
336
  <ol>
337
- <li><?php _e('Go on','tweet-old-post');?> <a href="https://www.tumblr.com/oauth/apps" target="_blank"> https://www.tumblr.com/oauth/apps</a></li>
338
- <li><?php _e('If you already made an application you will see it’s info here, otherwise click “Register application” button.','tweet-old-post');?></li>
339
- <li><?php _e("Click 'Register application'”' button. Fill 'Application Name', 'Application Website', all other fields (just enter your website URL to the 'Default callback URL') and click Register'.",'tweet-old-post');?> </li>
340
- <li><?php printf(__('Copy/Paste the Consumer Key and Consumer Secret in the fields from the right. ','tweet-old-post'),top_settings_url());?> </li>
341
- <li><?php printf(__('Fill URL of your Tumblr Blog. ','tweet-old-post'));?> </li>
342
 
343
  <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?></li>
344
  </ol>
10
 
11
  </script>
12
  <div class="cwp_top_wrapper">
13
+
 
 
 
14
 
15
  <header id="cwp_top_header" class='clearfix'>
16
  <h1 class="top_logo">
19
  } else echo "Revive Old Post"; ?>
20
 
21
  </h1>
22
+ <span class="slogan"><?php _e("by", 'tweet-old-post'); ?> <a href="https://revive.social/?utm_source=topadmin&utm_medium=announce&utm_campaign=top">ReviveSocial</a></span>
23
 
24
  <div class="cwp_top_actions">
25
 
26
+ <a href="https://twitter.com/intent/tweet?text=Check-out%20this%20awesome%20plugin%20-%20&url=http%3A%2F%2Frevive.social%2Fplugins%2Frevive-old-post%2F&via=ReviveSocial" class="tweet-about-it"><span></span> <?php _e("Show your love", 'tweet-old-post'); ?></a>
27
  <a target="_blank" href="http://wordpress.org/support/view/plugin-reviews/tweet-old-post#postform" class="leave-a-review"><span></span> <?php _e("Leave A Review", 'tweet-old-post'); ?></a>
28
  </div><!-- end .cwp_top_actions -->
29
  </header><!-- end .cwp_top_header -->
88
  <div class="left">
89
  <label for="<?php echo $field['option']; ?>"> <?php _e($field['name'],'tweet-old-post'); ?> </label>
90
  <span class="description"> <?php _e($field['description'],'tweet-old-post'); ?> </span>
 
 
 
 
 
91
  </div><!-- end .left -->
92
  <div class="right">
93
  <?php CWP_TOP_Core::generateFieldType( $field ); ?>
143
  <?php endif; ?>
144
  <li class="rop-beta-user"><div class="rop-left"><?php _e("Beta user",'tweet-old-post');?> </div><a href="#" id="rop-beta-button" class="rop-right <?php echo $beta_user; ?>"></a><div class="rop-clear" ></div><span class="rop-beta-desc"><?php _e("As a beta user you will have access to the latest stable releases before going to production",'tweet-old-post');?></span></li>
145
  <li class="rop-beta-user"><div class="rop-left"><?php _e("Remote check",'tweet-old-post');?></div><a href="#" id="cwp_remote_check" class="<?php echo $remote_check; ?> rop-right "></a><div class="rop-clear" ></div><span class="rop-beta-desc"><?php _e("We will send you a ping each 15 minutes in order to assure that posts will be sent to social networks on time. ",'tweet-old-post');?> </span> </li>
146
+ <li class="upgrade"><a target="_blank" href="https://revive.social/plugins/revive-old-post/?utm_source=bannerright&utm_medium=announce&utm_campaign=top&upgrade=true"> <?php _e("Upgrade Tweet Old Post for only $9.99 - Upgrade To Pro Now!", 'tweet-old-post'); ?></a></li>
147
 
148
  </ul>
149
  </aside><!-- end .sidebar -->
180
  <span class="sample_tweet top_sample_auth">
181
  <div class="top_left_instructions">
182
  <ol>
183
+ <li><?php _e('Go to','tweet-old-post');?> <a href="https://developers.facebook.com/apps/" target="_blank">developers.facebook.com/apps</a> </li>
184
+ <li><?php _e('Click on <strong>Create New App</strong> from the top right corner.','tweet-old-post');?> </li>
185
+ <li><?php _e('Enter a <strong>Display Name</strong>, <strong>Namespace</strong>, <strong>Contact Email</strong>, <strong>Category</strong> and click on Create App ID.','tweet-old-post');?> </li>
186
+ <li><?php _e('After you prove you are human and the page loads go to <strong>Dashboard</strong>, copy your <strong>App ID</strong> and <strong>App Secret</strong> in the fields on the right.','tweet-old-post');?> </li>
187
+ <li><?php _e('Go back to the app dashboard and next to <strong>Get Started with the Facebook SDK</strong> click <strong>Choose a Platform</strong>.','tweet-old-post');?> </li>
188
+ <li><?php printf(__('Select <strong>Website</strong> from the options, when the page loads scroll down and copy the following URL into the <strong>Site URL</strong> area: <code>%s</code> then click <strong>Next</strong>','tweet-old-post'),top_settings_url());?> </li>
189
+ <li><?php _e('When the new page loads click <strong>Skip Quick Start</strong> to the top right" then go to <strong>Settings</strong>','tweet-old-post');?> </li>
190
+ <li><?php printf(__('In the <strong>App Domains</strong> area paste the following URL: <code>%s</code> then scroll down and click <strong>Save changes</strong>','tweet-old-post'),top_settings_url());?> </li>
191
+ <li><?php _e('Go to <strong>App Review</strong> and turn the switch asking to make your app public to "Yes" and click continue','tweet-old-post');?> </li>
192
+ <li><?php _e('Now everything is almost done, click on <strong>Authorize App</strong> button to the right of this screen, a new page will open asking you to continue as yourself, click <strong>Okay</strong>, the next page will ask you who you want the posts to be shared with, select <strong>Public</strong> if you want everyone to see the shared posts.','tweet-old-post');?> </li>
193
  </ol>
194
+ <h4 class="video-tutorial-link"><?php _e('<a target="_blank" href="http://docs.revive.social/article/349-how-to-create-a-facebook-application-for-revive-old-post">Click here</a> for a video showing these instructions','tweet-old-post'); ?></h4>
195
  </div>
196
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
197
  <fieldset class="option twptop_opt_app_id">
225
 
226
  <div class="cwp_not_version_preview">
227
  <div class="cwp_sample_tweet_preview_inner top_auth_inner">
228
+ <h2><?php _e('You need to have the latest version of Revive Old Post Pro in order to use this feature. Please update it or download for your account here <a href="http://revive.social/your-purchases/" target="_blank">http://revive.social/your-purchases/</a>','tweet-old-post');?></h2>
229
 
230
  </span><button class="top_close_popup"><?php _e('Close','tweet-old-post');?></button>
231
  </div><!-- end .cwp_sample_tweet_preview_inner -->
237
  <span class="sample_tweet top_sample_auth">
238
  <div class="top_left_instructions">
239
  <ol>
240
+ <li><?php _e('Go to','tweet-old-post');?> <a href="https://www.linkedin.com/secure/developer?newapp=" target="_blank">linkedin.com/secure/developer?newapp=</a> and click <strong>Create Application</strong>.</li><br>
241
+ <li><?php _e('Enter the required details for your application, be sure to add this current website\'s URL inside the <strong>Website URL</strong> field, click <strong>Submit</strong> when done.','tweet-old-post');?></li><br>
242
+ <li><?php _e('Set the <strong>Default Application Permissions</strong> to r_basicprofile and w_share.','tweet-old-post');?></li><br>
243
+ <li><?php printf(__('Copy/Paste this url : <code>%s</code> into OAuth 2.0 Redirect URLs field, click <strong>Add</strong> and then <strong>Update</strong>','tweet-old-post'),top_settings_url());?> </li><br>
244
+ <li><?php _e('To the top left of the LinkedIn page select <strong>Settings</strong>, under <strong>Application Status</strong> set it to <strong>Live</strong> and click <strong>Update</strong> to save your changes.','tweet-old-post');?></li><br>
245
+ <li><?php _e('Go back to <strong>Authentication</strong> page, copy the <strong>Client ID</strong> and <strong>Client Secret</strong> and paste them in the fields on the right of this page then click <strong>Authorize APP</strong>','tweet-old-post');?></li><br>
246
+ <li><?php _e('A new page will open up asking you to grant access by logging in, enter your login credentials then click <strong>Allow access</strong>. Your application should now be connected and ready to share','tweet-old-post');?></li>
 
247
  </ol>
248
+ <h4 class ="video-tutorial-link"><?php _e('<a target="_blank" href="http://docs.revive.social/article/406-how-to-create-a-linkedin-app-for-revive-old-post" >Click here</a> for a video showing these instructions','tweet-old-post'); ?></h4>
249
  </div>
250
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
251
  <fieldset class="option twptop_opt_app_id">
252
  <div class="left">
253
  <label for="top_opt_app_id"><?php _e('Linkedin API Key','tweet-old-post');?> </label>
254
  <span class="description"><?php _e('API Key that you get once you create an app','tweet-old-post');?> </span>
 
 
255
  </div><!-- end .left -->
256
  <div class="right">
257
  <input type="text" placeholder="1487991504767913" value="<?php get_option('cwp_top_lk_app_id');?>" name="top_opt_app_id" id="top_opt_app_id_lk">
282
  <span class="sample_tweet top_sample_auth">
283
  <div class="top_left_instructions">
284
  <ol>
285
+ <li><?php _e('Go on','tweet-old-post');?> <a href="https://dev.xing.com/applications/dashboard" target="_blank"> https://dev.xing.com/applications/dashboard</a></li><br>
286
+ <li><?php _e('If you already made an application you will see it’s info here, otherwise click “Create app” button.','tweet-old-post');?></li><br>
287
+ <li><?php _e("Fill 'Application Name', click 'Save'",'tweet-old-post');?> </li><br>
288
+ <li><?php printf(__('Copy/Paste the Consumer Key and Consumer Secret in the fields from the right. ','tweet-old-post'),top_settings_url());?> </li><br>
289
 
290
+ <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?></li><br>
291
  </ol>
292
  </div>
293
  <form action="" method="post" id="cwp_top_form" class=" top_auth_form">
326
  <span class="sample_tweet top_sample_auth">
327
  <div class="top_left_instructions">
328
  <ol>
329
+ <li><?php _e('Go on','tweet-old-post');?> <a href="https://www.tumblr.com/oauth/apps" target="_blank"> https://www.tumblr.com/oauth/apps</a></li><br>
330
+ <li><?php _e('If you already made an application you will see it’s info here, otherwise click “Register application” button.','tweet-old-post');?></li><br>
331
+ <li><?php _e("Click 'Register application'”' button. Fill 'Application Name', 'Application Website', all other fields (just enter your website URL to the 'Default callback URL') and click Register'.",'tweet-old-post');?> </li><br>
332
+ <li><?php printf(__('Copy/Paste the Consumer Key and Consumer Secret in the fields from the right. ','tweet-old-post'),top_settings_url());?> </li><br>
333
+ <li><?php printf(__('Fill URL of your Tumblr Blog. ','tweet-old-post'));?> </li><br>
334
 
335
  <li><?php _e('Now everything is done, click on <strong>Authorize App</strong> button.','tweet-old-post');?></li>
336
  </ol>
js/chosen.jquery.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Chosen v1.5.1 | (c) 2011-2016 by Harvest | MIT License, https://github.com/harvesthq/chosen/blob/master/LICENSE.md */
2
+ (function(){var a,AbstractChosen,Chosen,SelectParser,b,c={}.hasOwnProperty,d=function(a,b){function d(){this.constructor=a}for(var e in b)c.call(b,e)&&(a[e]=b[e]);return d.prototype=b.prototype,a.prototype=new d,a.__super__=b.prototype,a};SelectParser=function(){function SelectParser(){this.options_index=0,this.parsed=[]}return SelectParser.prototype.add_node=function(a){return"OPTGROUP"===a.nodeName.toUpperCase()?this.add_group(a):this.add_option(a)},SelectParser.prototype.add_group=function(a){var b,c,d,e,f,g;for(b=this.parsed.length,this.parsed.push({array_index:b,group:!0,label:this.escapeExpression(a.label),title:a.title?a.title:void 0,children:0,disabled:a.disabled,classes:a.className}),f=a.childNodes,g=[],d=0,e=f.length;e>d;d++)c=f[d],g.push(this.add_option(c,b,a.disabled));return g},SelectParser.prototype.add_option=function(a,b,c){return"OPTION"===a.nodeName.toUpperCase()?(""!==a.text?(null!=b&&(this.parsed[b].children+=1),this.parsed.push({array_index:this.parsed.length,options_index:this.options_index,value:a.value,text:a.text,html:a.innerHTML,title:a.title?a.title:void 0,selected:a.selected,disabled:c===!0?c:a.disabled,group_array_index:b,group_label:null!=b?this.parsed[b].label:null,classes:a.className,style:a.style.cssText})):this.parsed.push({array_index:this.parsed.length,options_index:this.options_index,empty:!0}),this.options_index+=1):void 0},SelectParser.prototype.escapeExpression=function(a){var b,c;return null==a||a===!1?"":/[\&\<\>\"\'\`]/.test(a)?(b={"<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},c=/&(?!\w+;)|[\<\>\"\'\`]/g,a.replace(c,function(a){return b[a]||"&amp;"})):a},SelectParser}(),SelectParser.select_to_array=function(a){var b,c,d,e,f;for(c=new SelectParser,f=a.childNodes,d=0,e=f.length;e>d;d++)b=f[d],c.add_node(b);return c.parsed},AbstractChosen=function(){function AbstractChosen(a,b){this.form_field=a,this.options=null!=b?b:{},AbstractChosen.browser_is_supported()&&(this.is_multiple=this.form_field.multiple,this.set_default_text(),this.set_default_values(),this.setup(),this.set_up_html(),this.register_observers(),this.on_ready())}return AbstractChosen.prototype.set_default_values=function(){var a=this;return this.click_test_action=function(b){return a.test_active_click(b)},this.activate_action=function(b){return a.activate_field(b)},this.active_field=!1,this.mouse_on_container=!1,this.results_showing=!1,this.result_highlighted=null,this.allow_single_deselect=null!=this.options.allow_single_deselect&&null!=this.form_field.options[0]&&""===this.form_field.options[0].text?this.options.allow_single_deselect:!1,this.disable_search_threshold=this.options.disable_search_threshold||0,this.disable_search=this.options.disable_search||!1,this.enable_split_word_search=null!=this.options.enable_split_word_search?this.options.enable_split_word_search:!0,this.group_search=null!=this.options.group_search?this.options.group_search:!0,this.search_contains=this.options.search_contains||!1,this.single_backstroke_delete=null!=this.options.single_backstroke_delete?this.options.single_backstroke_delete:!0,this.max_selected_options=this.options.max_selected_options||1/0,this.inherit_select_classes=this.options.inherit_select_classes||!1,this.display_selected_options=null!=this.options.display_selected_options?this.options.display_selected_options:!0,this.display_disabled_options=null!=this.options.display_disabled_options?this.options.display_disabled_options:!0,this.include_group_label_in_selected=this.options.include_group_label_in_selected||!1,this.max_shown_results=this.options.max_shown_results||Number.POSITIVE_INFINITY},AbstractChosen.prototype.set_default_text=function(){return this.form_field.getAttribute("data-placeholder")?this.default_text=this.form_field.getAttribute("data-placeholder"):this.is_multiple?this.default_text=this.options.placeholder_text_multiple||this.options.placeholder_text||AbstractChosen.default_multiple_text:this.default_text=this.options.placeholder_text_single||this.options.placeholder_text||AbstractChosen.default_single_text,this.results_none_found=this.form_field.getAttribute("data-no_results_text")||this.options.no_results_text||AbstractChosen.default_no_result_text},AbstractChosen.prototype.choice_label=function(a){return this.include_group_label_in_selected&&null!=a.group_label?"<b class='group-name'>"+a.group_label+"</b>"+a.html:a.html},AbstractChosen.prototype.mouse_enter=function(){return this.mouse_on_container=!0},AbstractChosen.prototype.mouse_leave=function(){return this.mouse_on_container=!1},AbstractChosen.prototype.input_focus=function(a){var b=this;if(this.is_multiple){if(!this.active_field)return setTimeout(function(){return b.container_mousedown()},50)}else if(!this.active_field)return this.activate_field()},AbstractChosen.prototype.input_blur=function(a){var b=this;return this.mouse_on_container?void 0:(this.active_field=!1,setTimeout(function(){return b.blur_test()},100))},AbstractChosen.prototype.results_option_build=function(a){var b,c,d,e,f,g,h;for(b="",e=0,h=this.results_data,f=0,g=h.length;g>f&&(c=h[f],d="",d=c.group?this.result_add_group(c):this.result_add_option(c),""!==d&&(e++,b+=d),(null!=a?a.first:void 0)&&(c.selected&&this.is_multiple?this.choice_build(c):c.selected&&!this.is_multiple&&this.single_set_selected_text(this.choice_label(c))),!(e>=this.max_shown_results));f++);return b},AbstractChosen.prototype.result_add_option=function(a){var b,c;return a.search_match&&this.include_option_in_results(a)?(b=[],a.disabled||a.selected&&this.is_multiple||b.push("active-result"),!a.disabled||a.selected&&this.is_multiple||b.push("disabled-result"),a.selected&&b.push("result-selected"),null!=a.group_array_index&&b.push("group-option"),""!==a.classes&&b.push(a.classes),c=document.createElement("li"),c.className=b.join(" "),c.style.cssText=a.style,c.setAttribute("data-option-array-index",a.array_index),c.innerHTML=a.search_text,a.title&&(c.title=a.title),this.outerHTML(c)):""},AbstractChosen.prototype.result_add_group=function(a){var b,c;return(a.search_match||a.group_match)&&a.active_options>0?(b=[],b.push("group-result"),a.classes&&b.push(a.classes),c=document.createElement("li"),c.className=b.join(" "),c.innerHTML=a.search_text,a.title&&(c.title=a.title),this.outerHTML(c)):""},AbstractChosen.prototype.results_update_field=function(){return this.set_default_text(),this.is_multiple||this.results_reset_cleanup(),this.result_clear_highlight(),this.results_build(),this.results_showing?this.winnow_results():void 0},AbstractChosen.prototype.reset_single_select_options=function(){var a,b,c,d,e;for(d=this.results_data,e=[],b=0,c=d.length;c>b;b++)a=d[b],a.selected?e.push(a.selected=!1):e.push(void 0);return e},AbstractChosen.prototype.results_toggle=function(){return this.results_showing?this.results_hide():this.results_show()},AbstractChosen.prototype.results_search=function(a){return this.results_showing?this.winnow_results():this.results_show()},AbstractChosen.prototype.winnow_results=function(){var a,b,c,d,e,f,g,h,i,j,k,l;for(this.no_results_clear(),d=0,f=this.get_search_text(),a=f.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"),i=new RegExp(a,"i"),c=this.get_search_regex(a),l=this.results_data,j=0,k=l.length;k>j;j++)b=l[j],b.search_match=!1,e=null,this.include_option_in_results(b)&&(b.group&&(b.group_match=!1,b.active_options=0),null!=b.group_array_index&&this.results_data[b.group_array_index]&&(e=this.results_data[b.group_array_index],0===e.active_options&&e.search_match&&(d+=1),e.active_options+=1),b.search_text=b.group?b.label:b.html,(!b.group||this.group_search)&&(b.search_match=this.search_string_match(b.search_text,c),b.search_match&&!b.group&&(d+=1),b.search_match?(f.length&&(g=b.search_text.search(i),h=b.search_text.substr(0,g+f.length)+"</em>"+b.search_text.substr(g+f.length),b.search_text=h.substr(0,g)+"<em>"+h.substr(g)),null!=e&&(e.group_match=!0)):null!=b.group_array_index&&this.results_data[b.group_array_index].search_match&&(b.search_match=!0)));return this.result_clear_highlight(),1>d&&f.length?(this.update_results_content(""),this.no_results(f)):(this.update_results_content(this.results_option_build()),this.winnow_results_set_highlight())},AbstractChosen.prototype.get_search_regex=function(a){var b;return b=this.search_contains?"":"^",new RegExp(b+a,"i")},AbstractChosen.prototype.search_string_match=function(a,b){var c,d,e,f;if(b.test(a))return!0;if(this.enable_split_word_search&&(a.indexOf(" ")>=0||0===a.indexOf("["))&&(d=a.replace(/\[|\]/g,"").split(" "),d.length))for(e=0,f=d.length;f>e;e++)if(c=d[e],b.test(c))return!0},AbstractChosen.prototype.choices_count=function(){var a,b,c,d;if(null!=this.selected_option_count)return this.selected_option_count;for(this.selected_option_count=0,d=this.form_field.options,b=0,c=d.length;c>b;b++)a=d[b],a.selected&&(this.selected_option_count+=1);return this.selected_option_count},AbstractChosen.prototype.choices_click=function(a){return a.preventDefault(),this.results_showing||this.is_disabled?void 0:this.results_show()},AbstractChosen.prototype.keyup_checker=function(a){var b,c;switch(b=null!=(c=a.which)?c:a.keyCode,this.search_field_scale(),b){case 8:if(this.is_multiple&&this.backstroke_length<1&&this.choices_count()>0)return this.keydown_backstroke();if(!this.pending_backstroke)return this.result_clear_highlight(),this.results_search();break;case 13:if(a.preventDefault(),this.results_showing)return this.result_select(a);break;case 27:return this.results_showing&&this.results_hide(),!0;case 9:case 38:case 40:case 16:case 91:case 17:case 18:break;default:return this.results_search()}},AbstractChosen.prototype.clipboard_event_checker=function(a){var b=this;return setTimeout(function(){return b.results_search()},50)},AbstractChosen.prototype.container_width=function(){return null!=this.options.width?this.options.width:""+this.form_field.offsetWidth+"px"},AbstractChosen.prototype.include_option_in_results=function(a){return this.is_multiple&&!this.display_selected_options&&a.selected?!1:!this.display_disabled_options&&a.disabled?!1:a.empty?!1:!0},AbstractChosen.prototype.search_results_touchstart=function(a){return this.touch_started=!0,this.search_results_mouseover(a)},AbstractChosen.prototype.search_results_touchmove=function(a){return this.touch_started=!1,this.search_results_mouseout(a)},AbstractChosen.prototype.search_results_touchend=function(a){return this.touch_started?this.search_results_mouseup(a):void 0},AbstractChosen.prototype.outerHTML=function(a){var b;return a.outerHTML?a.outerHTML:(b=document.createElement("div"),b.appendChild(a),b.innerHTML)},AbstractChosen.browser_is_supported=function(){return/iP(od|hone)/i.test(window.navigator.userAgent)?!1:/Android/i.test(window.navigator.userAgent)&&/Mobile/i.test(window.navigator.userAgent)?!1:/IEMobile/i.test(window.navigator.userAgent)?!1:/Windows Phone/i.test(window.navigator.userAgent)?!1:/BlackBerry/i.test(window.navigator.userAgent)?!1:/BB10/i.test(window.navigator.userAgent)?!1:"Microsoft Internet Explorer"===window.navigator.appName?document.documentMode>=8:!0},AbstractChosen.default_multiple_text="Select Some Options",AbstractChosen.default_single_text="Select an Option",AbstractChosen.default_no_result_text="No results match",AbstractChosen}(),a=jQuery,a.fn.extend({chosen:function(b){return AbstractChosen.browser_is_supported()?this.each(function(c){var d,e;return d=a(this),e=d.data("chosen"),"destroy"===b?void(e instanceof Chosen&&e.destroy()):void(e instanceof Chosen||d.data("chosen",new Chosen(this,b)))}):this}}),Chosen=function(c){function Chosen(){return b=Chosen.__super__.constructor.apply(this,arguments)}return d(Chosen,c),Chosen.prototype.setup=function(){return this.form_field_jq=a(this.form_field),this.current_selectedIndex=this.form_field.selectedIndex,this.is_rtl=this.form_field_jq.hasClass("chosen-rtl")},Chosen.prototype.set_up_html=function(){var b,c;return b=["chosen-container"],b.push("chosen-container-"+(this.is_multiple?"multi":"single")),this.inherit_select_classes&&this.form_field.className&&b.push(this.form_field.className),this.is_rtl&&b.push("chosen-rtl"),c={"class":b.join(" "),style:"width: "+this.container_width()+";",title:this.form_field.title},this.form_field.id.length&&(c.id=this.form_field.id.replace(/[^\w]/g,"_")+"_chosen"),this.container=a("<div />",c),this.is_multiple?this.container.html('<ul class="chosen-choices"><li class="search-field"><input type="text" value="'+this.default_text+'" class="default" autocomplete="off" style="width:25px;" /></li></ul><div class="chosen-drop"><ul class="chosen-results"></ul></div>'):this.container.html('<a class="chosen-single chosen-default"><span>'+this.default_text+'</span><div><b></b></div></a><div class="chosen-drop"><div class="chosen-search"><input type="text" autocomplete="off" /></div><ul class="chosen-results"></ul></div>'),this.form_field_jq.hide().after(this.container),this.dropdown=this.container.find("div.chosen-drop").first(),this.search_field=this.container.find("input").first(),this.search_results=this.container.find("ul.chosen-results").first(),this.search_field_scale(),this.search_no_results=this.container.find("li.no-results").first(),this.is_multiple?(this.search_choices=this.container.find("ul.chosen-choices").first(),this.search_container=this.container.find("li.search-field").first()):(this.search_container=this.container.find("div.chosen-search").first(),this.selected_item=this.container.find(".chosen-single").first()),this.results_build(),this.set_tab_index(),this.set_label_behavior()},Chosen.prototype.on_ready=function(){return this.form_field_jq.trigger("chosen:ready",{chosen:this})},Chosen.prototype.register_observers=function(){var a=this;return this.container.bind("touchstart.chosen",function(b){return a.container_mousedown(b),b.preventDefault()}),this.container.bind("touchend.chosen",function(b){return a.container_mouseup(b),b.preventDefault()}),this.container.bind("mousedown.chosen",function(b){a.container_mousedown(b)}),this.container.bind("mouseup.chosen",function(b){a.container_mouseup(b)}),this.container.bind("mouseenter.chosen",function(b){a.mouse_enter(b)}),this.container.bind("mouseleave.chosen",function(b){a.mouse_leave(b)}),this.search_results.bind("mouseup.chosen",function(b){a.search_results_mouseup(b)}),this.search_results.bind("mouseover.chosen",function(b){a.search_results_mouseover(b)}),this.search_results.bind("mouseout.chosen",function(b){a.search_results_mouseout(b)}),this.search_results.bind("mousewheel.chosen DOMMouseScroll.chosen",function(b){a.search_results_mousewheel(b)}),this.search_results.bind("touchstart.chosen",function(b){a.search_results_touchstart(b)}),this.search_results.bind("touchmove.chosen",function(b){a.search_results_touchmove(b)}),this.search_results.bind("touchend.chosen",function(b){a.search_results_touchend(b)}),this.form_field_jq.bind("chosen:updated.chosen",function(b){a.results_update_field(b)}),this.form_field_jq.bind("chosen:activate.chosen",function(b){a.activate_field(b)}),this.form_field_jq.bind("chosen:open.chosen",function(b){a.container_mousedown(b)}),this.form_field_jq.bind("chosen:close.chosen",function(b){a.input_blur(b)}),this.search_field.bind("blur.chosen",function(b){a.input_blur(b)}),this.search_field.bind("keyup.chosen",function(b){a.keyup_checker(b)}),this.search_field.bind("keydown.chosen",function(b){a.keydown_checker(b)}),this.search_field.bind("focus.chosen",function(b){a.input_focus(b)}),this.search_field.bind("cut.chosen",function(b){a.clipboard_event_checker(b)}),this.search_field.bind("paste.chosen",function(b){a.clipboard_event_checker(b)}),this.is_multiple?this.search_choices.bind("click.chosen",function(b){a.choices_click(b)}):this.container.bind("click.chosen",function(a){a.preventDefault()})},Chosen.prototype.destroy=function(){return a(this.container[0].ownerDocument).unbind("click.chosen",this.click_test_action),this.search_field[0].tabIndex&&(this.form_field_jq[0].tabIndex=this.search_field[0].tabIndex),this.container.remove(),this.form_field_jq.removeData("chosen"),this.form_field_jq.show()},Chosen.prototype.search_field_disabled=function(){return this.is_disabled=this.form_field_jq[0].disabled,this.is_disabled?(this.container.addClass("chosen-disabled"),this.search_field[0].disabled=!0,this.is_multiple||this.selected_item.unbind("focus.chosen",this.activate_action),this.close_field()):(this.container.removeClass("chosen-disabled"),this.search_field[0].disabled=!1,this.is_multiple?void 0:this.selected_item.bind("focus.chosen",this.activate_action))},Chosen.prototype.container_mousedown=function(b){return this.is_disabled||(b&&"mousedown"===b.type&&!this.results_showing&&b.preventDefault(),null!=b&&a(b.target).hasClass("search-choice-close"))?void 0:(this.active_field?this.is_multiple||!b||a(b.target)[0]!==this.selected_item[0]&&!a(b.target).parents("a.chosen-single").length||(b.preventDefault(),this.results_toggle()):(this.is_multiple&&this.search_field.val(""),a(this.container[0].ownerDocument).bind("click.chosen",this.click_test_action),this.results_show()),this.activate_field())},Chosen.prototype.container_mouseup=function(a){return"ABBR"!==a.target.nodeName||this.is_disabled?void 0:this.results_reset(a)},Chosen.prototype.search_results_mousewheel=function(a){var b;return a.originalEvent&&(b=a.originalEvent.deltaY||-a.originalEvent.wheelDelta||a.originalEvent.detail),null!=b?(a.preventDefault(),"DOMMouseScroll"===a.type&&(b=40*b),this.search_results.scrollTop(b+this.search_results.scrollTop())):void 0},Chosen.prototype.blur_test=function(a){return!this.active_field&&this.container.hasClass("chosen-container-active")?this.close_field():void 0},Chosen.prototype.close_field=function(){return a(this.container[0].ownerDocument).unbind("click.chosen",this.click_test_action),this.active_field=!1,this.results_hide(),this.container.removeClass("chosen-container-active"),this.clear_backstroke(),this.show_search_field_default(),this.search_field_scale()},Chosen.prototype.activate_field=function(){return this.container.addClass("chosen-container-active"),this.active_field=!0,this.search_field.val(this.search_field.val()),this.search_field.focus()},Chosen.prototype.test_active_click=function(b){var c;return c=a(b.target).closest(".chosen-container"),c.length&&this.container[0]===c[0]?this.active_field=!0:this.close_field()},Chosen.prototype.results_build=function(){return this.parsing=!0,this.selected_option_count=null,this.results_data=SelectParser.select_to_array(this.form_field),this.is_multiple?this.search_choices.find("li.search-choice").remove():this.is_multiple||(this.single_set_selected_text(),this.disable_search||this.form_field.options.length<=this.disable_search_threshold?(this.search_field[0].readOnly=!0,this.container.addClass("chosen-container-single-nosearch")):(this.search_field[0].readOnly=!1,this.container.removeClass("chosen-container-single-nosearch"))),this.update_results_content(this.results_option_build({first:!0})),this.search_field_disabled(),this.show_search_field_default(),this.search_field_scale(),this.parsing=!1},Chosen.prototype.result_do_highlight=function(a){var b,c,d,e,f;if(a.length){if(this.result_clear_highlight(),this.result_highlight=a,this.result_highlight.addClass("highlighted"),d=parseInt(this.search_results.css("maxHeight"),10),f=this.search_results.scrollTop(),e=d+f,c=this.result_highlight.position().top+this.search_results.scrollTop(),b=c+this.result_highlight.outerHeight(),b>=e)return this.search_results.scrollTop(b-d>0?b-d:0);if(f>c)return this.search_results.scrollTop(c)}},Chosen.prototype.result_clear_highlight=function(){return this.result_highlight&&this.result_highlight.removeClass("highlighted"),this.result_highlight=null},Chosen.prototype.results_show=function(){return this.is_multiple&&this.max_selected_options<=this.choices_count()?(this.form_field_jq.trigger("chosen:maxselected",{chosen:this}),!1):(this.container.addClass("chosen-with-drop"),this.results_showing=!0,this.search_field.focus(),this.search_field.val(this.search_field.val()),this.winnow_results(),this.form_field_jq.trigger("chosen:showing_dropdown",{chosen:this}))},Chosen.prototype.update_results_content=function(a){return this.search_results.html(a)},Chosen.prototype.results_hide=function(){return this.results_showing&&(this.result_clear_highlight(),this.container.removeClass("chosen-with-drop"),this.form_field_jq.trigger("chosen:hiding_dropdown",{chosen:this})),this.results_showing=!1},Chosen.prototype.set_tab_index=function(a){var b;return this.form_field.tabIndex?(b=this.form_field.tabIndex,this.form_field.tabIndex=-1,this.search_field[0].tabIndex=b):void 0},Chosen.prototype.set_label_behavior=function(){var b=this;return this.form_field_label=this.form_field_jq.parents("label"),!this.form_field_label.length&&this.form_field.id.length&&(this.form_field_label=a("label[for='"+this.form_field.id+"']")),this.form_field_label.length>0?this.form_field_label.bind("click.chosen",function(a){return b.is_multiple?b.container_mousedown(a):b.activate_field()}):void 0},Chosen.prototype.show_search_field_default=function(){return this.is_multiple&&this.choices_count()<1&&!this.active_field?(this.search_field.val(this.default_text),this.search_field.addClass("default")):(this.search_field.val(""),this.search_field.removeClass("default"))},Chosen.prototype.search_results_mouseup=function(b){var c;return c=a(b.target).hasClass("active-result")?a(b.target):a(b.target).parents(".active-result").first(),c.length?(this.result_highlight=c,this.result_select(b),this.search_field.focus()):void 0},Chosen.prototype.search_results_mouseover=function(b){var c;return c=a(b.target).hasClass("active-result")?a(b.target):a(b.target).parents(".active-result").first(),c?this.result_do_highlight(c):void 0},Chosen.prototype.search_results_mouseout=function(b){return a(b.target).hasClass("active-result")?this.result_clear_highlight():void 0},Chosen.prototype.choice_build=function(b){var c,d,e=this;return c=a("<li />",{"class":"search-choice"}).html("<span>"+this.choice_label(b)+"</span>"),b.disabled?c.addClass("search-choice-disabled"):(d=a("<a />",{"class":"search-choice-close","data-option-array-index":b.array_index}),d.bind("click.chosen",function(a){return e.choice_destroy_link_click(a)}),c.append(d)),this.search_container.before(c)},Chosen.prototype.choice_destroy_link_click=function(b){return b.preventDefault(),b.stopPropagation(),this.is_disabled?void 0:this.choice_destroy(a(b.target))},Chosen.prototype.choice_destroy=function(a){return this.result_deselect(a[0].getAttribute("data-option-array-index"))?(this.show_search_field_default(),this.is_multiple&&this.choices_count()>0&&this.search_field.val().length<1&&this.results_hide(),a.parents("li").first().remove(),this.search_field_scale()):void 0},Chosen.prototype.results_reset=function(){return this.reset_single_select_options(),this.form_field.options[0].selected=!0,this.single_set_selected_text(),this.show_search_field_default(),this.results_reset_cleanup(),this.form_field_jq.trigger("change"),this.active_field?this.results_hide():void 0},Chosen.prototype.results_reset_cleanup=function(){return this.current_selectedIndex=this.form_field.selectedIndex,this.selected_item.find("abbr").remove()},Chosen.prototype.result_select=function(a){var b,c;return this.result_highlight?(b=this.result_highlight,this.result_clear_highlight(),this.is_multiple&&this.max_selected_options<=this.choices_count()?(this.form_field_jq.trigger("chosen:maxselected",{chosen:this}),!1):(this.is_multiple?b.removeClass("active-result"):this.reset_single_select_options(),b.addClass("result-selected"),c=this.results_data[b[0].getAttribute("data-option-array-index")],c.selected=!0,this.form_field.options[c.options_index].selected=!0,this.selected_option_count=null,this.is_multiple?this.choice_build(c):this.single_set_selected_text(this.choice_label(c)),(a.metaKey||a.ctrlKey)&&this.is_multiple||this.results_hide(),this.show_search_field_default(),(this.is_multiple||this.form_field.selectedIndex!==this.current_selectedIndex)&&this.form_field_jq.trigger("change",{selected:this.form_field.options[c.options_index].value}),this.current_selectedIndex=this.form_field.selectedIndex,a.preventDefault(),this.search_field_scale())):void 0},Chosen.prototype.single_set_selected_text=function(a){return null==a&&(a=this.default_text),a===this.default_text?this.selected_item.addClass("chosen-default"):(this.single_deselect_control_build(),this.selected_item.removeClass("chosen-default")),this.selected_item.find("span").html(a)},Chosen.prototype.result_deselect=function(a){var b;return b=this.results_data[a],this.form_field.options[b.options_index].disabled?!1:(b.selected=!1,this.form_field.options[b.options_index].selected=!1,this.selected_option_count=null,this.result_clear_highlight(),this.results_showing&&this.winnow_results(),this.form_field_jq.trigger("change",{deselected:this.form_field.options[b.options_index].value}),this.search_field_scale(),!0)},Chosen.prototype.single_deselect_control_build=function(){return this.allow_single_deselect?(this.selected_item.find("abbr").length||this.selected_item.find("span").first().after('<abbr class="search-choice-close"></abbr>'),this.selected_item.addClass("chosen-single-with-deselect")):void 0},Chosen.prototype.get_search_text=function(){return a("<div/>").text(a.trim(this.search_field.val())).html()},Chosen.prototype.winnow_results_set_highlight=function(){var a,b;return b=this.is_multiple?[]:this.search_results.find(".result-selected.active-result"),a=b.length?b.first():this.search_results.find(".active-result").first(),null!=a?this.result_do_highlight(a):void 0},Chosen.prototype.no_results=function(b){var c;return c=a('<li class="no-results">'+this.results_none_found+' "<span></span>"</li>'),c.find("span").first().html(b),this.search_results.append(c),this.form_field_jq.trigger("chosen:no_results",{chosen:this})},Chosen.prototype.no_results_clear=function(){return this.search_results.find(".no-results").remove()},Chosen.prototype.keydown_arrow=function(){var a;return this.results_showing&&this.result_highlight?(a=this.result_highlight.nextAll("li.active-result").first())?this.result_do_highlight(a):void 0:this.results_show()},Chosen.prototype.keyup_arrow=function(){var a;return this.results_showing||this.is_multiple?this.result_highlight?(a=this.result_highlight.prevAll("li.active-result"),a.length?this.result_do_highlight(a.first()):(this.choices_count()>0&&this.results_hide(),this.result_clear_highlight())):void 0:this.results_show()},Chosen.prototype.keydown_backstroke=function(){var a;return this.pending_backstroke?(this.choice_destroy(this.pending_backstroke.find("a").first()),this.clear_backstroke()):(a=this.search_container.siblings("li.search-choice").last(),a.length&&!a.hasClass("search-choice-disabled")?(this.pending_backstroke=a,this.single_backstroke_delete?this.keydown_backstroke():this.pending_backstroke.addClass("search-choice-focus")):void 0)},Chosen.prototype.clear_backstroke=function(){return this.pending_backstroke&&this.pending_backstroke.removeClass("search-choice-focus"),this.pending_backstroke=null},Chosen.prototype.keydown_checker=function(a){var b,c;switch(b=null!=(c=a.which)?c:a.keyCode,this.search_field_scale(),8!==b&&this.pending_backstroke&&this.clear_backstroke(),b){case 8:this.backstroke_length=this.search_field.val().length;break;case 9:this.results_showing&&!this.is_multiple&&this.result_select(a),this.mouse_on_container=!1;break;case 13:this.results_showing&&a.preventDefault();break;case 32:this.disable_search&&a.preventDefault();break;case 38:a.preventDefault(),this.keyup_arrow();break;case 40:a.preventDefault(),this.keydown_arrow()}},Chosen.prototype.search_field_scale=function(){var b,c,d,e,f,g,h,i,j;if(this.is_multiple){for(d=0,h=0,f="position:absolute; left: -1000px; top: -1000px; display:none;",g=["font-size","font-style","font-weight","font-family","line-height","text-transform","letter-spacing"],i=0,j=g.length;j>i;i++)e=g[i],f+=e+":"+this.search_field.css(e)+";";return b=a("<div />",{style:f}),b.text(this.search_field.val()),a("body").append(b),h=b.width()+25,b.remove(),c=this.container.outerWidth(),h>c-10&&(h=c-10),this.search_field.css({width:h+"px"})}},Chosen}(AbstractChosen)}).call(this);
js/master.js CHANGED
@@ -869,12 +869,15 @@ jQuery(document).ready(function(){
869
  jQuery(".login.pro-only").click(function(e){
870
  if(!ropProAvailable){
871
  window.open(
872
- 'https://themeisle.com/plugins/tweet-old-post-pro/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true',
873
  '_blank'
874
  );
875
  return false;
876
  }
877
  });
 
 
 
878
  });
879
 
880
  function cwpDependeField(field,second){
869
  jQuery(".login.pro-only").click(function(e){
870
  if(!ropProAvailable){
871
  window.open(
872
+ 'http://revive.social/plugins/revive-old-post/?utm_source=imagepro&utm_medium=link&utm_campaign=top&upgrade=true',
873
  '_blank'
874
  );
875
  return false;
876
  }
877
  });
878
+
879
+ jQuery(".top-chosen-select").chosen({width: "90%"});
880
+ jQuery("#top_exc_inc_radio").buttonset();
881
  });
882
 
883
  function cwpDependeField(field,second){
languages/tweet-old-post-de_DE.po CHANGED
@@ -650,15 +650,15 @@ msgid ""
650
  "them and driving more traffic to them from twitter/facebook or linkedin. It "
651
  "also helps you to promote your content. You can set time and no of posts to "
652
  "share to drive more traffic.For questions, comments, or feature requests, <a "
653
- "href=\"https://themeisle.com/contact/?"
654
  "utm_source=plugindesc&utm_medium=announce&utm_campaign=top\">contact </a> us!"
655
  msgstr ""
656
  "Ein WordPress-Plug-in, das Ihnen dabei hilft, Ihre alten Beiträge am Leben "
657
  "zu halten, indem Sie sie teilen und mehr Traffic von Twitter, Facebook oder "
658
  "Linkedin auf Ihren Blog lenken. Sie können auf diese Weise auch Ihre Inhalte "
659
  "besser vermarkten. Legen Sie eine Zeit und die Anzahl der zu teilenden "
660
- "Beiträge fest, um mehr Traffic zu generieren. <a href=\"https://themeisle.com/"
661
- "contact/?utm_source=plugindesc&utm_medium=announce&utm_campaign=top"
662
  "\">Kontaktieren Sie uns</a>, falls Sie Fragen, Kommentare oder Wünsche haben!"
663
 
664
  #~ msgid "Post Only"
650
  "them and driving more traffic to them from twitter/facebook or linkedin. It "
651
  "also helps you to promote your content. You can set time and no of posts to "
652
  "share to drive more traffic.For questions, comments, or feature requests, <a "
653
+ "href=\"http://revive.social/support/?"
654
  "utm_source=plugindesc&utm_medium=announce&utm_campaign=top\">contact </a> us!"
655
  msgstr ""
656
  "Ein WordPress-Plug-in, das Ihnen dabei hilft, Ihre alten Beiträge am Leben "
657
  "zu halten, indem Sie sie teilen und mehr Traffic von Twitter, Facebook oder "
658
  "Linkedin auf Ihren Blog lenken. Sie können auf diese Weise auch Ihre Inhalte "
659
  "besser vermarkten. Legen Sie eine Zeit und die Anzahl der zu teilenden "
660
+ "Beiträge fest, um mehr Traffic zu generieren. <a href=\"http://revive.social/"
661
+ "support/?utm_source=plugindesc&utm_medium=announce&utm_campaign=top"
662
  "\">Kontaktieren Sie uns</a>, falls Sie Fragen, Kommentare oder Wünsche haben!"
663
 
664
  #~ msgid "Post Only"
readme.txt CHANGED
@@ -1,5 +1,5 @@
1
  === Revive Old Post (Former Tweet Old Post) ===
2
- Contributors: codeinwp,marius2012,marius_codeinwp,hardeepasrani,Madalin_Themeisle
3
  Tags: admin, ajax, plugin, twitter, facebook, linkedin, automatic, tweet, share, wordpress, marketing, sharing, Tweet old post, Tweets,evergreen, Promote old post by tweeting about them, Twitter, Auto Tweet, Hashtags, Twitter Hashtags, Tweet Posts, Tweet, Post Tweets, Wordpress Twitter Plugin, Twitter Plugin, Tweet Selected Posts, Twitter, Promote Posts, Tweet Random Post, Share Post, Promote Post, Post Tweets, Wordpress Twitter, Drive Traffic, Tweet Selected Posts
4
  Requires at least: 2.7
5
  Tested up to: 4.5.2
@@ -12,7 +12,7 @@ Plugin to share about your old posts on twitter, facebook, linkedin to get more
12
 
13
  ### What the plugin can do ?
14
 
15
- This plugin helps you to keeps your old posts alive by sharing them and driving more traffic to them from social networks. It also helps you to promote your content. You can set time and no of posts to share to drive more traffic.For questions, comments, or feature requests, <a href="http://themeisle.com/contact/?utm_source=readmetop&utm_medium=announce&utm_campaign=top">contact us</a>!
16
 
17
 
18
 
@@ -29,7 +29,7 @@ This plugin helps you to keeps your old posts alive by sharing them and driving
29
 
30
  > ### Why to upgrade to PRO ?
31
 
32
- > Using the <a rel="friend" href="https://themeisle.com/plugins/tweet-old-post-pro/">PRO version</a> of the plugin you will unleash the most important functionality : images in tweets . Using those your RT/CTR will go crazy.
33
 
34
  > Other notable features :
35
 
@@ -42,11 +42,11 @@ This plugin helps you to keeps your old posts alive by sharing them and driving
42
 
43
  Some of you reported some scheduling issues, after investigation work looks like this is coming from some web hosts, make sure you check-out this post about <a rel="friend" href="http://www.codeinwp.com/blog/best-wordpress-shared-hosting-providers/">shared WordPress hosting</a>, which should help you pick a good one that works.
44
 
45
- For updates follow https://twitter.com/themeisle If you have anything you can let us know <a href="http://themeisle.com/contact/?utm_source=readmetop&utm_medium=announce&utm_campaign=top">here</a>.
46
 
47
  ** Useful Resources **
48
 
49
- - Check-out our <a href="http://docs.themeisle.com" rel="friend" target="_blank">tutorials site</a>
50
  - Take a look at our other <a href="http://themeisle.com/wordpress-plugins/" rel="friend" target="_blank">plugins</a>.
51
  - Read more about WordPress on our <a href="http://www.codeinwp.com/blog/" rel="friend" target="_blank">blog</a>.
52
 
@@ -79,7 +79,7 @@ Alternatively you can also follow the following steps to install the Revive Old
79
 
80
  == Frequently Asked Questions ==
81
  If you have any questions please get in touch with us at,
82
- https://themeisle.com/contact/
83
 
84
  **Before asking any question you need to check if you have the latest version, either PRO or FREE.**
85
 
@@ -98,7 +98,7 @@ https://themeisle.com/contact/
98
 
99
  **How do i add a facebook account**
100
 
101
- - Please fallow this tutorial : http://docs.themeisle.com/article/66-how-to-create-a-facebook-application
102
 
103
  **If new version doesn't works**
104
 
@@ -109,7 +109,7 @@ https://themeisle.com/contact/
109
 
110
  **Any more questions or doubts?**
111
 
112
- - Contact us at https://themeisle.com/contact/ and send us also a copy from Revive Old Post -> System Info
113
 
114
 
115
 
@@ -120,11 +120,20 @@ https://themeisle.com/contact/
120
 
121
  for more you can check out
122
 
123
- https://themeisle.com/plugins/tweet-old-post-lite/
124
 
125
 
126
  == Changelog ==
127
 
 
 
 
 
 
 
 
 
 
128
  **New in v7.3.7**
129
 
130
  * Fixed issue with inverted settings in post format and custom schedule
@@ -169,6 +178,7 @@ https://themeisle.com/plugins/tweet-old-post-lite/
169
 
170
 
171
  **New in v7.0.8**
 
172
  * Added facebook tutorial for facebook share.
173
  * Fixed multisite issue for redirect url
174
  * Making translation ready for new wordpress.org system
1
  === Revive Old Post (Former Tweet Old Post) ===
2
+ Contributors: codeinwp,marius2012,marius_codeinwp,hardeepasrani,Madalin_Themeisle, rsocial
3
  Tags: admin, ajax, plugin, twitter, facebook, linkedin, automatic, tweet, share, wordpress, marketing, sharing, Tweet old post, Tweets,evergreen, Promote old post by tweeting about them, Twitter, Auto Tweet, Hashtags, Twitter Hashtags, Tweet Posts, Tweet, Post Tweets, Wordpress Twitter Plugin, Twitter Plugin, Tweet Selected Posts, Twitter, Promote Posts, Tweet Random Post, Share Post, Promote Post, Post Tweets, Wordpress Twitter, Drive Traffic, Tweet Selected Posts
4
  Requires at least: 2.7
5
  Tested up to: 4.5.2
12
 
13
  ### What the plugin can do ?
14
 
15
+ This plugin helps you to keeps your old posts alive by sharing them and driving more traffic to them from social networks. It also helps you to promote your content. You can set time and no of posts to share to drive more traffic.For questions, comments, or feature requests, <a href="http://revive.social/support/?utm_source=readmetop&utm_medium=announce&utm_campaign=top">contact us</a>!
16
 
17
 
18
 
29
 
30
  > ### Why to upgrade to PRO ?
31
 
32
+ > Using the <a rel="friend" href="http://revive.social/plugins/revive-old-post/">PRO version</a> of the plugin you will unleash the most important functionality : images in tweets . Using those your RT/CTR will go crazy.
33
 
34
  > Other notable features :
35
 
42
 
43
  Some of you reported some scheduling issues, after investigation work looks like this is coming from some web hosts, make sure you check-out this post about <a rel="friend" href="http://www.codeinwp.com/blog/best-wordpress-shared-hosting-providers/">shared WordPress hosting</a>, which should help you pick a good one that works.
44
 
45
+ For updates follow https://twitter.com/ReviveSocial If you have anything you can let us know <a href="http://revive.social/support/?utm_source=readmetop&utm_medium=announce&utm_campaign=top">here</a>.
46
 
47
  ** Useful Resources **
48
 
49
+ - Check-out our <a href="http://docs.revive.social" rel="friend" target="_blank">tutorials site</a>
50
  - Take a look at our other <a href="http://themeisle.com/wordpress-plugins/" rel="friend" target="_blank">plugins</a>.
51
  - Read more about WordPress on our <a href="http://www.codeinwp.com/blog/" rel="friend" target="_blank">blog</a>.
52
 
79
 
80
  == Frequently Asked Questions ==
81
  If you have any questions please get in touch with us at,
82
+ http://revive.social/support/
83
 
84
  **Before asking any question you need to check if you have the latest version, either PRO or FREE.**
85
 
98
 
99
  **How do i add a facebook account**
100
 
101
+ - Please fallow this tutorial : http://docs.revive.social/article/349-how-to-create-a-facebook-application-for-revive-old-post
102
 
103
  **If new version doesn't works**
104
 
109
 
110
  **Any more questions or doubts?**
111
 
112
+ - Contact us at http://revive.social/support/ and send us also a copy from Revive Old Post -> System Info
113
 
114
 
115
 
120
 
121
  for more you can check out
122
 
123
+ http://revive.social/plugins/revive-old-post
124
 
125
 
126
  == Changelog ==
127
 
128
+ **New in v7.3.8**
129
+
130
+ * Improved categories excluding UI in the General tab
131
+ * Improved design of the social networks authorization popups
132
+ * Added more shortners
133
+ * Fixed issue with wrong tags fetch
134
+
135
+
136
+
137
  **New in v7.3.7**
138
 
139
  * Fixed issue with inverted settings in post format and custom schedule
178
 
179
 
180
  **New in v7.0.8**
181
+
182
  * Added facebook tutorial for facebook share.
183
  * Fixed multisite issue for redirect url
184
  * Making translation ready for new wordpress.org system
tweet-old-post.php CHANGED
@@ -1,17 +1,17 @@
1
  <?php
2
  # /*
3
  # Plugin Name: Revive Old Post (Former Tweet Old Post)
4
- # Plugin URI: https://themeisle.com/plugins/tweet-old-post-lite/
5
- # Description: Wordpress plugin that helps you to keeps your old posts alive by sharing them and driving more traffic to them from twitter/facebook or linkedin. It also helps you to promote your content. You can set time and no of posts to share to drive more traffic.For questions, comments, or feature requests, <a href="https://themeisle.com/contact/?utm_source=plugindesc&utm_medium=announce&utm_campaign=top">contact </a> us!
6
- # Author: ThemeIsle
7
- # Version: 7.3.7
8
- # Author URI: https://themeisle.com/
9
  # Text Domain: tweet-old-post
10
  # Domain Path: /languages
11
  # */
12
 
13
  // Config Constants
14
- define ("ROP_PRO_URL", "http://themeisle.com/plugins/tweet-old-post-pro/");
15
  define("ROPPLUGINPATH", realpath(dirname(__FILE__) ));
16
  define("ROPCSSFILE", plugins_url('css/style.css',__FILE__ ));
17
  define("ROPCUSTOMDASHBOARDICON", plugins_url("css/custom_dashboard_icon.css", __FILE__));
@@ -19,7 +19,11 @@ define("ROPJSFILE", plugins_url('js/master.js',__FILE__ ));
19
  define("ROPJSCOUNTDOWN", plugins_url('js/countdown.js',__FILE__ ));
20
  define("ROPPLUGINBASENAME", plugin_basename(__FILE__));
21
  define('ROP_TOP_FB_API_VERSION','v2.0');
22
- define('ROP_VERSION','7.3.7');
 
 
 
 
23
  // Require core.
24
  require_once(ROPPLUGINPATH."/inc/core.php");
25
  // Require core.
1
  <?php
2
  # /*
3
  # Plugin Name: Revive Old Post (Former Tweet Old Post)
4
+ # Plugin URI: https://revive.social/
5
+ # Description: Wordpress plugin that helps you to keeps your old posts alive by sharing them and driving more traffic to them from twitter/facebook or linkedin. It also helps you to promote your content. You can set time and no of posts to share to drive more traffic.For questions, comments, or feature requests, <a href="http://revive.social/support/?utm_source=plugindesc&utm_medium=announce&utm_campaign=top">contact </a> us!
6
+ # Author: reviev.social
7
+ # Version: 7.3.8
8
+ # Author URI: https://revive.social/
9
  # Text Domain: tweet-old-post
10
  # Domain Path: /languages
11
  # */
12
 
13
  // Config Constants
14
+ define ("ROP_PRO_URL", "http://revive.social/plugins/revive-old-post/");
15
  define("ROPPLUGINPATH", realpath(dirname(__FILE__) ));
16
  define("ROPCSSFILE", plugins_url('css/style.css',__FILE__ ));
17
  define("ROPCUSTOMDASHBOARDICON", plugins_url("css/custom_dashboard_icon.css", __FILE__));
19
  define("ROPJSCOUNTDOWN", plugins_url('js/countdown.js',__FILE__ ));
20
  define("ROPPLUGINBASENAME", plugin_basename(__FILE__));
21
  define('ROP_TOP_FB_API_VERSION','v2.0');
22
+ define('ROP_VERSION','7.3.8');
23
+ // Added by Ash/Upwork
24
+ define("ROP_ROOT", trailingslashit(plugins_url("", __FILE__)));
25
+ // Added by Ash/Upwork
26
+
27
  // Require core.
28
  require_once(ROPPLUGINPATH."/inc/core.php");
29
  // Require core.