OpenClinica 使用者手冊/彈出式日曆
外觀
安裝完成後,一切正常,但選擇日期的彈出式日曆除外。雖然您使用它,但在嘗試儲存資料時,仍然會收到錯誤訊息“無效日期格式”。這可能是由於您的伺服器區域設定不是英語/美國。
當 Tomcat 安裝時,它會獲取伺服器的區域設定。主要目標是設定環境變數 - user.language - user.country(可能是可選的)嘗試以下方法之一。兩種方法都會更改使用此 Tomcat 服務的所有應用程式的環境變數。
要解決此問題,在 Windows 伺服器上,選擇“程式”,然後選擇“Tomcat”,最後選擇“配置”。轉到“Java”選項卡,並在 Java 選項中新增兩行
-Duser.language=en -Duser.country=US
以下方法適用於 Windows XP,並且可能在其他 Windows 版本上也類似
1. stop your tomcat 2. open a console window (enter 'cmd' into the start menu execute field) 3. go to <tomcat installation directory>\bin 4. execute tomcatw6.exe //ES// 5. add the system variables to your java configuration 6. start your tomcat
儲存新設定並重啟 Tomcat。
如果不存在,請在 /usr/local/tomcat/bin 中建立一個名為 setenv.sh 的新檔案,其中包含以下程式碼
#!/bin/bash JAVA_OPTS="$JAVA_OPTS -Duser.language=en -Duser.country=US"
如果 setenv.sh 存在,請在 setenv.sh(/usr/local/tomcat/bin)中將 -Duser.language=en 和 -Duser.country=US 新增到 JAVA_OPTS 中
重啟 Tomcat
注意:Debian Squeeze 使用者將在 /usr/share/tomcat6/bin 中建立 setenv.sh 檔案。