These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

Drop down menu, populated from mysql, while filling data to POST aswell.

Author
Fred Eto
The Eloria Corporation
#1 - 2011-10-24 20:27:33 UTC
Hi tech forum.

I've built this small script skill-checker a while ago, it uses the POST command to get info:

http://pastebin.com/MtT2iEt8

ther start of the parser itself:

http://pastebin.com/Tc98nQda

I've now started using the script for TS so that you can reg on ts with API. I would now like to use the ts database to fill the above.

Basically it should be something like this:

You get a dropdown menu, where you can chose name. Which will be tsName from the databse so (TICKER | NAME)

Then it should auto-pull the UserID and Api Key from the databse, that's api_user and api_key and lastly, instead of the "CharName" I have now, I would replace that with the charid also taken from the mysql database. (characterID).

I tried playing with the following:

http://pastebin.com/KW9XSHzX

But it didn't give me anything to chose from, which kinda stalled me.

Help is appreciated!

Thanks in advance =)

/Fred
Trenker
#2 - 2011-10-24 20:43:37 UTC
First you select only the field tsName

$query="SELECT tsName FROM users";

but later you want the fields id and name

echo '< option value="' . $nt['id'] . '" >' . $nt['name'] . '< /option >';

So you may want to try
SELECT tsName, id, name FROM users