![]() ![]() |
You can get the value of the text field with:
then you could create a new DIV containing the value:
then insert the DIV somewhere into the document using appendChild or insertBefore |
![]() ![]() |
Thanks for the reply - this is the best way to do it I think. I tried by the ID and here by the name:
The script seems to be enabled on the page in Greasemonkey but nothing happens. The page source does not show any changes. Any clue what I'm doing wrong? |
![]() ![]() |
getElementsByName returns an array rather than a single element so you'd need to reference it with no idea why you've changed the createElement from 'div' to 'showphone1' , that might prevent it from being visible - I'm not sure. you can use the Error Console to see where problems are occuring:
|
![]() |
JavaScript doesn't manipulate the source. It manipulates the DOM. |
![]() ![]() |
Roger Faught wrote:To see the source as it has been changed by scripts, select the relevant part of the page, right-click, and use View Selection Source. |



