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 8247637
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T22:54:57+00:00 2026-06-07T22:54:57+00:00

In JavaScript I need help appending values into a textbox. What happens is that

  • 0

In JavaScript I need help appending values into a textbox. What happens is that with the relevant piece of code below, the user can add an “Option Type” from a table row into the textbox. For example if the user clicks on the “Add” button and within that row the Option Type is “True or False”, then I want it to display number 27 in the textbox, and if “Option Type” is “Yes or No” then display number 28 in the textbox. So I want it like below

Option Type             Number

True or False           27
Yes or No               28

My question is how can insert the numbers for the 2 option types into the textbox?

I tried this below for True or False but it did not work:

var myNumbers = {};

   myNumbers["True-False"] = "27";

   gridValues = myNumbers[gridValues];

Below is the true and false buttons:

<input name="answerTrueName"  id="answerTrue"   type="button"   value="True"    onclick="btnclick(this);"/>
<input name="answerFalseName" id="answerFalse"  type="button"   value="False"   onclick="btnclick(this);"/>
  • 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-07T22:54:59+00:00Added an answer on June 7, 2026 at 10:54 pm

    Figured it out, it is suppose to be:

    var myNumbers = {};
    
       myNumbers["True or False"] = "27";
    
       gridValues = myNumbers[gridValues];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i need help with a little code that i have below. i'm a newbie
I need help with the javascript below please. I have 2 text boxes and
I need help to create a regex (for JavaScript .match and PHP preg_match) that
I need help: I want to validate in javascript my currency inputs that are
I need help with Javascript. I need to replace however many characters there are
I need help getting VIM to correctly indent javascript inside script tags. This is
I need help changing the placeholder value on a input field with javascript, preferably
I`m new to JavaScript and I need some help extracting the ID from URL
Need some help from javascript gurus. I have one page where http://www.google.com/finance/converter is embedded
I need some help in JavaScript, HTML, HTML DOM and DHTML. I am not

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.