Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Jun 2009
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Multiple action done by a clicked button

    Hi every

    I need a help.
    I have window containing a field.
    I was looking for a way to copy the value in the field and at the same time close the window.

    For copying i use this onclick="return copy_clip(document.forms[0].num_alladaid_{num_allada:rowNumber}.value) it worked perfectly.

    To close window i cleaned the copying code and insert this : 'javascript:window.close();' it worked perfectly too.

    But i don't know how to put the 2 codes in one line so that on click the button will copy the field value and close the window

  • #2
    Supreme Master coder! Philip M's Avatar
    Join Date
    Jun 2002
    Location
    London, England
    Posts
    18,017
    Thanks
    203
    Thanked 2,538 Times in 2,516 Posts
    Code:
    onclick="return copy_clip(document.forms[0].num_alladaid_{num_allada:rowNumber}.value);window.close();"
    All advice is supplied packaged by intellectual weight, and not by volume. Contents may settle slightly in transit.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •