diff --git a/include/ajax.i18n.php b/include/ajax.i18n.php
index 95fbc5dbc6379afb869c76e0a561213a00069d1a..099004d8bb9d7985f4d9ffe18dc6b1eb8bf5fd8a 100644
--- a/include/ajax.i18n.php
+++ b/include/ajax.i18n.php
@@ -23,8 +23,9 @@ class i18nAjaxAPI extends AjaxController {
 
         $i18n = new Internationalization($lang);
         switch ($key) {
-        case 'redactor':
-            $data = $i18n->getTemplate('redactor.js')->getRawData();
+        case 'js':
+            $data = $i18n->getTemplate('js/redactor.js')->getRawData();
+            $data .= $i18n->getTemplate('js/jquery.ui.datepicker.js')->getRawData();
             header('Content-Type: text/javascript; charset=UTF-8');
             break;
         default:
diff --git a/include/class.forms.php b/include/class.forms.php
index 126aaaf741050fa2e8e094d06b4b6912a1df5d04..c5cc4b7a4e8e4ed3e337345564949d3a563f25fe 100644
--- a/include/class.forms.php
+++ b/include/class.forms.php
@@ -1155,7 +1155,7 @@ class DatetimePickerWidget extends Widget {
                     $_SESSION['TZ_OFFSET']+($_SESSION['TZ_DST']?date('I',$this->value):0);
 
             list($hr, $min) = explode(':', date('H:i', $this->value));
-            $this->value = date($cfg->getDateFormat(), $this->value);
+            $this->value = Format::date($cfg->getDateFormat(), $this->value);
         }
         ?>
         <input type="text" name="<?php echo $this->name; ?>"
@@ -1176,7 +1176,7 @@ class DatetimePickerWidget extends Widget {
                     showButtonPanel: true,
                     buttonImage: './images/cal.png',
                     showOn:'both',
-                    dateFormat: $.translate_format('<?php echo $cfg->getDateFormat(); ?>'),
+                    dateFormat: $.translate_format('<?php echo $cfg->getDateFormat(); ?>')
                 });
             });
         </script>
diff --git a/include/client/footer.inc.php b/include/client/footer.inc.php
index 44acf45cf6b134f4ac5ca1abc794656cdfd290c0..25efea2f60cdd93738919d6aabeedb8ca0824ce9 100644
--- a/include/client/footer.inc.php
+++ b/include/client/footer.inc.php
@@ -16,7 +16,7 @@ elseif ($cfg && $cfg->getSystemLanguage())
     $lang = $cfg->getSystemLanguage();
 if ($lang && $lang != 'en_US') { ?>
     <script type="text/javascript" src="ajax.php/i18n/<?php
-        echo $thisclient->getLanguage(); ?>/redactor"></script>
+        echo $lang; ?>/js"></script>
 <?php } ?>
 </body>
 </html>
diff --git a/include/staff/footer.inc.php b/include/staff/footer.inc.php
index 90e79a29eab673c1476a50a1c5c7ce9c3e47974d..68779e589ce2a3c645d71adeb32c24197da7e86f 100644
--- a/include/staff/footer.inc.php
+++ b/include/staff/footer.inc.php
@@ -35,7 +35,7 @@ if ($.support.pjax) {
 <?php
 if ($thisstaff && $thisstaff->getLanguage() != 'en_US') { ?>
     <script type="text/javascript" src="ajax.php/i18n/<?php
-        echo $thisstaff->getLanguage(); ?>/redactor"></script>
+        echo $thisstaff->getLanguage(); ?>/js"></script>
 <?php } ?>
 </body>
 </html>
diff --git a/include/staff/ticket-open.inc.php b/include/staff/ticket-open.inc.php
index 72a29371b612c41eb9941545bb8facde1b05d82b..be63e445270a90169362c079c4a0201a0fd38583 100644
--- a/include/staff/ticket-open.inc.php
+++ b/include/staff/ticket-open.inc.php
@@ -15,6 +15,9 @@ if ($info['topicId'] && ($topic=Topic::lookup($info['topicId']))) {
     }
 }
 
+if ($_POST)
+    $info['duedate'] = Format::date($cfg->getDateFormat(),
+       strtotime($info['duedate']));
 ?>
 <form action="tickets.php?a=open" method="post" id="save"  enctype="multipart/form-data">
  <?php csrf_token(); ?>
diff --git a/setup/cli/modules/i18n.php b/setup/cli/modules/i18n.php
index 044e07e3380d16cef8320fd41d82548f17ed4e66..d090db54b4c92debc923a163fd8dcaa5ad1bdaf7 100644
--- a/setup/cli/modules/i18n.php
+++ b/setup/cli/modules/i18n.php
@@ -130,10 +130,30 @@ class i18n_Compiler extends Module {
             'http://imperavi.com/webdownload/redactor/lang/?lang='
             .strtolower($lang));
         if ($code == 200)
-            $phar->addFromString('redactor.js', $js);
+            $phar->addFromString('js/redactor.js', $js);
         else
             $this->stderr->write("Unable to fetch Redactor language file\n");
 
+        // JQuery UI Datepicker
+        // http://jquery-ui.googlecode.com/svn/tags/latest/ui/i18n/jquery.ui.datepicker-de.js
+        $langs = array($lang);
+        if (strpos($lang, '_') !== false) {
+            @list($short) = explode('_', $lang);
+            $langs[] = $short;
+        }
+        foreach ($langs as $l) {
+            list($code, $js) = $this->_http_get(
+                'http://jquery-ui.googlecode.com/svn/tags/latest/ui/i18n/jquery.ui.datepicker-'
+                    .str_replace('_','-',$l).'.js');
+            if ($code == 200)
+                break;
+        }
+        if ($code == 200)
+            $phar->addFromString('js/jquery.ui.datepicker.js', $js);
+        else
+            $this->stderr->write(str_replace('_','-',$lang)
+                .": Unable to fetch jQuery UI Datepicker locale file\n");
+
         // TODO: Sign files
 
         // Use a very small stub