SEOPress - Version 3.8.0.3

Version Description

  • INFO Add a fallback for get modified post date in xml sitemaps
  • FIX JS file for SEO metabox
Download this release

Release Info

Developer rainbowgeek
Plugin Icon 128x128 SEOPress
Version 3.8.0.3
Comparing to
See all releases

Code changes from version 3.8.0.2 to 3.8.0.3

assets/js/seopress-counters.js CHANGED
@@ -1,43 +1,3 @@
1
- function sp_meta_title_update(e) {
2
- var meta_title_val = jQuery("#seopress_titles_title_meta").val();
3
- var meta_title_placeholder = jQuery("#seopress_titles_title_meta").attr("placeholder");
4
-
5
- jQuery("#seopress_titles_title_counters").css("color", "inherit"),
6
- jQuery("#seopress_titles_title_pixel").css("color", "inherit"),
7
-
8
- meta_title_val.length > 60 && jQuery("#seopress_titles_title_counters").css("color", "red"),
9
- pixelTitle(meta_title_val) > 568 && jQuery("#seopress_titles_title_pixel").css("color", "red");
10
-
11
- if (meta_title_val.length == 0) {
12
- meta_title_placeholder.length > 60 && jQuery("#seopress_titles_title_counters").css("color", "red"),
13
- pixelTitle(meta_title_placeholder) > 568 && jQuery("#seopress_titles_title_pixel").css("color", "red")
14
- }
15
-
16
- meta_title_val.length > 0 ? (jQuery("#seopress_titles_title_counters").text(meta_title_val.length),
17
- jQuery("#seopress_titles_title_pixel").text(pixelTitle(meta_title_val))) : meta_title_placeholder.length && (jQuery("#seopress_titles_title_counters").text(meta_title_placeholder.length),
18
- jQuery("#seopress_titles_title_pixel").text(pixelTitle(meta_title_placeholder))),
19
-
20
- meta_title_val.length > 0 ? (jQuery(".snippet-title-custom").text(e.target.value),
21
- jQuery(".snippet-title").css("display", "none"),
22
- jQuery(".snippet-title-custom").css("display", "block"),
23
- jQuery(".snippet-title-default").css("display", "none")) : 0 == meta_title_val.length && (jQuery(".snippet-title-default").css("display", "block"),
24
- jQuery(".snippet-title-custom").css("display", "none"), jQuery(".snippet-title").css("display", "none"));
25
-
26
- if (meta_title_val.length) {
27
- var progress = Math.round(pixelTitle(meta_title_val)/568*100);
28
- } else {
29
- var progress = Math.round(pixelTitle(meta_title_placeholder)/568*100);
30
- }
31
-
32
- if (progress >= 100) {
33
- progress = 100;
34
- }
35
-
36
- jQuery('#seopress_titles_title_counters_progress').attr('aria-valuenow',progress),
37
- jQuery('#seopress_titles_title_counters_progress').text(progress +'%'),
38
- jQuery('#seopress_titles_title_counters_progress').css('width',progress +'%')
39
- }
40
-
41
  function sp_titles_counters() {
42
  var meta_title_val = jQuery("#seopress_titles_title_meta").val();
43
  var meta_title_placeholder = jQuery("#seopress_titles_title_meta").attr("placeholder");
@@ -62,7 +22,47 @@ function sp_titles_counters() {
62
 
63
  jQuery('#seopress_titles_title_counters_progress').attr('aria-valuenow',progress),
64
  jQuery('#seopress_titles_title_counters_progress').text(progress +'%'),
65
- jQuery('#seopress_titles_title_counters_progress').css('width',progress +'%')
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
66
  }
67
 
68
  function sp_meta_desc_counters() {
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  function sp_titles_counters() {
2
  var meta_title_val = jQuery("#seopress_titles_title_meta").val();
3
  var meta_title_placeholder = jQuery("#seopress_titles_title_meta").attr("placeholder");
22
 
23
  jQuery('#seopress_titles_title_counters_progress').attr('aria-valuenow',progress),
24
  jQuery('#seopress_titles_title_counters_progress').text(progress +'%'),
25
+ jQuery('#seopress_titles_title_counters_progress').css('width',progress +'%'),
26
+
27
+ jQuery("#seopress_titles_title_meta, #seopress-tag-single-title, #seopress-tag-single-site-title, #seopress-tag-single-sep").on('keyup paste change click', function(e) {
28
+ var meta_title_val = jQuery("#seopress_titles_title_meta").val();
29
+ var meta_title_placeholder = jQuery("#seopress_titles_title_meta").attr("placeholder");
30
+
31
+ jQuery("#seopress_titles_title_counters").css("color", "inherit"),
32
+ jQuery("#seopress_titles_title_pixel").css("color", "inherit"),
33
+
34
+ meta_title_val.length > 60 && jQuery("#seopress_titles_title_counters").css("color", "red"),
35
+ pixelTitle(meta_title_val) > 568 && jQuery("#seopress_titles_title_pixel").css("color", "red");
36
+
37
+ if (meta_title_val.length == 0) {
38
+ meta_title_placeholder.length > 60 && jQuery("#seopress_titles_title_counters").css("color", "red"),
39
+ pixelTitle(meta_title_placeholder) > 568 && jQuery("#seopress_titles_title_pixel").css("color", "red")
40
+ }
41
+
42
+ meta_title_val.length > 0 ? (jQuery("#seopress_titles_title_counters").text(meta_title_val.length),
43
+ jQuery("#seopress_titles_title_pixel").text(pixelTitle(meta_title_val))) : meta_title_placeholder.length && (jQuery("#seopress_titles_title_counters").text(meta_title_placeholder.length),
44
+ jQuery("#seopress_titles_title_pixel").text(pixelTitle(meta_title_placeholder))),
45
+
46
+ meta_title_val.length > 0 ? (jQuery(".snippet-title-custom").text(e.target.value),
47
+ jQuery(".snippet-title").css("display", "none"),
48
+ jQuery(".snippet-title-custom").css("display", "block"),
49
+ jQuery(".snippet-title-default").css("display", "none")) : 0 == meta_title_val.length && (jQuery(".snippet-title-default").css("display", "block"),
50
+ jQuery(".snippet-title-custom").css("display", "none"), jQuery(".snippet-title").css("display", "none"));
51
+
52
+ if (meta_title_val.length) {
53
+ var progress = Math.round(pixelTitle(meta_title_val)/568*100);
54
+ } else {
55
+ var progress = Math.round(pixelTitle(meta_title_placeholder)/568*100);
56
+ }
57
+
58
+ if (progress >= 100) {
59
+ progress = 100;
60
+ }
61
+
62
+ jQuery('#seopress_titles_title_counters_progress').attr('aria-valuenow',progress),
63
+ jQuery('#seopress_titles_title_counters_progress').text(progress +'%'),
64
+ jQuery('#seopress_titles_title_counters_progress').css('width',progress +'%')
65
+ })
66
  }
67
 
68
  function sp_meta_desc_counters() {
assets/js/seopress-counters.min.js CHANGED
@@ -1 +1 @@
1
- function sp_meta_title_update(e){var s=jQuery("#seopress_titles_title_meta").val(),t=jQuery("#seopress_titles_title_meta").attr("placeholder");if(jQuery("#seopress_titles_title_counters").css("color","inherit"),jQuery("#seopress_titles_title_pixel").css("color","inherit"),s.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(s)>568&&jQuery("#seopress_titles_title_pixel").css("color","red"),0==s.length&&(t.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(t)>568&&jQuery("#seopress_titles_title_pixel").css("color","red")),s.length>0?(jQuery("#seopress_titles_title_counters").text(s.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(s))):t.length&&(jQuery("#seopress_titles_title_counters").text(t.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(t))),s.length>0?(jQuery(".snippet-title-custom").text(e.target.value),jQuery(".snippet-title").css("display","none"),jQuery(".snippet-title-custom").css("display","block"),jQuery(".snippet-title-default").css("display","none")):0==s.length&&(jQuery(".snippet-title-default").css("display","block"),jQuery(".snippet-title-custom").css("display","none"),jQuery(".snippet-title").css("display","none")),s.length)var i=Math.round(pixelTitle(s)/568*100);else i=Math.round(pixelTitle(t)/568*100);i>=100&&(i=100),jQuery("#seopress_titles_title_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_title_counters_progress").text(i+"%"),jQuery("#seopress_titles_title_counters_progress").css("width",i+"%")}function sp_titles_counters(){var e=jQuery("#seopress_titles_title_meta").val(),s=jQuery("#seopress_titles_title_meta").attr("placeholder");if(jQuery("#seopress_titles_title_counters").after('<div id="seopress_titles_title_counters_val">/ 60</div>'),e.length>0?(jQuery("#seopress_titles_title_counters").text(e.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(e))):s.length&&(jQuery("#seopress_titles_title_counters").text(s.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(s))),e.length>60?jQuery("#seopress_titles_title_counters").css("color","red"):s.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(e)>568?jQuery("#seopress_titles_title_pixel").css("color","red"):pixelTitle(s)>568&&jQuery("#seopress_titles_title_pixel").css("color","red"),e.length)var t=Math.round(pixelTitle(e)/568*100);else t=Math.round(pixelTitle(s)/568*100);t>=100&&(t=100),jQuery("#seopress_titles_title_counters_progress").attr("aria-valuenow",t),jQuery("#seopress_titles_title_counters_progress").text(t+"%"),jQuery("#seopress_titles_title_counters_progress").css("width",t+"%")}function sp_meta_desc_counters(){var e=jQuery("#seopress_titles_desc_meta").val(),s=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(jQuery("#seopress_titles_desc_counters").after('<div id="seopress_titles_desc_counters_val">/ 160</div>'),e.length>0?(jQuery("#seopress_titles_desc_counters").text(e.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(e))):s.length&&(jQuery("#seopress_titles_desc_counters").text(s.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(s))),e.length>160?jQuery("#seopress_titles_desc_counters").css("color","red"):s.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(e)>940?jQuery("#seopress_titles_desc_pixel").css("color","red"):pixelDesc(s)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red"),e.length)var t=Math.round(pixelDesc(e)/940*100);else t=Math.round(pixelDesc(s)/940*100);t>=100&&(t=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",t),jQuery("#seopress_titles_desc_counters_progress").text(t+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",t+"%"),jQuery("#seopress_titles_desc_meta, #seopress-tag-single-excerpt").on("keyup paste change click",function(e){var s=jQuery("#seopress_titles_desc_meta").val(),t=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(jQuery("#seopress_titles_desc_counters").css("color","inherit"),jQuery("#seopress_titles_desc_pixel").css("color","inherit"),s.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(s)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red"),0==s.length&&(t.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(t)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red")),s.length>0?(jQuery("#seopress_titles_desc_counters").text(s.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(s))):t.length&&(jQuery("#seopress_titles_desc_counters").text(t.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(t))),s.length>0?(jQuery(".snippet-description-custom").text(e.target.value),jQuery(".snippet-description").css("display","none"),jQuery(".snippet-description-custom").css("display","inline"),jQuery(".snippet-description-default").css("display","none")):0==s.length&&(jQuery(".snippet-description-default").css("display","inline"),jQuery(".snippet-description-custom").css("display","none"),jQuery(".snippet-description").css("display","none")),s.length)var i=Math.round(pixelDesc(s)/940*100);else i=Math.round(pixelDesc(t)/940*100);i>=100&&(i=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_desc_counters_progress").text(i+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",i+"%")}),jQuery("#excerpt, .editor-post-excerpt textarea").keyup(function(e){var s=jQuery("#seopress_titles_desc_meta").val(),t=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(0==s.length&&0==jQuery(".snippet-description-custom").val().length&&(jQuery(".snippet-description-custom").text(e.target.value),jQuery(".snippet-description").css("display","none"),jQuery(".snippet-description-custom").css("display","inline"),jQuery(".snippet-description-default").css("display","none")),s.length)var i=s.length;else i=t.length;i>=100&&(i=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_desc_counters_progress").text(i+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",i+"%")})}function pixelTitle(e){return inputText=e,font="18px Arial",canvas=document.createElement("canvas"),context=canvas.getContext("2d"),context.font=font,width=context.measureText(inputText).width,formattedWidth=Math.ceil(width),formattedWidth}function pixelDesc(e){return inputText=e,font="14px Arial",canvas=document.createElement("canvas"),context=canvas.getContext("2d"),context.font=font,width=context.measureText(inputText).width,formattedWidth=Math.ceil(width),formattedWidth}function sp_social(){jQuery("#seopress_social_fb_title_meta, #seopress-tag-single-title, #seopress-tag-single-site-title, #seopress-tag-single-sep").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_title_meta").val();s.length>0?(jQuery(".snippet-fb-title-custom").text(e.target.value),jQuery(".snippet-fb-title").css("display","none"),jQuery(".snippet-fb-title-custom").css("display","block"),jQuery(".snippet-fb-title-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-title-default").css("display","block"),jQuery(".snippet-fb-title-custom").css("display","none"),jQuery(".snippet-fb-title").css("display","none"))}),jQuery("#seopress_social_fb_desc_meta").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_desc_meta").val();s.length>0?(jQuery(".snippet-fb-description-custom").text(e.target.value),jQuery(".snippet-fb-description").css("display","none"),jQuery(".snippet-fb-description-custom").css("display","block"),jQuery(".snippet-fb-description-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-description-default").css("display","block"),jQuery(".snippet-fb-description-custom").css("display","none"),jQuery(".snippet-fb-description").css("display","none"))}),jQuery("#seopress_social_fb_img_meta").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_img_meta").val();s.length>0?(jQuery(".snippet-fb-img-custom img").attr("src",e.target.value),jQuery(".snippet-fb-img").css("display","none"),jQuery(".snippet-fb-img-custom").css("display","block"),jQuery(".snippet-fb-img-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-img-default").css("display","block"),jQuery(".snippet-fb-img-custom").css("display","none"),jQuery(".snippet-fb-img").css("display","none"))})}function sp_ca_toggle(){var e=!1;jQuery(".gr-analysis-title .btn-toggle").on("click",function(s){e&&(event.stopImmediatePropagation(),event.preventDefault(),e=!1),jQuery(this).toggleClass("open"),jQuery(this).parent().parent().next(".gr-analysis-content").toggle()}),jQuery("#expand-all").on("click",function(e){e.preventDefault(),jQuery(".gr-analysis-content").show()}),jQuery("#close-all").on("click",function(e){e.preventDefault(),jQuery(".gr-analysis-content").hide()})}jQuery(document).ready(function(e){function s(){e.ajax({method:"GET",url:seopressAjaxRealPreview.seopress_real_preview,data:{action:"seopress_do_real_preview",post_id:e("#seopress-tabs").attr("data_id"),tax_name:e("#seopress-tabs").attr("data_tax"),origin:e("#seopress-tabs").attr("data_origin"),post_type:e("#seopress_launch_analysis").attr("data_post_type"),seopress_analysis_target_kw:e("#seopress_analysis_target_kw_meta").val(),_ajax_nonce:seopressAjaxRealPreview.seopress_nonce},beforeSend:function(){e(".analysis-score p span").fadeIn().text(seopressAjaxRealPreview.i18n.progress),e(".analysis-score p").addClass("loading")},success:function(s){void 0===s.data.og_title?og_title="":og_title=s.data.og_title.values,void 0===s.data.og_desc?og_desc="":og_desc=s.data.og_desc.values,void 0===s.data.og_img?og_img="":og_img=s.data.og_img.values,void 0===s.data.og_url?og_url="":og_url=s.data.og_url.host,void 0===s.data.og_site_name?og_site_name="":og_site_name=s.data.og_site_name.values,void 0===s.data.tw_title?tw_title="":tw_title=s.data.tw_title.values,void 0===s.data.tw_desc?tw_desc="":tw_desc=s.data.tw_desc.values,void 0===s.data.tw_img?tw_img="":tw_img=s.data.tw_img.values;var t={og_title:og_title,og_desc:og_desc,og_img:og_img,og_url:og_url,og_site_name:og_site_name,tw_title:tw_title,tw_desc:tw_desc,tw_img:tw_img};for(var i in t)t.length&&(i=t[i].length>1?t[i].slice(-1)[0]:t[i][0]);e("#seopress_cpt .google-snippet-preview .snippet-title").html(s.data.title),e("#seopress_cpt .google-snippet-preview .snippet-title-default").html(s.data.title),e("#seopress_titles_title_meta").attr("placeholder",s.data.title),e("#seopress_cpt .google-snippet-preview .snippet-description").html(s.data.meta_desc),e("#seopress_cpt .google-snippet-preview .snippet-description-default").html(s.data.meta_desc),e("#seopress_titles_desc_meta").attr("placeholder",s.data.meta_desc),e("#seopress_cpt #seopress_social_fb_title_meta").attr("placeholder",t.og_title),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-title").html(t.og_title),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-title-default").html(t.og_title),e("#seopress_cpt #seopress_social_fb_desc_meta").attr("placeholder",t.og_desc),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-description").html(t.og_desc),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-description-default").html(t.og_desc),e("#seopress_cpt #seopress_social_fb_img_meta").attr("placeholder",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-img img").attr("src",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-img-default img").attr("src",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-url").html(t.og_url),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-site-name").html(t.og_site_name),e("#seopress_cpt #seopress_social_twitter_title_meta").attr("placeholder",t.tw_title),e("#seopress_cpt #seopress_social_twitter_desc_meta").attr("placeholder",t.tw_desc),e("#seopress_cpt #seopress_social_twitter_img_meta").attr("placeholder",t.tw_img),e("#seopress_cpt #seopress_robots_canonical_meta").attr("placeholder",s.data.canonical),e("#seopress-analysis-tabs").load(" #seopress-analysis-tabs-1","",sp_ca_toggle),e(".analysis-score p").removeClass("loading"),e(" #seopress_titles_title_counters_val").remove(),e(" #seopress_titles_desc_counters_val").remove(),sp_titles_counters(),sp_meta_desc_counters(),sp_social()}})}s(),e("#seopress_launch_analysis").on("click",function(){s()}),sp_ca_toggle()});
1
+ function sp_titles_counters(){var e=jQuery("#seopress_titles_title_meta").val(),s=jQuery("#seopress_titles_title_meta").attr("placeholder");if(jQuery("#seopress_titles_title_counters").after('<div id="seopress_titles_title_counters_val">/ 60</div>'),e.length>0?(jQuery("#seopress_titles_title_counters").text(e.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(e))):s.length&&(jQuery("#seopress_titles_title_counters").text(s.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(s))),e.length>60?jQuery("#seopress_titles_title_counters").css("color","red"):s.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(e)>568?jQuery("#seopress_titles_title_pixel").css("color","red"):pixelTitle(s)>568&&jQuery("#seopress_titles_title_pixel").css("color","red"),e.length)var t=Math.round(pixelTitle(e)/568*100);else t=Math.round(pixelTitle(s)/568*100);t>=100&&(t=100),jQuery("#seopress_titles_title_counters_progress").attr("aria-valuenow",t),jQuery("#seopress_titles_title_counters_progress").text(t+"%"),jQuery("#seopress_titles_title_counters_progress").css("width",t+"%"),jQuery("#seopress_titles_title_meta, #seopress-tag-single-title, #seopress-tag-single-site-title, #seopress-tag-single-sep").on("keyup paste change click",function(e){var s=jQuery("#seopress_titles_title_meta").val(),t=jQuery("#seopress_titles_title_meta").attr("placeholder");if(jQuery("#seopress_titles_title_counters").css("color","inherit"),jQuery("#seopress_titles_title_pixel").css("color","inherit"),s.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(s)>568&&jQuery("#seopress_titles_title_pixel").css("color","red"),0==s.length&&(t.length>60&&jQuery("#seopress_titles_title_counters").css("color","red"),pixelTitle(t)>568&&jQuery("#seopress_titles_title_pixel").css("color","red")),s.length>0?(jQuery("#seopress_titles_title_counters").text(s.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(s))):t.length&&(jQuery("#seopress_titles_title_counters").text(t.length),jQuery("#seopress_titles_title_pixel").text(pixelTitle(t))),s.length>0?(jQuery(".snippet-title-custom").text(e.target.value),jQuery(".snippet-title").css("display","none"),jQuery(".snippet-title-custom").css("display","block"),jQuery(".snippet-title-default").css("display","none")):0==s.length&&(jQuery(".snippet-title-default").css("display","block"),jQuery(".snippet-title-custom").css("display","none"),jQuery(".snippet-title").css("display","none")),s.length)var i=Math.round(pixelTitle(s)/568*100);else i=Math.round(pixelTitle(t)/568*100);i>=100&&(i=100),jQuery("#seopress_titles_title_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_title_counters_progress").text(i+"%"),jQuery("#seopress_titles_title_counters_progress").css("width",i+"%")})}function sp_meta_desc_counters(){var e=jQuery("#seopress_titles_desc_meta").val(),s=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(jQuery("#seopress_titles_desc_counters").after('<div id="seopress_titles_desc_counters_val">/ 160</div>'),e.length>0?(jQuery("#seopress_titles_desc_counters").text(e.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(e))):s.length&&(jQuery("#seopress_titles_desc_counters").text(s.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(s))),e.length>160?jQuery("#seopress_titles_desc_counters").css("color","red"):s.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(e)>940?jQuery("#seopress_titles_desc_pixel").css("color","red"):pixelDesc(s)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red"),e.length)var t=Math.round(pixelDesc(e)/940*100);else t=Math.round(pixelDesc(s)/940*100);t>=100&&(t=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",t),jQuery("#seopress_titles_desc_counters_progress").text(t+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",t+"%"),jQuery("#seopress_titles_desc_meta, #seopress-tag-single-excerpt").on("keyup paste change click",function(e){var s=jQuery("#seopress_titles_desc_meta").val(),t=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(jQuery("#seopress_titles_desc_counters").css("color","inherit"),jQuery("#seopress_titles_desc_pixel").css("color","inherit"),s.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(s)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red"),0==s.length&&(t.length>160&&jQuery("#seopress_titles_desc_counters").css("color","red"),pixelDesc(t)>940&&jQuery("#seopress_titles_desc_pixel").css("color","red")),s.length>0?(jQuery("#seopress_titles_desc_counters").text(s.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(s))):t.length&&(jQuery("#seopress_titles_desc_counters").text(t.length),jQuery("#seopress_titles_desc_pixel").text(pixelDesc(t))),s.length>0?(jQuery(".snippet-description-custom").text(e.target.value),jQuery(".snippet-description").css("display","none"),jQuery(".snippet-description-custom").css("display","inline"),jQuery(".snippet-description-default").css("display","none")):0==s.length&&(jQuery(".snippet-description-default").css("display","inline"),jQuery(".snippet-description-custom").css("display","none"),jQuery(".snippet-description").css("display","none")),s.length)var i=Math.round(pixelDesc(s)/940*100);else i=Math.round(pixelDesc(t)/940*100);i>=100&&(i=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_desc_counters_progress").text(i+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",i+"%")}),jQuery("#excerpt, .editor-post-excerpt textarea").keyup(function(e){var s=jQuery("#seopress_titles_desc_meta").val(),t=jQuery("#seopress_titles_desc_meta").attr("placeholder");if(0==s.length&&0==jQuery(".snippet-description-custom").val().length&&(jQuery(".snippet-description-custom").text(e.target.value),jQuery(".snippet-description").css("display","none"),jQuery(".snippet-description-custom").css("display","inline"),jQuery(".snippet-description-default").css("display","none")),s.length)var i=s.length;else i=t.length;i>=100&&(i=100),jQuery("#seopress_titles_desc_counters_progress").attr("aria-valuenow",i),jQuery("#seopress_titles_desc_counters_progress").text(i+"%"),jQuery("#seopress_titles_desc_counters_progress").css("width",i+"%")})}function pixelTitle(e){return inputText=e,font="18px Arial",canvas=document.createElement("canvas"),context=canvas.getContext("2d"),context.font=font,width=context.measureText(inputText).width,formattedWidth=Math.ceil(width),formattedWidth}function pixelDesc(e){return inputText=e,font="14px Arial",canvas=document.createElement("canvas"),context=canvas.getContext("2d"),context.font=font,width=context.measureText(inputText).width,formattedWidth=Math.ceil(width),formattedWidth}function sp_social(){jQuery("#seopress_social_fb_title_meta, #seopress-tag-single-title, #seopress-tag-single-site-title, #seopress-tag-single-sep").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_title_meta").val();s.length>0?(jQuery(".snippet-fb-title-custom").text(e.target.value),jQuery(".snippet-fb-title").css("display","none"),jQuery(".snippet-fb-title-custom").css("display","block"),jQuery(".snippet-fb-title-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-title-default").css("display","block"),jQuery(".snippet-fb-title-custom").css("display","none"),jQuery(".snippet-fb-title").css("display","none"))}),jQuery("#seopress_social_fb_desc_meta").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_desc_meta").val();s.length>0?(jQuery(".snippet-fb-description-custom").text(e.target.value),jQuery(".snippet-fb-description").css("display","none"),jQuery(".snippet-fb-description-custom").css("display","block"),jQuery(".snippet-fb-description-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-description-default").css("display","block"),jQuery(".snippet-fb-description-custom").css("display","none"),jQuery(".snippet-fb-description").css("display","none"))}),jQuery("#seopress_social_fb_img_meta").on("keyup paste change click",function(e){var s=jQuery("#seopress_social_fb_img_meta").val();s.length>0?(jQuery(".snippet-fb-img-custom img").attr("src",e.target.value),jQuery(".snippet-fb-img").css("display","none"),jQuery(".snippet-fb-img-custom").css("display","block"),jQuery(".snippet-fb-img-default").css("display","none")):0==s.length&&(jQuery(".snippet-fb-img-default").css("display","block"),jQuery(".snippet-fb-img-custom").css("display","none"),jQuery(".snippet-fb-img").css("display","none"))})}function sp_ca_toggle(){var e=!1;jQuery(".gr-analysis-title .btn-toggle").on("click",function(s){e&&(event.stopImmediatePropagation(),event.preventDefault(),e=!1),jQuery(this).toggleClass("open"),jQuery(this).parent().parent().next(".gr-analysis-content").toggle()}),jQuery("#expand-all").on("click",function(e){e.preventDefault(),jQuery(".gr-analysis-content").show()}),jQuery("#close-all").on("click",function(e){e.preventDefault(),jQuery(".gr-analysis-content").hide()})}jQuery(document).ready(function(e){function s(){e.ajax({method:"GET",url:seopressAjaxRealPreview.seopress_real_preview,data:{action:"seopress_do_real_preview",post_id:e("#seopress-tabs").attr("data_id"),tax_name:e("#seopress-tabs").attr("data_tax"),origin:e("#seopress-tabs").attr("data_origin"),post_type:e("#seopress_launch_analysis").attr("data_post_type"),seopress_analysis_target_kw:e("#seopress_analysis_target_kw_meta").val(),_ajax_nonce:seopressAjaxRealPreview.seopress_nonce},beforeSend:function(){e(".analysis-score p span").fadeIn().text(seopressAjaxRealPreview.i18n.progress),e(".analysis-score p").addClass("loading")},success:function(s){void 0===s.data.og_title?og_title="":og_title=s.data.og_title.values,void 0===s.data.og_desc?og_desc="":og_desc=s.data.og_desc.values,void 0===s.data.og_img?og_img="":og_img=s.data.og_img.values,void 0===s.data.og_url?og_url="":og_url=s.data.og_url.host,void 0===s.data.og_site_name?og_site_name="":og_site_name=s.data.og_site_name.values,void 0===s.data.tw_title?tw_title="":tw_title=s.data.tw_title.values,void 0===s.data.tw_desc?tw_desc="":tw_desc=s.data.tw_desc.values,void 0===s.data.tw_img?tw_img="":tw_img=s.data.tw_img.values;var t={og_title:og_title,og_desc:og_desc,og_img:og_img,og_url:og_url,og_site_name:og_site_name,tw_title:tw_title,tw_desc:tw_desc,tw_img:tw_img};for(var i in t)t.length&&(i=t[i].length>1?t[i].slice(-1)[0]:t[i][0]);e("#seopress_cpt .google-snippet-preview .snippet-title").html(s.data.title),e("#seopress_cpt .google-snippet-preview .snippet-title-default").html(s.data.title),e("#seopress_titles_title_meta").attr("placeholder",s.data.title),e("#seopress_cpt .google-snippet-preview .snippet-description").html(s.data.meta_desc),e("#seopress_cpt .google-snippet-preview .snippet-description-default").html(s.data.meta_desc),e("#seopress_titles_desc_meta").attr("placeholder",s.data.meta_desc),e("#seopress_cpt #seopress_social_fb_title_meta").attr("placeholder",t.og_title),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-title").html(t.og_title),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-title-default").html(t.og_title),e("#seopress_cpt #seopress_social_fb_desc_meta").attr("placeholder",t.og_desc),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-description").html(t.og_desc),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-description-default").html(t.og_desc),e("#seopress_cpt #seopress_social_fb_img_meta").attr("placeholder",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-img img").attr("src",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-img-default img").attr("src",t.og_img),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-url").html(t.og_url),e("#seopress_cpt .facebook-snippet-preview .snippet-fb-site-name").html(t.og_site_name),e("#seopress_cpt #seopress_social_twitter_title_meta").attr("placeholder",t.tw_title),e("#seopress_cpt #seopress_social_twitter_desc_meta").attr("placeholder",t.tw_desc),e("#seopress_cpt #seopress_social_twitter_img_meta").attr("placeholder",t.tw_img),e("#seopress_cpt #seopress_robots_canonical_meta").attr("placeholder",s.data.canonical),e("#seopress-analysis-tabs").load(" #seopress-analysis-tabs-1","",sp_ca_toggle),e(".analysis-score p").removeClass("loading"),e(" #seopress_titles_title_counters_val").remove(),e(" #seopress_titles_desc_counters_val").remove(),sp_titles_counters(),sp_meta_desc_counters(),sp_social()}})}s(),e("#seopress_launch_analysis").on("click",function(){s()}),sp_ca_toggle()});
inc/functions/sitemap/template-xml-sitemaps-single.php CHANGED
@@ -120,7 +120,11 @@ function seopress_xml_sitemap_single() {
120
  $seopress_sitemaps .= '</loc>';
121
  $seopress_sitemaps .= "\n";
122
  $seopress_sitemaps .= '<lastmod>';
123
- $seopress_sitemaps .= get_the_modified_date('c', $post);
 
 
 
 
124
  $seopress_sitemaps .= '';
125
  $seopress_sitemaps .= '</lastmod>';
126
  $seopress_sitemaps .= "\n";
120
  $seopress_sitemaps .= '</loc>';
121
  $seopress_sitemaps .= "\n";
122
  $seopress_sitemaps .= '<lastmod>';
123
+ if (get_the_modified_date('c', $post)) {
124
+ $seopress_sitemaps .= get_the_modified_date('c', $post);
125
+ } else {
126
+ $seopress_sitemaps .= get_post_modified_time('c', false, $post);
127
+ }
128
  $seopress_sitemaps .= '';
129
  $seopress_sitemaps .= '</lastmod>';
130
  $seopress_sitemaps .= "\n";
readme.txt CHANGED
@@ -6,7 +6,7 @@ Tags: SEO, XML sitemap, meta title, open graph, content analysis, knowledge grap
6
  Requires at least: 4.7+
7
  Tested up to: 5.3
8
  Requires PHP: 5.6
9
- Stable tag: 3.8.0.2
10
  License: GPLv2 or later
11
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -210,68 +210,18 @@ You're theme is probably using a deprecated function to handle the title. <a hre
210
  <a href="https://www.seopress.org/support/faq/" target="_blank">Read our complete FAQ on our site</a>
211
 
212
  == Screenshots ==
213
- 1. SEOPress Dashboard
214
- 2. Titles & Metas
215
- 3. Titles & Metas
216
- 4. Titles & Metas
217
- 5. Titles & Metas
218
- 6. Titles & Metas
219
- 7. XML Sitemap
220
- 8. XML Sitemap
221
- 9. XML Sitemap
222
- 10. HTML Sitemap
223
- 11. Social Networks
224
- 12. Social Networks
225
- 13. Social Networks
226
- 14. Social Networks
227
- 15. Google Analytics
228
- 16. Google Analytics
229
- 17. Google Analytics
230
- 18. Google Analytics
231
- 19. Google Analytics
232
- 20. Advanced settings
233
- 21. Advanced settings
234
- 22. Advanced settings
235
- 23. Tools: Import / Export / Reset settings
236
- 24. SEOPress Bot : scan (PRO)
237
- 25. SEOPress Bot : settings (PRO)
238
- 26. License settings (PRO)
239
- 27. Google Local Business (PRO)
240
- 28. Dublin Core (PRO)
241
- 29. Structured Data Types (PRO)
242
- 30. Breadcrumbs (PRO)
243
- 31. WooCommerce (PRO)
244
- 32. Easy Digital Downloads (PRO)
245
- 33. Google Page Speed (PRO)
246
- 34. Robots.txt (PRO)
247
- 35. Google News Sitemap (PRO)
248
- 36. Monitoring 404 (PRO)
249
- 37. htaccess (PRO)
250
- 38. RSS (PRO)
251
- 39. Backlinks (PRO)
252
- 40. URL Rewriting (PRO)
253
- 41. White Label (PRO)
254
- 42. Schemas (PRO)
255
- 43. Schemas (PRO)
256
- 44. Redirections (PRO)
257
- 45. Redirections (PRO)
258
- 46. Broken links (PRO)
259
- 47. SEO metabox
260
- 48. SEO metabox
261
- 49. SEO metabox
262
- 50. SEO metabox
263
- 51. SEO metabox
264
- 52. SEO metabox
265
- 53. Content analysis metabox
266
- 54. Content analysis metabox
267
- 55. Content analysis metabox
268
- 56. Content analysis metabox
269
- 57. Google Structured data types (PRO)
270
- 58. Google Structured data types (PRO)
271
- 59. Installation Wizard
272
- 60. Installation Wizard
273
 
274
  == Changelog ==
 
 
 
275
  = 3.8.0.2 =
276
  * FIX XML Image sitemaps
277
  = 3.8.0.1 =
6
  Requires at least: 4.7+
7
  Tested up to: 5.3
8
  Requires PHP: 5.6
9
+ Stable tag: 3.8.0.3
10
  License: GPLv2 or later
11
  License URI: https://www.gnu.org/licenses/gpl-2.0.html
12
 
210
  <a href="https://www.seopress.org/support/faq/" target="_blank">Read our complete FAQ on our site</a>
211
 
212
  == Screenshots ==
213
+ 1. SEOPress notifications center
214
+ 2. SEOPress dashboard
215
+ 3. SEO metabox: Titles settings
216
+ 4. SEO metabox: Social tab
217
+ 5. Content analysis metabox
218
+ 6. SEOPress PRO
219
+ 7. Installation Wizard
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
220
 
221
  == Changelog ==
222
+ = 3.8.0.3 =
223
+ * INFO Add a fallback for get modified post date in xml sitemaps
224
+ * FIX JS file for SEO metabox
225
  = 3.8.0.2 =
226
  * FIX XML Image sitemaps
227
  = 3.8.0.1 =
seopress.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: SEOPress
4
  Plugin URI: https://www.seopress.org/
5
  Description: One of the best SEO plugins for WordPress.
6
- Version: 3.8.0.2
7
  Author: SEOPress
8
  Author URI: https://www.seopress.org/
9
  License: GPLv2
@@ -53,7 +53,7 @@ register_deactivation_hook(__FILE__, 'seopress_deactivation');
53
  ///////////////////////////////////////////////////////////////////////////////////////////////////
54
  //Define
55
  ///////////////////////////////////////////////////////////////////////////////////////////////////
56
- define( 'SEOPRESS_VERSION', '3.8.0.2' );
57
  define( 'SEOPRESS_AUTHOR', 'Benjamin Denis' );
58
 
59
  ///////////////////////////////////////////////////////////////////////////////////////////////////
3
  Plugin Name: SEOPress
4
  Plugin URI: https://www.seopress.org/
5
  Description: One of the best SEO plugins for WordPress.
6
+ Version: 3.8.0.3
7
  Author: SEOPress
8
  Author URI: https://www.seopress.org/
9
  License: GPLv2
53
  ///////////////////////////////////////////////////////////////////////////////////////////////////
54
  //Define
55
  ///////////////////////////////////////////////////////////////////////////////////////////////////
56
+ define( 'SEOPRESS_VERSION', '3.8.0.3' );
57
  define( 'SEOPRESS_AUTHOR', 'Benjamin Denis' );
58
 
59
  ///////////////////////////////////////////////////////////////////////////////////////////////////