[pLog-svn] r6555 - plog/branches/lifetype-1.2/bin-devel
jondaley at devel.lifetype.net
jondaley at devel.lifetype.net
Sun Jun 15 07:20:03 EDT 2008
Author: jondaley
Date: 2008-06-15 07:20:03 -0400 (Sun, 15 Jun 2008)
New Revision: 6555
Added:
plog/branches/lifetype-1.2/bin-devel/testlocale.php
Log:
sanity checker for new locales
Added: plog/branches/lifetype-1.2/bin-devel/testlocale.php
===================================================================
--- plog/branches/lifetype-1.2/bin-devel/testlocale.php (rev 0)
+++ plog/branches/lifetype-1.2/bin-devel/testlocale.php 2008-06-15 11:20:03 UTC (rev 6555)
@@ -0,0 +1,31 @@
+<?
+
+if(!$argv[1]){
+ print "Please put a locale name on the command line, e.g. ".$argv[0]." en_UK\n";
+ die;
+}
+
+$locale = preg_replace("/[^a-z_]/i", "", $argv[1]);
+
+
+// PUBLIC
+$file = "locale_$locale.php";
+if(!file_exists($file))
+ die("Can't find $file\n");
+include($file);
+print "Locale description: " . $messages["locale_description"]."\n";
+print "Encoding: " . $messages["encoding"]."\n";
+print "An error string as a sanity check: " . $messages["error_incorrect_search_terms"]."\n";
+unset($messages);
+
+
+// ADMIN
+$file = "admin/locale_$locale.php";
+if(!file_exists($file))
+ die("Can't find $file\n");
+include($file);
+print "Welcome: " . $messages["welcome_message"]."\n";
+print "Random Help String: " . $messages["help_notify_new_blogs"]."\n";
+
+
+?>
\ No newline at end of file
More information about the pLog-svn
mailing list