I have a csv file containing the coordinates. I also have the HTML for the webpage. I am hosting the webpage on my localhost. I want to know the elements which are present at the coordinates and output details into a new csv file. I have following PHP script inside my HTML file.
for($i=1;$i<=10;$i++)
{
echo '<script>var elem= document.elementFromPoint('.$csv[$i][1].','.$csv[$i]2].');alert(a);</script>
}
But now how to access this variable elem from PHP. Can I output CSV from javascript?
Is there any other way to get the coordinates from CSV and output element details ? Any help is highly appreciated