1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

get config of plugin on another server

Discussion in 'Development' started by kaliiks, Feb 7, 2017.

  1. kaliiks

    kaliiks Zombie

    Messages:
    250
    Error :/
    Code:
    Warning: file_put_contents(/C:/Users/uzivatel/Desktop/Server-MB1/plugins/Core/config.yml): failed to open stream: Invalid argument in phar://C:/Users/uzivatel/Desktop/Server/PocketMine-MP.phar/src/pocketmine/utils/Config.php on line 207
    PHP:
    public function instanceMb1(){

        
    $newconfig = new Config("C:/Users/uzivatel/Desktop/Server-MB1/plugins/Core/config.yml");
        return 
    $newconfig->get("status");

    }
     
    Last edited: Feb 11, 2017
  2. kaliiks

    kaliiks Zombie

    Messages:
    250
    No, sorry it is working thank you @robske_110 (Tim) !!!
     
  3. Bluplayz

    Bluplayz Spider Jockey

    Messages:
    43
    GitHub:
    bluplayz
    You can try
    $config = new Config('path/file.txt',Config::YAML);
    (if you know the path to your server)

    otherwise use MySQL to get Data vom other Servers :)
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.