Support » Plugin: SEOPress » Cannot read property ‘length’ of undefined

  • Hi There,

    seopress-counters.js assumes jQuery("#seopress_titles_title_meta").val().length, however in some cases (custom post types) that field will not exist so an Uncaught TypeError is thrown. This of course causes other issues on the page.

    That section should probably read something like:

    var titles_title_meta_val = jQuery("#seopress_titles_title_meta").val();
    if (titles_title_meta_val) {

    I’d have to check, but once that is fixed there may be other similar issues.



Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Benjamin Denis


    this is known bug and it’s already fixed.
    We’ll push an update ASAP.
    Thank you for your feedback.

    Great thanks!

    Hi There,

    It looks like some issues still remain on the editor screen for custom post types. Check line 4 of seopress-counters.js


    Similar issue as earlier, assuming that #seopress_titles_title_meta exists. Thanks,


    Plugin Author Benjamin Denis


    I’m unable to recreate the bug, can you describe precisely how do you get it? To make sure I set correctly conditional tags in the JS file.
    Thank you!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Cannot read property ‘length’ of undefined’ is closed to new replies.