Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8282951
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T10:33:47+00:00 2026-06-08T10:33:47+00:00

I have a form for editing a ticket that requires a Reason for Edit.

  • 0

I have a form for editing a ticket that requires a “Reason for Edit”. What I would like to do is have that automatically filled in as a result of when any of the input fields or the select dropdown changes. I know this can be done with javascript and an onChange event and have it modify (I believe) the innerHTML of the textarea. I’m strong on PHP/MySQL but javascript is definitely my weakness.

What I do not know and have been unsuccessful searching for, is exactly how to code this. As an example of what I have would be the following code:

<!-- Customers name -->
<input type='text' name='customer_name' onChange="updateReason('Updated Customer Name')" /><br><br>

<!-- Customer Email -->
<input type='text' name='customer_email' onChange="updateReason('Updated Customer Email')" />

If either of those two would be changed then the contents of a textarea would be updated and end with a carriage return.

Any help (or even pushed in the right direction / links to a guide) is appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T10:33:49+00:00Added an answer on June 8, 2026 at 10:33 am

    HTML:

    <form name="frmTest" action="test.html">
        <textarea name="reason"></textarea>
    
        <!-- Customers name -->
        <input type='text' name='customer_name' onChange="updateReason('Updated Customer Name')" />
    
        <!-- Customer Email -->
        <input type='text' name='customer_email' onChange="updateReason('Updated Customer Email')" />
    </form>
    

    native HTML implementation:

    function updateReason(text) {
      document.frmTest.reason.value += text + '\r\n';
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a form for editing notifications that looks like: <form action='edit.php' method =
I have a form that handles editing of a domain model (A). This domain
I have a longish form that scrolls vertically and also allows editing records. When
I have created a form that is used for both adding and editing a
I have a jqGrid that has add/edit dialogs with a form that's longer than
I have a form on which I would like the user to confirm one
I have a page on my site with a form for editing event information
I have form where are 2 input fields and then i have dynamic dataTables
I have form, where some fields are looks like rows, so I can add/delete
Let's say I have a form for adding/editing products (with field 'user' being a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.