Translate PHP Define files

WebTranslateIt supports PHP define files.

.php define file example

  define("January", "January");
  # An instruction to translators.
  define("February", "February");
  define("March", "March");
  define("April", "April");
  define("May", "May");
  define("June", "June");
  define("July", "July");
  define("August", "August");
  define("September", "September");
  define("October", "October");
  define("November", "November");
  define("December", "December");
  • Each string must end with a ;.
  • define can be spelt in lowercase or uppercase.
  • Strings can be single quoted or double quoted.
  • If a string is single quoted, single quotes must be escaped.
  • If a string is double quoted, double quotes must be escaped.
  • Instructions can be left to translators by including a line starting by #.
  • The PHP closing tag ?> is optional. If no PHP closing tag is present when importing a file WebTranslateIt will generate files without a closing tag.


  define("January", "January");
  define('January', 'January');
  define("January", 'A \'quoted\' "string"');
  define("January", "A 'quoted' \"string\"");


  define("January", 'A 'quoted' "string"');
  define("January", "A 'quoted' "string"");