Advertisement
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

[New API] Creating database

Comments in 'Plugin Development' started by laccolite, Jun 10, 2014.

  1. laccolite
    Offline

    laccolite New Member

    Joined:
    Mar 1, 2014
    Posts:
    22
    How to create and load a Sqlite3 database?
    PEMapModder likes this.
  2. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,306
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Search on the forums. There was a thread by @Humerus on that.
  3. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,306
    Plugins:
    11
    Minecraft User:
    PEMapModder
    And SQLite3 is a PHP extension. PocketMine API updates should not affect it.
  4. laccolite
    Offline

    laccolite New Member

    Joined:
    Mar 1, 2014
    Posts:
    22
    When I created a simple function loadDB, and put $this->loadDB(); into a onEnable function, error happened:
    Uncaught exception 'RuntimeException' with message 'Autoloader couldn't find a file to include for Plugin\SQLite3'
  5. PEMapModder
    Offline

    PEMapModder Notable Member Plugin Developer

    Joined:
    Oct 9, 2013
    Posts:
    7,306
    Plugins:
    11
    Minecraft User:
    PEMapModder
    Use \SQLite3 not SQLite3 because you are in a namespace.

    Also, plugins with the namespace Plugin is discouraged and probably will not be approved.
    laccolite likes this.

Share This Page

Advertisement