I have 2 php files (php1 and php2)
php1 creates some data inside a js function, and then makes an ajax call to php2.
php2 takes that data and creates an html result table which is passed back to php1 and displayed inside a <div>
While php2 is processing (it takes several seconds to complete). I would like a progress bar to display on the user's screen inside the div that will ultimately hold the table of results.
php2 will know how much data it has to process. Let's say it's 10 items. Every time it has completed processing of one of those items, the progress bar will show a "n of 10 completed" along with a visual bar that fills up according to how far along we have processed the data.