I have a php loop that is generating data from a range of queries to a remote database using a loop in this format. i am outputting the data in the format below where "java" is the field name and "132" is the result of the query.
java 132
java+unix 154
java+sybase 186
etc
i want to get the final data and insert it into mysql database after the loop is completed (so I get all the data at once and can put it into a row with the field names being java, java+unix, java+sybase, etc). I am fine with database connectivity but i can't work out how to get all the data at once...
1) is there a way to come out of the loop when it is finished and still use the outputted data?
2) should i build a php page that calls the page with the loop?
3) could i build further variables that appends each result when they come in like the code below? How can I access this when the loop completes?
$skillinput = $skillinput."'".$skills."'";
$resultinput = $resultinput."'".$resultc."'";