Thanks for the reply. I am however, having issues getting my results for deletion.
I have created an array of all files in the directory using:
and I have queried my db for the table field results like so:
I need to return the results of the items that exist in @imgdir_contents and do not exist in @results but I dont want the results of the reverse so I dont want results that match @results items that do not exist in @imgdir_contents
I suppose that I could compare the arrays but I can only access the @results array inside of the while loop since I am a noob and dont know how to pass the @results outside of the while code block.
Your help is appreciated.