Question: I am really struggling with PHP syntax to create variable to display texts and values in a table, as well as trying to create a

I am really struggling with PHP syntax to create variable to display texts and values in a table, as well as trying to create a random number generator in PHP. I am fine with creating the table, and would have no issue simply inputting the info. But, I do not understand using PHP to produce the texts and values.

  1. Using HTML and PHP syntax:
    1. Donuts cost $2. Create a variable and display the text and variables value in row one as is shown in the image below.
    2. Donut toppings are $1.25 per topping. Create a variable and display the text and variables value in row two as is shown in the image below.
    3. Calculate and display the price of one donut with five toppings. Create a variable for the price and display the text and variables value in row three as is shown in the image below.
    4. Calculate and display the price of one donut with five toppings, but this time display the price of each topping so, 1 topping is $3.25, 2 toppings are $4.50, etc. Use a while loop or a for loop. Display the text and values in four as is shown in the image below.
    5. Complete the appropriate calculations to accomplish the task for Tonys donut wheel promotion:
    6. Tony has a new promotion: Spin the donut wheel and spin the toppings wheel. The donut wheel contains the numbers 1-12. The toppings wheel contains the numbers 1-6. Customers spin both wheels and get a random number for both . Can you simulate the spin of both, display the values for each (donut spin and topping spin) and the actual price? Remember, a donut costs $2.00 and each topping is $1.25.
      1. I am really struggling with PHP syntax to create variable to display

Home Template LP1 Prices Base price of donut $2.00 Each topping on a donut $1.25 Price of donut with 5 toppings added $8.25 Price of donut with 5 toppings added. Prices per number of toppings Donut with 1 topping(s): $3.25 Donut with 2 topping(s): $4.50 Donut with 3 topping(s): $5.75 Donut with 4 topping(s): $7.00 Donut with 5 topping(s): $8.25 SPIN THE DONUT WHEEL! Donut spin: 5 Topping spin: 4 Promotion Value: $ 15.00 Dandy Donuts

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!