User Input is data that the user inputs into the program. It generally takes the form of a String, but may also be an integer, floating-point number, etc.
Questions tagged [user-input]
5580 questions
1
vote
0 answers
How to simulate user input to std::cin for a mcve?
I want to prepare a mcve for a colleague, but to run the example some complicated user input from std::cin is required that I'd like to include in my example code. I tried to read from a string instead of std::cin, but it didnt work. Simplified…

463035818_is_not_an_ai
- 109,796
- 11
- 89
- 185
1
vote
4 answers
guidance on allowing users to submit info to a mysql database
I am interested in the idea of creating a website that allows users to submit content and display it on new pages for other users to view. For example having a form with a few text fields to fill out, and this will be the information that is shared.…

jennifer
- 301
- 1
- 7
- 18
1
vote
0 answers
Java- does an opposite of Crtrl-D exist?
I'm using Scanner to read input to a textfile where I post Account info.
After this I'm supposed to do the same thing with Transaction info.
However after I finish putting in info for the account class, I press Ctrl-D, as one does, to indicate end…

Sarah Wadley
- 21
- 1
- 5
1
vote
3 answers
window.location.assign() navigate to user input of url?
I need to use Javascript window.location.assign() to take input from a user in an inputbox and once a button is clicked the user will be taken to the URL they entered in that inputbox- I am having difficulty finding this online. I am assuming I…

Bunny
- 35
- 8
1
vote
3 answers
jQuery: password field with readable label?
I wrote this very simple function for my current project called insidelabel() that let's me add a description (label) for an input field inside of the input.
//Label inside of inputfields
function insidelabel(selector, name) {
…

matt
- 42,713
- 103
- 264
- 397
1
vote
2 answers
Replacing a word in a string with user input [RUBY]
I'm trying to figure out how to replace a word in a string with a user string.
The user would be prompted to type which word they would like to replace, and then they would be again prompted to enter the new word.
For example the starting string…

Andrew
- 19
- 1
- 4
1
vote
1 answer
execute external program in lua without userinput as arguments in lua
I want to execute an external program in lua. Usually this can be done with
os.execute("run '"..arg0.."' 'arg1' arg2")
The problem with this approach is if I want to pass user input as string to an external program, user input could be '; evil…

sivizius
- 450
- 2
- 14
1
vote
0 answers
How can I check if user-provided PHP code is valid?
How can I check if user-provided PHP code is valid? Specifically, I have a couple of PHP scripts that users can edit via the UI for a variety of reasons. If users edit those scripts, how can I verify that what they provide is valid and isn't going…

HartleySan
- 7,404
- 14
- 66
- 119
1
vote
5 answers
How to come out of select in Linux
I want to take the input from the user, which could be any of the given options, I tried using select, but it just goes in loop, doesn't come out, is there a way i can make it to come out and proceed after the user has entered right option, here is…

Ravi
- 1,082
- 4
- 15
- 24
1
vote
0 answers
Angular material accordion based on user input override user click on input
I'm trying to build a small accordion using Angular Material and I want to make an input field so that whenever the user types something, the accordion's panels are automatically expanded if they have "subitems" which contain that string. Here's a…

Robert
- 178
- 1
- 8
1
vote
0 answers
How to reject input until needed in Python?
I have taken an excerpt from my code where the problem still happens. I believe this is because of my slow_type function but while the dialogue is being "slow typed" my input will take any values typed during the "slow_type" even before the input…

Roberto Chavo
- 33
- 1
- 5
1
vote
4 answers
printing out (input and output process) in python
I think I'm almost there with my assignment. I'm trying to print:
"Hi John,(new line)
You have a 89.6% in your principle of programming course." However, when I print the below, it shows as follows:
"Hi John,(new line) …

Ji. K
- 47
- 1
- 7
1
vote
5 answers
Space between inputs doesn't give exception on array index?
I'm not sure what to title this question(if anyone has input on what to name the question, please let me know). My program asks the user for 5 int and 5 doubles. Then those numbers are put in an array and passes it to a method to get the average. My…

Silent Serenity
- 93
- 1
- 6
1
vote
2 answers
Turbo C++ cin() not working along with gets()
Here is a code snippet I have written using c++ in turbo C++ IDE. The problem I am facing is after using gets(), cin is not working as it is skipping the inputs.Can someone possibly provide a solution to this issue.
Here is the code snippet :-
…

holapancakes
- 11
- 2
1
vote
1 answer
How to keep a high score list tied with user?
In its simplest form, my game has a counter for a score, and I want that counter to be stored along with a user name that is inputted and sort them from highest to lowest. I would imagine I want to write both attributes to a text file and then when…

Salizmo Squeegee
- 43
- 1
- 6