Welcome to Geeklog, Anonymous Wednesday, December 25 2024 @ 12:15 am EST
Geeklog Forums
Calendar not showing abreviated version of dag in mini cal
Status: offline
Rick78
Forum User
Regular Poster
Registered: 10/20/03
Posts: 98
Hello,
On the top of the calendar page are two small calendars for previous and next months,
The days above these are abbreviated with 2 letters. Two of the days are not abbreviated.
The reason for this is the second letter in each of these days are of another language.
The days are Sunday, which is Søndag in Danish and Saturday, which is Lørdag.
Both days are written in full, and mess the calendar up.
How can I fix this?
Thanks,
Rick
On the top of the calendar page are two small calendars for previous and next months,
The days above these are abbreviated with 2 letters. Two of the days are not abbreviated.
The reason for this is the second letter in each of these days are of another language.
The days are Sunday, which is Søndag in Danish and Saturday, which is Lørdag.
Both days are written in full, and mess the calendar up.
How can I fix this?
Thanks,
Rick
8
6
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
It may have something to do with the fact that there's a national special character as the second character in those weekday names. The labels for the mini calendar are using the first two characters from the weekdays in the $LANG_WEEK array.
Which character set is your site running on? UTF-8 or something else?
bye, Dirk
Which character set is your site running on? UTF-8 or something else?
bye, Dirk
9
6
Quote
Status: offline
Rick78
Forum User
Regular Poster
Registered: 10/20/03
Posts: 98
Hi Dirk,
Thanks for the reply. I am a bit unsure how a character set is chosen. It seems as if I am using iso-8859-1.
How can I be sure which is chosen?
My config.php states:
$_CONF['language'] = 'danish';
$_CONF['default_charset'] = 'iso-8859-1';
So I would assume that it is iso-8859-1.
Regards,
Rick
Thanks for the reply. I am a bit unsure how a character set is chosen. It seems as if I am using iso-8859-1.
How can I be sure which is chosen?
My config.php states:
$_CONF['language'] = 'danish';
$_CONF['default_charset'] = 'iso-8859-1';
So I would assume that it is iso-8859-1.
Regards,
Rick
24
9
Quote
Status: offline
Dirk
Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Okay, I think I found the problem. lib-mbyte.php is using the multi-byte versions of the string functions even when it isn't necessary.
Try this: In system/lib-mbyte.php, replace the function MBYTE_checkEnabled() with this version:
{
global $LANG_CHARSET;
static $mb_enabled;
if (strcasecmp($LANG_CHARSET, 'utf-8') == 0) {
if (function_exists( 'mb_eregi_replace' )) {
$mb_enabled = mb_internal_encoding("UTF-8");
} else {
$mb_enabled = false;
}
} else {
$mb_enabled = false;
}
return $mb_enabled;
}
bye, Dirk
Try this: In system/lib-mbyte.php, replace the function MBYTE_checkEnabled() with this version:
Text Formatted Code
function MBYTE_checkEnabled(){
global $LANG_CHARSET;
static $mb_enabled;
if (strcasecmp($LANG_CHARSET, 'utf-8') == 0) {
if (function_exists( 'mb_eregi_replace' )) {
$mb_enabled = mb_internal_encoding("UTF-8");
} else {
$mb_enabled = false;
}
} else {
$mb_enabled = false;
}
return $mb_enabled;
}
bye, Dirk
8
6
Quote
All times are EST. The time is now 12:15 am.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content