Revision history for CharsetNotSupportedWorkaround


Revision [23489]

Last edited on 2016-05-20 07:38:48 by HansEric [Replaces old-style internal links with new pipe-split links.]
Additions:
On any page with code blocks, PHP displays a series of warnings for GeSHi [[Docs:SyntaxHighlighter | highlighting]] code, like these (path shortened):
The PHP function [[http://php.net/htmlentities | htmlentities()]] needs a character set (encoding) to know how to do its work; this is an optional parameter for the function. If this parameter is not defined, a default applies; this can be defined in the php.ini file, but often isn't. PHP then assumes some other default //(unclear so far where this default comes from - it may be a compilation option)//. GeSHi uses htmlentities() extensively, but always passes the optional parameter, so one can specify which encoding GeSHi uses. If this isn't set, the default from php.ini applies, and if that isn't set PHP's internal (?) default applies. Normally this will be iso-8859-1 (Latin-1).
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 | fixed as of GeSHi version 1.0.5]]. See also [[http://qbnz.com/highlighter/forum.php?t=46 | this forum topic]]. Wikka 1.1.6.0 uses [[Docs:ThirdPartyInfo | GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.
Deletions:
On any page with code blocks, PHP displays a series of warnings for GeSHi [[Docs:SyntaxHighlighter highlighting]] code, like these (path shortened):
The PHP function [[http://php.net/htmlentities htmlentities()]] needs a character set (encoding) to know how to do its work; this is an optional parameter for the function. If this parameter is not defined, a default applies; this can be defined in the php.ini file, but often isn't. PHP then assumes some other default //(unclear so far where this default comes from - it may be a compilation option)//. GeSHi uses htmlentities() extensively, but always passes the optional parameter, so one can specify which encoding GeSHi uses. If this isn't set, the default from php.ini applies, and if that isn't set PHP's internal (?) default applies. Normally this will be iso-8859-1 (Latin-1).
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. See also [[http://qbnz.com/highlighter/forum.php?t=46 this forum topic]]. Wikka 1.1.6.0 uses [[Docs:ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.


Revision [21504]

Edited on 2011-05-19 02:00:31 by HansEric [Replaces old-style internal links with new pipe-split links.]
Additions:
~1)Open **##/libs/Wakka.class.php##**.
Deletions:
~1)Open **##wikka.php##**.


Revision [18364]

Edited on 2008-01-28 00:11:13 by JavaWoman [Modified links pointing to docs server]
Additions:
On any page with code blocks, PHP displays a series of warnings for GeSHi [[Docs:SyntaxHighlighter highlighting]] code, like these (path shortened):
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. See also [[http://qbnz.com/highlighter/forum.php?t=46 this forum topic]]. Wikka 1.1.6.0 uses [[Docs:ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.
Deletions:
On any page with code blocks, PHP displays a series of warnings for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. See also [[http://qbnz.com/highlighter/forum.php?t=46 this forum topic]]. Wikka 1.1.6.0 uses [[ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.


Revision [7661]

Edited on 2005-04-27 15:14:00 by JavaWoman [extra link to GeSHi forum]
Additions:
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. See also [[http://qbnz.com/highlighter/forum.php?t=46 this forum topic]]. Wikka 1.1.6.0 uses [[ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.
Deletions:
In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. Wikka 1.1.6.0 uses [[ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.


Revision [7656]

Edited on 2005-04-27 08:19:50 by JavaWoman [small correction]
Additions:
On any page with code blocks, PHP displays a series of warnings for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):
Deletions:
On any page with code blocks, PHP displays a series for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):


Revision [7655]

Edited on 2005-04-27 08:17:21 by JavaWoman [added note (+ link) about fix in next version of GeSHi]
Additions:
=====Charset not supported warnings=====

===Symptoms===
On any page with code blocks, PHP displays a series for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):
%%Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1608

Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588

Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588

...(etc.)%%

===Cause===
The PHP function [[http://php.net/htmlentities htmlentities()]] needs a character set (encoding) to know how to do its work; this is an optional parameter for the function. If this parameter is not defined, a default applies; this can be defined in the php.ini file, but often isn't. PHP then assumes some other default //(unclear so far where this default comes from - it may be a compilation option)//. GeSHi uses htmlentities() extensively, but always passes the optional parameter, so one can specify which encoding GeSHi uses. If this isn't set, the default from php.ini applies, and if that isn't set PHP's internal (?) default applies. Normally this will be iso-8859-1 (Latin-1).

The (unusual) symptoms described above may occur when the default for PHP (either via php.ini or the internal default) actually is an unsupported character set (or an unrecognized string).

===Applies to===
Wikka version 1.1.6.0 (first version to include GeSHi).

===Solution===
Since GeSHi's API allows the encoding to be set, the solution is specify for GeSHi which encoding to use. This requires adding a single line of code to **##wikka.php##**:
~1)Open **##wikka.php##**.
~1)Find the function %%(php) function GeSHi_Highlight($sourcecode, $language, $start=0)%%
~1)Find the line (a few lines down): %%(php) $geshi->enable_classes();%% and just before it **add** the following line: %%(php) $geshi->set_encoding('iso-8859-1');%% --- Of course, if you really need a different encoding, replace '**##iso-8859-1##**' with the appropriate name.

===Future===
In the future, Wikka //may// provide a configuration option for Geshi to define the character set to be used.

In addition, word is that it will be / is [[http://qbnz.com/highlighter/forum.php?t=19 fixed as of GeSHi version 1.0.5]]. Wikka 1.1.6.0 uses [[ThirdPartyInfo GeSHi version 1.0.4]]; we'll include the latest version in the next Wikka release, of course.

----
Deletions:
=====Charset not supported warnings=====

===Symptoms===
On any page with code blocks, PHP displays a series for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):
%%Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1608

Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588

Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588

...(etc.)%%

===Cause===
The PHP function [[http://php.net/htmlentities htmlentities()]] needs a character set (encoding) to know how to do its work; this is an optional parameter for the function. If this parameter is not defined, a default applies; this can be defined in the php.ini file, but often isn't. PHP then assumes some other default //(unclear so far where this default comes from - it may be a compilation option)//. GeSHi uses htmlentities() extensively, but always passes the optional parameter, so one can specify which encoding GeSHi uses. If this isn't set, the default from php.ini applies, and if that isn't set PHP's internal (?) default applies. Normally this will be iso-8859-1 (Latin-1).

The (unusual) symptoms described above may occur when the default for PHP (either via php.ini or the internal default) actually is an unsupported character set (or an unrecognized string).

===Applies to===
Wikka version 1.1.6.0 (first version to include GeSHi).

===Solution===
Since GeSHi's API allows the encoding to be set, the solution is specify for GeSHi which encoding to use. This requires adding a single line of code to **##wikka.php##**:
~1)Open **##wikka.php##**.
~1)Find the function %%(php) function GeSHi_Highlight($sourcecode, $language, $start=0)%%
~1)Find the line (a few lines down): %%(php) $geshi->enable_classes();%% and just before it **add** the following line: %%(php) $geshi->set_encoding('iso-8859-1');%% --- Of course, if you really need a different encoding, replace '**##iso-8859-1##**' with the appropriate name.

===Future===
In the future, Wikka //may// provide a configuration option for Geshi to define the character set to be used.

----


Revision [5248]

Edited on 2005-01-26 21:29:18 by JavaWoman [initial]
Additions:
=====Charset not supported warnings=====
On any page with code blocks, PHP displays a series for GeSHi [[SyntaxHighlighter highlighting]] code, like these (path shortened):
%%Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1608
Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588
Warning: htmlentities(): charset `ANSI_X3.4-1968' not supported, assuming iso-8859-1 in [wikihome]/3rdparty/plugins/geshi/geshi.php on line 1588
...(etc.)%%
The PHP function [[http://php.net/htmlentities htmlentities()]] needs a character set (encoding) to know how to do its work; this is an optional parameter for the function. If this parameter is not defined, a default applies; this can be defined in the php.ini file, but often isn't. PHP then assumes some other default //(unclear so far where this default comes from - it may be a compilation option)//. GeSHi uses htmlentities() extensively, but always passes the optional parameter, so one can specify which encoding GeSHi uses. If this isn't set, the default from php.ini applies, and if that isn't set PHP's internal (?) default applies. Normally this will be iso-8859-1 (Latin-1).
The (unusual) symptoms described above may occur when the default for PHP (either via php.ini or the internal default) actually is an unsupported character set (or an unrecognized string).
Wikka version 1.1.6.0 (first version to include GeSHi).
Since GeSHi's API allows the encoding to be set, the solution is specify for GeSHi which encoding to use. This requires adding a single line of code to **##wikka.php##**:
~1)Open **##wikka.php##**.
~1)Find the function %%(php) function GeSHi_Highlight($sourcecode, $language, $start=0)%%
~1)Find the line (a few lines down): %%(php) $geshi->enable_classes();%% and just before it **add** the following line: %%(php) $geshi->set_encoding('iso-8859-1');%% --- Of course, if you really need a different encoding, replace '**##iso-8859-1##**' with the appropriate name.
===Future===
In the future, Wikka //may// provide a configuration option for Geshi to define the character set to be used.
Deletions:
=====Problem description=====
//This page is a **template** intended for documentation of **workarounds** for unusual Wikka problems. This page belongs to CategoryTemplate (which contains more handy templates). To create a Wikka **workaround** page, [[http://wikka.jsnx.com/WorkaroundTemplate/clone clone this page]] (most workaround page names end in 'Workaround' so it's useful to stick to that convention) and replace the title with a problem description (in a few words). Then remove this paragraph and provide actual page content in the outline below.//


Revision [5247]

The oldest known version of this page was created on 2005-01-26 20:54:37 by JavaWoman [initial]
Valid XHTML :: Valid CSS: :: Powered by WikkaWiki