Results 1 to 3 of 3

Thread: Checkbox and inputing a text field

  1. #1
    Join Date
    Jun 2011

    Checkbox and inputing a text field

    Okay first off let me say I am very new at Javascript and I am still learning. I have been using adobe Pro to create a form for my company and I am trying to add some javascript to help perform a function.

    I have a checkbox and i am running javascript right now that does the following

    this.getField('test 4545').value=("series 1");

    when the box is check it produces the text "series 1" in the text field i created called "test 4545". I also have a text input field called "test 3434" that you can input any text you would like

    My question is what script can I put in that will do the following.

    When the check box is checked it produces test field "test 4545" to be the text that was already entered in text field "test 3434"

    Thanks a lot guys.

  2. #2
    Join Date
    Dec 2005

    Question Question...

    Can you add 'ID=xxx' to the elements in question in your script?

    If yes, then you could try:
    document.getElementById('test3434').value = document.getElementById('test4545').value;

  3. #3
    Join Date
    Jun 2008
    I just did that for radio buttons! Finished it this morning after banging it around since last night!

    You can see the result here:

    Go all the way to the bottom where you will see "Book or Product Attributes". Click on the expanding "+" or blue text to open the DIV... then you will see two radio buttons.

    When you click either one of them, the text in the textbox changes.
    When the form is entered, I use PHP to strip extraneous text out of the radiobutton values while passing the value entered into the input box.

    Hope that helps!

    Privacy Policy Generator

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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