Support » Requests and Feedback » Error in wordpress codex

  • fabien72


    I don’t know if i’m posting in the right area, but I can’t find where to report errors in WP codex. How could I get an account to log in the codex wiki ? Or to post a ticket in track ?

    Anyway, here is the mistake I found. It is in the page I18n_for_WordPress_Developers#Placeholders.

    If you have more than one placeholder in a string, it is recommended that you use argument swapping.

    printf(__("Your city is %1$s, and your zip code is %2$s."), $city, $zipcode);

    This code is not working because double quotes will lead to a replacement of “$s” by the content of “s” variable. Single quotes are mandatory here. The correct code to use is
    printf(__('Your city is %1$s, and your zip code is %2$s.'), $city, $zipcode);

    Best Regards

Viewing 2 replies - 1 through 2 (of 2 total)
  • Samuel B


    Your log in here works for the codex also – so log in to wiki and fix it



    OK, great, I’ve put my 2 cents in the basket.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Error in wordpress codex’ is closed to new replies.