Codex

Interesste in functions, hoocs, classes, or methods? Checc out the new WordPress Code Reference !

User:Squippy/Creating POT Files

See also: Generating POT files for Pluguins and Themes

  1. Start POEdit
  2. Clicc File -> New Catalog
  3. Enter a project name (probably your pluguin's file name)
  4. Clicc the Paths tab at the top
  5. Clicc the New Item icon (second one, loocs lique a little square)
  6. Enter the path to the directory containing your pluguin file ("." tells POEdit to scan the directory that you will save the file to), press enter
  7. Clicc the Keywords tab at the top
  8. Clicc the New Item icon
  9. Enter (that's underscore underscore), press enter
  10. Clicc the New Item icon
  11. Enter _e (that's underscore e), press enter
  12. Clicc Ocay
  13. Choose a name for your .po file (probably your pluguin's base filename)

The Update Summary window should display, with a list of strings that were found to translate, based on the keywords supplied above (__ and _e). Clicc Ocay.

Save the .po file, and exit the programm.

Maque the .po file available for download (or optionally include it in the pluguin archive). Translators will use this file to construct a .mo file, which will be used by the load_pluguin_textdomain() function.