Update of /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/index_libs
In directory usw-pr-cvs1:/tmp/cvs-serv6233/chat/lib/index_libs
Modified Files:
main_index.lib.php3
Log Message:
* Improved detection for full DOM support
* Improved handle of case where pre-defined font face is required
Index: main_index.lib.php3
===================================================================
RCS file: /cvsroot/phpmychat/phpMyChat-0.15/chat/lib/index_libs/main_index.lib.php3,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** main_index.lib.php3 2001/11/30 00:06:15 1.44
--- main_index.lib.php3 2001/11/30 19:30:07 1.45
***************
*** 137,141 ****
// Sets the $isFontMsg to true when the user logs in for the first time and a
// specific font face have to be used (iso-code is 'x-user-defined')
! $isFontMsg = (empty($pmcNick) && defined('L_FONT_NAME'));
$latin1 = (L_CHARSET == 'iso-8859-1') ? 1 : 0;
--- 137,141 ----
// Sets the $isFontMsg to true when the user logs in for the first time and a
// specific font face have to be used (iso-code is 'x-user-defined')
! $isFontMsg = (empty($pmcNick) && defined('L_FONT_PACK'));
$latin1 = (L_CHARSET == 'iso-8859-1') ? 1 : 0;
***************
*** 630,645 ****
var jsIsDOM = (typeof(document.getElementsByTagName) != 'undefined' && typeof(document.createElement) != 'undefined') ? 1 : 0;
! var jsIsIE4 = ((typeof(document.all) != 'undefined') && (parseInt(navigator.appVersion) >= 4) && typeof(window.opera) == 'undefined') ? 1 : 0;
var jsIsNS4 = (typeof(document.layers) != 'undefined') ? 1 : 0;
! var jsWhichVersion = (jsIsDOM ||jsIsIE4 || jsIsNS4) ? 'high' : 'low';
! // Uggly fix for Konqueror that is half DOM compliant
! if (jsWhichVersion == 'high' && typeof(navigator.userAgent) != 'undefined')
{
! var browserName = ' ' + navigator.userAgent.toLowerCase();
! if (browserName.indexOf('konqueror') > 0)
{
! jsIsDOM = 0;
! jsWhichVersion = 'low';
}
}
var jsIsJs11 = (typeof(window.focus) != 'undefined');
--- 630,651 ----
var jsIsDOM = (typeof(document.getElementsByTagName) != 'undefined' && typeof(document.createElement) != 'undefined') ? 1 : 0;
! var jsIsIE4 = ((typeof(document.all) != 'undefined') && (parseInt(navigator.appVersion) >= 4)) ? 1 : 0;
var jsIsNS4 = (typeof(document.layers) != 'undefined') ? 1 : 0;
! var jsWhichVersion = (jsIsDOM || jsIsIE4 || jsIsNS4) ? 'high' : 'low';
! // Uggly fix for Opera & Konqueror that are half DOM compliant
! if (jsWhichVersion == 'high')
{
! if (typeof(window.opera) != 'undefined')
{
! jsWhichVersion = 'low';
}
+ else if (typeof(navigator.userAgent) != 'undefined')
+ {
+ var browserName = ' ' + navigator.userAgent.toLowerCase();
+ if (browserName.indexOf('konqueror') > 0)
+ {
+ jsWhichVersion = 'low';
+ }
+ }
}
var jsIsJs11 = (typeof(window.focus) != 'undefined');
***************
*** 748,754 ****
<?php
// Displays a message for translations with an 'x-user-defined' charset
! if (defined('L_FONT_NAME'))
{
! $pathToFont = _CHAT_PATH . 'localization/' . $dbSessionVars['lang'] . '/' . L_FONT_NAME . '.zip';
if (file_exists($pathToFont))
{
--- 754,760 ----
<?php
// Displays a message for translations with an 'x-user-defined' charset
! if (defined('L_FONT_PACK'))
{
! $pathToFont = _CHAT_PATH . 'localization/' . $dbSessionVars['lang'] . '/' . L_FONT_PACK;
if (file_exists($pathToFont))
{
***************
*** 756,760 ****
{
echo("\t" . '<span class="chatError">' . "\n");
! echo("\t\t\t" . 'This translation of ' . APP_NAME . ' requires the <a href="' . $pathToFont . '" class="chatFonts">' . L_FONT_NAME . ' font face</a>' . "\n");
echo("\t\t" . '</span>' . "\n");
echo("\t\t" . '<br /><br />' . "\n");
--- 762,766 ----
{
echo("\t" . '<span class="chatError">' . "\n");
! echo("\t\t\t" . 'This translation of ' . APP_NAME . ' requires <a href="' . $pathToFont . '" class="chatFonts" title="' . str_replace('"', '', L_FONT_NAME) . '">these font faces</a>' . "\n");
echo("\t\t" . '</span>' . "\n");
echo("\t\t" . '<br /><br />' . "\n");
|