1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
dybincka [34]
3 years ago
5

Create a page using PHP for a business website that will ask the user to enter his or her name into text boxes and will display

a welcome message that uses the user’s name.

Computers and Technology
1 answer:
Jet001 [13]3 years ago
4 0

Answer:

1         <?php

2            if (isset($_GET["submit"])) {

3                 echo "Welcome " . $_GET["name"];

4                }  

5         ?>

6

7

8         <form method="get">  

9            <input name="name" type="text" placeholder="Enter your name"/>

10           <button name="submit" type="submit">Submit</button>

11          </form>  

12

13         <?php

14          ?>

<h2>Explanation:</h2>

Lines 1 - 5    check if the user has clicked on the submit button.

                    If the button has been clicked the a welcome message is    

                    shown.

Lines 8 - 11   create a form to hold the text box and the submit button

                    Give the form a <em>method</em> attribute of value <em>get        [Line 8]</em>

<em>                     </em>Give the input field a <em>name</em> attribute of value <em>name </em>and a

                    placeholder attribute of value <em>Enter your name      [Line 9]</em>

<em>                     </em>Give the button a <em>name </em>attribute of value <em>submit</em> and a <em>type</em>

                    attribute of value <em>submit</em>                                            <em>[Line 10]</em>

<em />

<em />

<em />

<em />

PS: Save the file as a .php file and run it on your server. Be sure to remove the line numbers before saving. A sample web page is attached to this response.

You might be interested in
The node of a doubly linked list contains _____.
meriva

Answer:

Hi!

The correct answer is one data field and two links fields.

Explanation:

The node of a doubly-linked list contains one data field, and two links fields that references to the next node on the list and another one link field that references to the previous node in the sequence of nodes).

3 0
3 years ago
webrooming is when consumers physically inspect a product in a store to get a look and feel for it—and then buy it from an onlin
azamat

The statement that webrooming is when consumers physically inspect a product in a store to get a look and feel for it—and then buy it from an online store because it is cheaper to do so is false.

<h3>What is webrooming?</h3>

It should be noted that webrooming simply means the consumer practice for researching products online before buying theme in stores.

In this case, the main idea of webrooming isn't to buy it at stores because it's cheaper. Therefore, it's false.

Learn more about webrooming on:

brainly.com/question/14988432

#SPJ12

3 0
2 years ago
Can you answer this ?​
beks73 [17]

Answer:

Answer it yourself.

Explanation:

NO.

4 0
2 years ago
Read 2 more answers
Create a dictionary that will hold AT LEAST 3 categories for food with at least 3 foods for each category. E.g. Fruits --&gt; Ap
RSB [31]

Answer:

  1. food_category = {
  2.    "Fruits": ["Apple", "Strawberries", "Orange"],
  3.    "Vegetables": ["Carrots", "Peas", "Onions"],
  4.    "Meats": ["Chicken", "Beef", "Mutton"]
  5. }
  6. for cat in food_category:
  7.    output = cat + ": "
  8.    for food in food_category[cat]:
  9.        output += food + ", "
  10.    print(output)
  11. answer = input("Do you want to add category or food (Y - Yes  N - No): ")
  12. while(answer == "Y"):
  13.    choice = input("New Category (N) or New Food (nf): ")
  14.    
  15.    if(choice == "N"):
  16.        new_cat = input("Enter new category name: ")
  17.        if(new_cat not in food_category):
  18.            food_category[new_cat] = ""
  19.    elif(choice == "nf"):
  20.        cat = input("Enter category: ")
  21.        new_food = input("Enter new food name: ")  
  22.        food_category[cat].append(new_food)
  23.    
  24.    answer = input("Do you want to add new category or food (Y - Yes N - No): ")
  25. print("All food categories: ")
  26. for cat in food_category:
  27.    print(cat)
  28. selected_cat = input("Select a category to view the food list: ")
  29. output = ""
  30. for food in food_category[selected_cat]:
  31.    output += food + ", "
  32. print(output)

Explanation:

The solution code is written in Python 3.

Firstly, create a food category dictionary data structure (Line 1 -5). Next, display all the food category and the food in each category (Line 7 - 11)

Next prompt user to feedback if they wish to add new category or new food (Line 13).

While the answer is yes prompt user to enter their choice, either category or food and use if else if statements to handle the choice made by the user. If the choice is new category, prompt user to enter new category name and check if the new category is already exist in the dictionary. If not, add that category to dictionary (Line 18 - 21).

If the choice is food, nf, prompt user to input food category and enter the new food name and add it to the food_category list (Line 22 - 25).

After that prompt user to enter if they wish to continue to add new data (Line 27).

After collecting all info from user, write a for loop to display all the categories (Line 29 - 31).

At last, prompt user to select a category and display all the food of the selected category (Line 33 - 37).

8 0
2 years ago
What is the full form of PDA? HELP ME PLZ-​
finlep [7]

Answer:

Patent ductus arteriosus (PDA)

Explanation:

Patent ductus arteriosus (PDA) is a medical condition in which the ductus arteriosus of a person fails to close after birth.

6 0
2 years ago
Read 2 more answers
Other questions:
  • Which of the following best describes cost-benefit analysis?
    9·1 answer
  • Correspondence involves verbal communication. True False
    6·2 answers
  • I need a free flashdrive can anyone tell me any website links so i can get one for free????​
    11·1 answer
  • Complete the following table.
    6·1 answer
  • Ryan is working on a document with many secotions. For each section,he wantes to have the title bolded,underlined,an blue. Which
    9·2 answers
  • How are computers 35 years ago and how are they presently and how are they going to be in the next 35 years
    9·1 answer
  • Define each of the following data mining functionalities: characterization, discrimination, association and correlation analysis
    9·1 answer
  • Yusuke has been a fan of online games for as long as she can remember. She particularly loves the role-playing games that allow
    7·1 answer
  • 15. You read a news article that's politically biased and not well organized. It's
    6·1 answer
  • Please help me please please
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!