View Full Version : Uploading a TStringArray to a website?
Wizkid
07-30-2011, 03:28 PM
How would I do such a thing?
Working on a way to notice how my script bugs, and also trying to find a way to add it into random solvers! That way we can see which solvers are broken straight away and not wait until twenty people gets stuck and one reports it!
All help is accepted!
~ Wizkid
Floor66
07-30-2011, 03:40 PM
you can make a simple php script that accepts POST data, then glue the TStringArray into one string and post that.
then you can make it flatfile or save it in a mysql db, whatever you want
Wizkid
07-30-2011, 03:43 PM
I can work out the Simba code, however the php file will be a big problem :\
I searched for similar routines but couldn't find anything, closest I came to it was a version checker, and that didn't help me at all!
~ Wizkid
Floor66
07-30-2011, 04:37 PM
Look at PHP's fopen() function to use with a flatfile configuration.
Then you can just do
if($_POST)
{
//fopen or whatever; just make a .txt file with the report or something
}
Frement
07-30-2011, 04:39 PM
if ($_POST) ?? :)
if (isset($_POST["data"]) {
$file = fopen("file.dat", "a"); //Opens to append
fwrite($file, $_POST["data"]."\n");
fclose();
} else {
echo "No POST data.";
}
Floor66
07-30-2011, 04:53 PM
if($_POST) works :p
Powered by vBulletin® Version 4.2.1 Copyright © 2024 vBulletin Solutions, Inc. All rights reserved.