WordPress.org

Ready to get started?Download WordPress

Forums

xili-language
[resolved] Call to a member function read() on a non-object (3 posts)

  1. cdennington
    Member
    Posted 1 year ago #

    Hello, I have recently installed Xili Language and Xili Dictionary onto my theme. The theme I am using has been customised but is mainly based upon Twenty Eleven.

    When I go to the Xili language settings page, I get the following error, and although I can see the menu list, there are no options within any of the tabs:
    Fatal error: Call to a member function read() on a non-object in /Applications/XAMPP/xamppfiles/htdocs/wangltangl-reskin/wp-content/plugins/xili-language/xili-includes/xl-class-admin.php on line 3069

    And then when I visit the Xili Dictionary settings page, and go to the tab "Tools, Files po mo", I get the following error, and I seem unable to import MO or PO files:
    Fatal error: Call to a member function read() on a non-object in /Applications/XAMPP/xamppfiles/htdocs/wangltangl-reskin/wp-content/plugins/xili-dictionary/xili-dictionary.php on line 5841

    If I comment out the while loops associated with these lines of code, the plugin seems to work as normal, but I still cant import the translate files, is there a way I can fix this?

    http://wordpress.org/extend/plugins/xili-language/

  2. Michel - xiligroup dev
    Member
    Plugin Author

    Posted 1 year ago #

    Thanks for your question,
    Context:
    It seems to be on PC (xampp)
    version of php ?
    version of WP ?
    version of xili-language - latest ?

    This error seems to occur when plugin search files in language folders and php seems to be unable to read the path (use php function dir ($path) see source lines above 3069).

    can you test with twenty eleven-xili (http://2011.wpmu.xilione.com) ?

    M.

  3. cdennington
    Member
    Posted 1 year ago #

    Thanks for your quick response, I have managed to fix this Fatal error following your instructions, it turns out dir($path), was only looking at the theme folder and not into langs.

    Once I added the following to the $dir variable the error went away and the folder could be found:

    $dir = dir($path . "/langs");

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags