I am currently re-writing a site from coldfusion into php. I have one section within a loop that pulls a query out of the database and then runs a query on the result to build the array that will be used later on in the script.
I have the following code that was used in coldfusion:
<cfquery name="Score#MyNum#" DBTYPE="query">
SELECT Score, Answer FROM ScoreA WHERE Answer = '#Questlist.Answer#'
</cfquery>
Where #MyNum# is the number of the loop (there are 20 iterations), ScoreA is a query run earlier in the script as is Questlist.
This gives out the following (example) result:
Score1.Score = 1, Score2.Score = 4, Score3.Score = 10, etc.
Is it possible to do this in php? or will i have to do it a long winded way.
Thanks for any help.