Forums

WordPress SEO by Yoast
[resolved] Too Few arguments error ! (13 posts)

  1. djneo134.1
    Member
    Posted 5 months ago #

    Hi, since this morning, after doing the last update of WordPress SEO by Yoast, I received this message in every post that I wrote :

    Warning: sprintf() [function.sprintf]: Too few arguments in .../wp-content/plugins/wordpress-seo/admin/linkdex/linkdex.php on line 175

    I am using WordPress v3.2.1, and WordPress SEO v1.1

    I am a french user, so maybe this could be a problem with the french language feature...

    How can it be rectify ?

    Thanks

    http://wordpress.org/extend/plugins/wordpress-seo/

  2. Joost de Valk
    Member
    Posted 5 months ago #

    if you change that line 175 to this:

    $keywordStopWord = sprintf(__("The keyword for this page contains one or more %s$1stop words%s$2, consider removing them. Found '\%s'.", 'wordpress-seo' ),"<a href=\"http://en.wikipedia.org/wiki/Stop_words\">", "</a>");

    does it get any better?

  3. saschaelk
    Member
    Posted 5 months ago #

    i have the same problem. the keyword-input is not visible:
    Warning: sprintf() [function.sprintf]: Too few arguments in /is/htdocs/xxxxxxxxxxx/www.xxxxxxxx.com/wp-content/plugins/wordpress-seo/admin/linkdex/linkdex.php on line 175

    withe the new code:
    $keywordStopWord = sprintf(__("The keyword for this page contains one or more %s$1stop words%s$2, consider removing them. Found '\%s'.", 'wordpress-seo' ),"", "");
    same problem :(

    i am using wp 3.2.1 and SEO Version 1.1 DE-Edition

  4. saschaelk
    Member
    Posted 5 months ago #

    Vielleicht auf deutsch? ;)

    Wenn ich in das Feld Fokus Keyword: was eintrage und dann speicher, kommt der Fehler. Wenn da nichts drin steht, dann auch keine Fehlermeldung.
    Ich suche aber generell das Feld "Keywords" - das finde ich nicht.

  5. petervanderdoes
    Member
    Posted 5 months ago #

    Joost:
    $keywordStopWord = sprintf(__("The keyword for this page contains one or more %sstop words%s, consider removing them. Found '\%s'.", 'wordpress-seo' ),"<a href=\"http://en.wikipedia.org/wiki/Stop_words\">", "</a>");

    Has three input fields and you only give it 2.
    %sstop words%s = 2
    Found '\%s' = 1
    Total of three

    Changing it to:
    $keywordStopWord = sprintf(__("The keyword for this page contains one or more %sstop words%s, consider removing them. Found '\%s'.", 'wordpress-seo' ),"<a href=\"http://en.wikipedia.org/wiki/Stop_words\">", "</a>","1");

    Solves it

  6. petervanderdoes
    Member
    Posted 5 months ago #

    Better solution is to substitute the entire function for this one:

    function ScoreKeyword($job, &$results) {
    		$keywordStopWord = __("The keyword for this page contains one or more %sstop words%s, consider removing them. Found '%s'.", 'wordpress-seo' );
    
    		if ( wpseo_stopwords_check( $job["keyword"] ) !== false )
    			$this->SaveScoreResult( $results, 5, sprintf( $keywordStopWord,"<a href=\"http://en.wikipedia.org/wiki/Stop_words\">", "</a>", wpseo_stopwords_check( $job["keyword"] ) ) );
    	}
  7. Joost de Valk
    Member
    Posted 5 months ago #

    Thanks Peter, I was doing something similar but your is actually even cleaner ;)

  8. saschaelk
    Member
    Posted 5 months ago #

    it works. thanks!

    but the keyword-inputfield is away? No more Keywords (meta)?

  9. Joost de Valk
    Member
    Posted 5 months ago #

    It was never there unless you enabled it under SEO -> Dashboard. It's useless though.

  10. kletskater
    Member
    Posted 5 months ago #

    Hee Joost, I always tought my site was high ranked in google because off the keywords.
    What makes my site with particulair keywords outrank other in google?

  11. Joost de Valk
    Member
    Posted 5 months ago #

  12. kletskater
    Member
    Posted 5 months ago #

    Joost, I´ve read your blogs for a year or so and also read you're part about google not using them.
    I still feel myself to be a newby fot I only use wp so shorttly and learning every day.
    I asume keywords ans seach words are 2 different things because when I change keywords in my pages the will rease in google in a few days when seaching for those particulair words.

  13. Joost de Valk
    Member
    Posted 5 months ago #

    Well you're free to use them: go to your SEO -> Dashboard and enable them, they're just not there by default.

Reply

You must log in to post.

About this Plugin

About this Topic