<?php
$dbhost = 'localhost';
$dbuser = user;
$dbpass = 'xxxxxxx';
$conn = mysql_connect($dbhost, $dbuser, $dbpass) or die ('Error connecting to mysql');
$dbname = 'database';
mysql_select_db($dbname);
$query="select username from usertable ;";
$result = mysql_query($query);
while($row = mysql_fetch_array($result, MYSQL_ASSOC))
{
// this is the part where I don't know how to proceed with
while opening and searching through the file "userdata.html" {
match the first corresponding amount for the user ( example user1's amount is 0.00, user2's amount is: 12.49 as shown in the HTML table)
store the match (amount) in a variable "let's say $useramount"
store the variable $useramount in another table ( I can manage to do this myself, just to explain the purpose of doing this)
//end
}
}
?>
Thank you so much for helping me out!