J
james_crane
Hi,
I have an editable div. If I insert and image and explicity give it an
id I can reference it and change the tag thus...
var imgTag = document.getElementById("james")
imgTag.setAttribute('align','left')
However, I would like the user to be able to select the image, and then
have the align attribute set BUT I can;t get a reference to the image,
I have fiddled with
imgTag = document.selection.createRange()
but am failing - help woudl be appreciated
Thanks
James
I have an editable div. If I insert and image and explicity give it an
id I can reference it and change the tag thus...
var imgTag = document.getElementById("james")
imgTag.setAttribute('align','left')
However, I would like the user to be able to select the image, and then
have the align attribute set BUT I can;t get a reference to the image,
I have fiddled with
imgTag = document.selection.createRange()
but am failing - help woudl be appreciated
Thanks
James