ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Lua/XML Help (https://www.esoui.com/forums/forumdisplay.php?f=175)
-   -   Include external files/ database connection? (https://www.esoui.com/forums/showthread.php?t=771)

Cordain 04/10/14 07:40 PM

Include external files/ database connection?
 
Please help. I have a lua script that uses luaSQL for database connection. It works as a stand alone lua script but not when used in an addon.

example code:
Code:

mysql = require "libmysql.mysql"
local env  = mysql.mysql()
local conn = env:connect('DB-NAME','DB-USERNAME,'PASSWORD','DB-IP-ADDRESS,'PORT NUMBER')

it throws an error "Function expected instead of nil" at this line
Code:

mysql = require "libmysql.mysql"
Anyone have suggestions on connecting to external database?

an alternative would be to have addon POST to a my server side php file to handle database update but I have no idea how to do this either.

Seerah 04/10/14 07:59 PM

ESO is a sandbox. The i/o libraries are not included in this version of Lua.

Cordain 04/10/14 08:26 PM

Seerah- can they be included in some fassion. Or am i walking on a dead steet?

Seerah 04/10/14 08:33 PM

Dead end street. ESO is a sandbox on purpose. :p

Cordain 04/10/14 08:37 PM

Thanks for the help, and for crushing my hopes and dreams :p

Seerah 04/10/14 08:39 PM

No problem! :banana:


All times are GMT -6. The time now is 06:23 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI