How to set-up a $default language.php?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ukpapillon
    New Member
    • Feb 2007
    • 3

    How to set-up a $default language.php?

    I'm still trying to sort out this annoying error message below, showing on my homepage:

    Warning: chk_language() [function.includ e]: Failed opening 'language/.php' for inclusion (include_path=' .:/usr/lib/php:/usr/local/lib/php') in /home/mysite/public_html/include/function.php on line 35

    The cause of this error is my $default language is not configure properly and need some guidance on how to do it.

    Please can someone help me to sort this problem out?
  • ronverdonk
    Recognized Expert Specialist
    • Jul 2006
    • 4259

    #2
    You must (in your main code, i.e. outside the functions) fill the $default variable with the default language, i.e. the file name of the $default.php file that you want to include later.

    In your chk_language() function you then set this variable to global scope and
    Code:
    global $default;
    Ronald :cool:

    Comment

    Working...