So far I can read several ID's from my external webserver into an lsl script. The problem is, that all id's get read as one string. But I need to read each ID individual to implement them in llGiveMoney.
PHP-Script
CODE
function cmd_get($params){
$req = array('slid');
foreach($req as $rkey){
$$rkey = mysql_real_escape_string($params[$rkey]);
}
$sql = "SELECT `id` FROM `mytable` ORDER BY `id` ASC LIMIT 0 , 10000";
$result = mysql_query($sql) or die(mysql_error());
while($row = mysql_fetch_row($result)){
for($i=0; $i<sizeof($row); $i++)
echo $row[$i];
}
}
SL-Script
CODE
default
{
touch_start(integer toucher)
{
urlStore = "http://myPage.com/Script.php?command=get&slid=id";
saveData = llHTTPRequest(urlStore,[HTTP_METHOD,"GET"],"");
}
http_response(key id,integer status, list meta, string body)
{
if(saveData==id)
{
llOwnerSay(body);
}
}
}
So I just do the output to see how the Data arrives in SL. If I read 10 ID's, they arrive as one big string. Do you know how I can split it up?
thx
THX