All this is supposed to do is execute an LUA file from the webserver that simply says:
dkp = 300;
After that it should update every 30 seconds and input that text into the simpleHTML field inside the XML layer, but it does nothing. I added the chat messages to see if it was even working and it doesn't even say anything in the chat window... Any help would be great
I don't really know much about making addons or LUA work, I am just a lowly PHP developer who normally does server-side applications lol
My XML
Code:
<Ui xmlns="http://www.blizzard.com/wow/ui" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<!--Autogenerated by wowuides, Version=1.0.300.0, Culture=neutral, PublicKeyToken=null-->
<Frame name="NSDKPForm" movable="true" enableMouse="true">
<!--<FrameSkin skinid="f15d4970-d66d-444e-bb2d-1ad102c87fed" frameid="f15d4971-d66d-444e-bb2d-1ad102c87fed" />-->
<Size>
<AbsDimension x="302" y="56" />
</Size>
<Anchors>
<Anchor point="TOPLEFT" relativeTo="UIParent">
<Offset>
<AbsDimension x="100" y="-100" />
</Offset>
</Anchor>
</Anchors>
<Backdrop bgFile="interface\dialogframe\ui-dialogbox-gold-background" edgeFile="interface\dialogframe\ui-dialogbox-gold-border" tile="true">
<BackgroundInsets>
<AbsInset left="11" right="12" top="12" bottom="11" />
</BackgroundInsets>
<TileSize>
<AbsValue val="32" />
</TileSize>
<EdgeSize>
<AbsValue val="32" />
</EdgeSize>
<Color r="1" g="1" b="1" />
<BorderColor r="1" g="1" b="1" />
</Backdrop>
<Frames>
<SimpleHTML name="$DKPreadout" file="|H%s|h%s|h">
<!--<FrameSkin skinid="f15d4970-d66d-444e-bb2d-1ad102c87fed" frameid="3eecda8a-2e43-4781-999f-95a367166924" />-->
<Size>
<AbsDimension x="274" y="30" />
</Size>
<Anchors>
<Anchor point="TOPLEFT">
<Offset>
<AbsDimension x="14" y="-14" />
</Offset>
</Anchor>
</Anchors>
<FontString>
<FontHeight>
<AbsValue val="14" />
</FontHeight>
<Color r="0" g="1" b="0" />
</FontString>
</SimpleHTML>
</Frames>
</Frame>
</Ui>
And my LUA
Code:
dkp = 0;
function RefreshDKP()
playername = UnitName("player");
remotedkp = "http://www.nocturnalsymphony.com/test/addondkp.php?p=" .. playername;
dofile(remotedkp);
DKPreadout:SetText("You have " .. dkp .. " DKP");
DEFAULT_CHAT_FRAME:AddMessage("DKP Refreshed");
Chronos.schedule(30,RefreshDKP);
end
function InitDKP()
playername = UnitName("player");
DKPreadout:SetText("Loading DKP for " .. playername);
DEFAULT_CHAT_FRAME:AddMessage("Loading DKP for " .. playername);
end
Chronos.afterInit(RefreshDKP);