Getting something from the config in a static reference

Discussion in 'Plugin Development' started by Prothean_IGS, Jan 2, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    Prothean_IGS

    Hello,
    I am currently trying to hook my plugin in to MySQL and for the connection I would like to get the MySQL Ip, port, server name, username, and password. The only problem is when I go to get the information from getConfig() I get an error saying that I can not make a static refernce to a non-static method (getConfig).

    Any idea of how I should do this so that I do not have to hard code the MySQL server info?
     
  2. Offline

    Mitsugaru

    Whatever method you're using to call the method getConfig() cannot be static. That's all the direction I can give without any actual code.

    EDIT - Here's a SO link that explains it in more detail: http://stackoverflow.com/a/4969191
     
Thread Status:
Not open for further replies.

Share This Page