|
use php to get style of html element
Goal: Using PHP, get the location of an html tag and store in mysql database
Background: Based on a mouse click, I use css style.top and style.left to set the location of the html tag using javascript. I am using php to do the database calls.
Can I get the style (e.g., style.top, style.left) of an html tag using PHP?
[CODE]
//javascript code when I create the html tag
//posx, posy are from the mouse click
var newDiv= document.createElement("img");
newDiv.style.top= (posy -10) +'px';
newDiv.style.left= (posx -6) +'px';
...
[CODE]
|