Problem
There are two known issues with date formats in ServicePortal showing in US date format regardless of the server or client regional settings:
1. Problem 2255 - Dates on trees are always shown in US format.
2. Problem 3825 - Dates on windows are always shown in US format.
Problem 2255 has been fixed in version 7.2.6 so those on an earlier version can upgrade to fix this, however Problem 3825 is still an issue in 7.2.6 and pending to be fixed in a later release. There is however a manual fix for both of these date problems.
Manual Solution
Before going further you need to know the full culture code that your region uses (and is reconised by IIS). For example the UK is "en-GB", Australia is "en-AU". ServicePortal is configured simply for "en" and this is by default going to use US format. There are lists of other culture codes avaialble at various websites online, one such list is at: http://www.cambiaresearch.com/cambia3/products/datacleanser/help/Content/Culture%20List.htm.
With your "en-XX" code in hand use the following steps to change the format ServicePortal uses for date fields on windows and dates on trees (pre-7.2.6):
1. Open your ServicePortal folder (normally under C:\Inetpub\wwwroot).
2. Take a backup of the Resource.xml, mi_resource.xml and web.config files.
3. Open the web.config file in a text editor.
4. Find the line that reads: <add key="Culture" value="en" />.
5. Modify the line so that "en" now reads your correct full culture as found earlier, ie, <add key="Culture" value="en-GB" />.
6. Save and close the file
7. Open the Resource.xml file in a text editor.
8. Find the line that reads: <cultrue id="en"> (note it reads cultrue, not culture).
9. Modify the line so at "en" matches the culture specified earlier, ie. <cultrue id="en-GB">.
10 Save and close the file.
11. Open the mi_resource.xml file in a text editor.
12. Repeat steps 8-10 for this file.
13. Perform an IIS reset on the server.
The dates will now appear in the correct format for your region. Problem 3825 is still pending to be fixed so the fields do not rely on the web.config Culture setting. This manual solution is only a workaround for the meantime. Thanks to Daniel Perry for helping find this.
Hi Chris,
Good spot! Yes its safe to edit the Cultrue (I have told the developers of this typo, as you would imagine it was taken very well!) and I've updated the article to include it.
Thanks
Hi again Stu
Afraid I've found a bug with this workaround - using the new culture (cultrue) codes seems to break the config/config.aspx page.
I was having an issue trying to log on to the portal config page and narrowed it to something that had changed in the serviceportal folder, so I started looking at changes I'd made. When I reverted this change back to using just the "en" codes, the issue went away.
Can you suggest a way to use the "en-XX" codes but have the config.aspx page work or should this be changed back to use this?
Kind regards
Chris
Hi Chris,
I've had a quick look but I think for now we'll just say you need to change the culture/cultrue back temporarily if you want to access the config pages.
| ||||||
Hi Stu
This worked a treat, but I found that it changed all my chart colours to black, so I had a delve about and noticed that there's a 'Cultrue' code (misspelling intended - why did they spell it like that?) in mi_resource.xml, which I had edited previously to change the service portal chart colours as per another community doc (http://community.landesk.com/support/docs/DOC-1241).
Changing the Cultrue code in this file as well displays the correct colours again - is it OK to edit this code?
Chris