{ "key_pair_value_system": true, "answer_rating_count": "", "question_feedback_html": { "html_star": "", "html_star_feedback": "" }, "answer_average_rating_value": "", "answer_date_js": "2024-09-08T22:13:19-04:00", "answer_date": "2024-09-08 22:13:19", "is_docs_available": null, "is_excel_available": null, "is_pdf_available": null, "count_file_available": 0, "main_page": "student_question_view", "question_id": "9726482", "url": "\/study-help\/questions\/the-alerts-boxes-and-form-validation-are-not-working-please-9726482", "question_creation_date_js": "2024-09-08T22:13:19-04:00", "question_creation_date": "Sep 08, 2024 10:13 PM", "meta_title": "[Solved] ****the alerts boxes and form validation | SolutionInn", "meta_description": "Answer of - ****the alerts boxes and form validation are not working please fix the errors**** add output as ss Join Us body{ back | SolutionInn", "meta_keywords": "****,alerts,boxes,form,validation,working,fix,errors****,add,output,ss,join", "question_title_h1": "****the alerts boxes and form validation are not working please fix the errors**** add output as ss Join Us body{ background-color:#F8F8FF; } #txtCity{ width: 40px;", "question_title": "****the alerts boxes and form validation are not working please fix the", "question_title_for_js_snippet": " the alerts boxes and form validation are not working please fix the errors add output as ss Join Us body background color F8F8FF txtCity width 40px txtState, txtZip width 25px Fitness Power For a healthy living Home Drinks", "question_description": "
****the alerts boxes and form validation are not working please fix the errors**** add output as ss <\/div>
<\/div>
<\/div>
<\/div>
<\/div>
content=\"width=device-width, Initial-scale=1\"><\/div>
Join Us<\/title><\/div> <div><style> body{<\/div> <div> <\/div> <div>background-color:#F8F8FF; } #txtCity{<\/div> <div>width: 40px; } #txtState, #txtZip{<\/div> <div>width: 25px; } <\/style> <\/head><\/div> <div><body bgcolor=\"#BOC4DE\"><\/div> <div><h1><\/div> <div><font face=\"Georgia pro Black\"><u> \"Fitness<\/div> <div>Power\"<\/h1><\/font><\/u><\/div> <div><h2>For a healthy living<\/h2><\/div> <div><pre><\/div> <div><font size=\"6\"color=black>Home<\/font><\/div> <div> <\/div> <div><font size=\"6\"color=black>Drinks <a<\/div> <div>href=\"memberform.html\"target=\"_top\"\"><\/div> <div><font size=\"6\"color=black>Join Us<\/pre> <hr><\/div> <div><form name= \"myform\"> <h1>Join Us<\/h1><\/div> <div><h3>Step 1:Enter your name, address, and<\/div> <div>phone number:<\/div> <div><\/h3> <table> <tr> <td>Name:<\/td> <td><\/div> <div><input type=\"text\" id=\"txtName\"\/><\/div> <div><\/td> <\/tr> <tr> <td>Address: <\/td> <td><\/div> <div><input type=\"text\" id= \"txtAddress\"\/><\/div> <div><\/td> <\/tr> <tr> <td>City: <\/td> <td><\/div> <div><input type=\"text\" id=\"txtCity\"\/><\/div> <div>State : <!--textbox for State--><\/div> <div><input type=\"text\" id=\"txtState\"\/><\/div> <div>Zip:<\/div> <div><input type=\"text\" id= \"txtZip\"\/> <\/td> <\/tr> <tr><\/div> <div> <\/div> <div> <\/div> <div> <\/div> <div><td>Phone:<\/td><td><\/div> <div><!-- textbox for phone --><\/div> <div><input type=\"text\" id= \"txtPhone\"><\/div> <div><\/td> <\/tr> <tr> <td>Email: <\/td> <td><\/div> <div><input type=\"text\" id=\"txtEmail\"><\/div> <div><\/td> <\/tr> <\/table><\/div> <div><h3> Step 2: Select the membership you want:<\/div> <div><\/h3> <!-- radio buttons --><\/div> <div><input type=\"radio\" name=\"membership\"<\/div> <div>\/>\"Weekly\"<\/div> <div><input type=\"radio\" name=\"membership\"<\/div> <div>\/>\"Monthly\"<\/div> <div><input type=\"radio\" name-\"membership\"<\/div> <div>\/>\"Yearly\"<\/div> <div><input type= \"radio\" name=\"membership\"<\/div> <div>\/>\"Quartly\"<\/div> <div><h3>Select the type of exercise you want: <\/h3><\/div> <div><!- Checkboxed for exercise --><\/div> <div><input type=\"checkbox\" name=\"exercise\"<\/div> <div>value=\/>Cardio<\/div> <div><input type= \"checkbox\" name=\"exercise\"<\/div> <div>value=\/>walking<\/div> <div><input type= \"checkbox\" name=\"exercise\"<\/div> <div>value=\/>Aerobic<\/div> <div> <\/div> <div><input type= \"checkbox\" name=\"exercise\"<\/div> <div>value=\/ >Yoga<\/div> <div><input type=\"checkbox\" name=\"exercise\"<\/div> <div>value=\/>Lifting<\/div> <div><input type=\"checkbox\" name=\"exercise\"<\/div> <div>value=\/>Cycling<\/div> <div> <\/div> <div><input type= \"checkbox\" name=\"exercise\"<\/div> <div>value=\/>Pilates<\/div> <div> <\/div> <div> <\/div> <div><input type= \"checkbox\" name= \"exercise\"<\/div> <div>value=\/>Trainer<\/div> <div> <!-- button to submit form --><\/div> <div><input type=\"button\" value=\"Submit Order\"<\/div> <div>onclick=\"displayOrder()\"\/><\/div> <div><input type=\"reset\" value= \"Clear Entries\"\/><\/div> <div><\/form> <div id= \"membership\"><\/div><\/div> <div> <\/div> <div><script> <\/div> <div> <\/div> <div> <\/div> <div> \/\/ New Code<\/div> <div>let Name = document.forms[\"myform\"]<\/div> <div>[\"txtName\"].value;<\/div> <div>if (Name ==\"\"){<\/div> <div>alert(\"Name must be filled out\"); }<\/div> <div>let Address = document.forms[\"myform\"]<\/div> <div>[\"txtAddress\"].value;<\/div> <div>if (Address==\"\"){<\/div> <div>alert(\"Address must be filled out\"); }<\/div> <div>let City = document.forms [\"myform\"]<\/div> <div>[\"txtCity\"].value;<\/div> <div>if (City ==\"\"){<\/div> <div>alert(\"City must be filled out\"); }<\/div> <div> <\/div> <div>let State = document.forms[\"myform\"]<\/div> <div>[\"txtState\"].value;<\/div> <div>if (State ==\"\"){<\/div> <div> alert(\"State must be filled out\"); }<\/div> <div>let ZIP = document.forms[\"myform\"]<\/div> <div>[\"txtZip\"].value;<\/div> <div>if (ZIP ==\"\"){<\/div> <div> alert(\"ZIP must be filled out\"); }<\/div> <div>let Phone = document.forms[\"myform\"]<\/div> <div>[\"txtPhone\"].value;<\/div> <div>if (Phone ==\"\"){ <\/div> <div> alert(\"Phone must be filled out\"); }<\/div> <div>let Email = document.forms [\"myform\"]<\/div> <div>[\"txtEmail\"].value;<\/div> <div>if (Email ==\"\"){<\/div> <div> alert(\"Email must be filled out\");}<\/div> <div>let memb=<\/div> <div>document.getElementsByName(\"membership\");<\/div> <div> <\/div> <div> <\/div> <div> <\/div> <div>var op=0; for(var i=0;i<memb.length;i++){<\/div> <div>\/\/checking which membership is selected<\/div> <div>if(memb[i].checked==true){<\/div> <div>\/\/if membership is selected then op=1; break; }}<\/div> <div>if (op==0) { alert(\"Choose membership\"); }<\/div> <div>let exe=<\/div> <div>document.getElementsByName (\"exercise\" );<\/div> <div>var ex=0; for(var i=0;i<exe.length;i++){<\/div> <div>\/\/checking which membership is selected<\/div> <div>if(exe[i].checked==true) {<\/div> <div>\/\/if membership is selected then ex=1; break; }}<\/div> <div>if(ex==0){ alert(\"Choose Excercise\");}<\/div> <div> <\/div> <div>\/\/new Code ended<\/div> <div>for(var i=0;i<membership.length;i++){<\/div> <div>\/\/checking which membership is selected<\/div> <div>if (membership[i].checked==true) {<\/div> <div>\/\/if membership is selected then<\/div> <div> <\/div> <div>members=membership[i].value+\"\";}}<\/div> <div>var name=(\"txtName\").value;\/\/getting name<\/div> <div>var address=(\"txtAddress\").value;\/\/getting ad<\/div> <div>var city=(\"txtCity\" ).value; \/\/getting city<\/div> <div>var state=(\"txtState\").value; \/\/getting State<\/div> <div>var state=(\"txtZip\").value;\/\/getting zip<\/div> <div>var phone=(\"txtPhone\").value; \/\/getting phone<\/div> <div>var email=(txtEmail\").value;\/\/getting email<\/div> <div> <\/div> <div>\/\/getting membership<\/div> <div>var<\/div> <div>membership=document.getElementsbyName();<\/div> <div>\/\/declaring variable to membership var members;<\/div> <div>\/\/using for loop<\/div> <div>for(var i=0;i<membership.length;i++){<\/div> <div> <\/div> <div>\/\/checking which membership is selected<\/div> <div>if(membership[i].checked==true) {<\/div> <div>\/\/if membership is selected then<\/div> <div>members=membership[i].value+\"\";} }<\/div> <div>\/\/getting exercise selected by user<\/div> <div>var exercise=document.getElementsbyName();<\/div> <div>\/\/declaring variable to exercise var exercise=\" \";<\/div> <div>\/\/using for loop for(var i=0;i<exercise.length;i++){<\/div> <div>\/\/checking which membership is selected<\/div> <div>if(membership[i].checked==true) {<\/div> <div>\/\/if exercise is selected then<\/div> <div> <\/div> <div> <\/div> <div> <\/div> <div> <\/div> <div>exercise+=exercise[i].value+\",\"; }}<\/div> <div>var htmlString=\"\";\/\/declaring variable to store<\/div> <div>htmlString+=\"<b>Name : <\/b>\" +name+\" <br\/><\/div> <div><b>Address: <\/b>\" +address + \"<br\/>\";<\/div> <div> <\/div> <div>htmlString+=\"<b>City: <\/b>\" +city+\" <br\/><\/div> <div><b>State: <\/b>\"+state+\"<br\/>\";<\/div> <div> <\/div> <div>htmlString+=\"<b>Email: <\/b>\" +email+\" <br\/><\/div> <div><b>membership: <\/b>\"+members+\" <br\/>\";<\/div> <div> <\/div> <div>htmlString+=\"<b>exercise: <\/b>\"+ exercise +\"<br\/>\";<\/div> <div> <\/div> <div>\/\/display details on the div<\/div> <div>(\"exercise\").innerHTML=htmlString;}<\/div> <div> <\/div> <div><\/script><\/div> <div><\/body><\/div> <div><\/html><\/div> <\/div>", "transcribed_text": "", "related_book": { "title": null, "isbn": null, "edition": null, "authors": null, "cover_image": null, "uri": null, "see_more_uri": "" }, "free_related_book": { "isbn": "", "uri": "", "name": "", "edition": "" }, "question_posted": "2024-09-08 22:13:19", "see_more_questions_link": null, "step_by_step_answer": "The Answer is in the image, click to view ...", "students_also_viewed": [ { "url": "\/study-help\/modern-mathematical-statistics-with-applications\/30-exercise-22-in-chapter-5-introduced-random-variables-x-1989438", "description": "30. Exercise 22 in Chapter 5 introduced random variables X and Y, the number of cars and buses, respectively, carried by a ferry on a single trip. The joint pmf of X and Y is given in the table in...", "stars": 0 }, { "url": "\/the-following-data-were-taken-from-the-balance-sheet-of-beatty-companybrbrdiv-aligncenterimg-srcimages352bmafsa", "description": "The following data were taken from the balance sheet of Marine Equipment Company: a. Determine for each year (1) The working capital (2) The current ratio (3) The quick ratio. b. What conclusions can...", "stars": 3 }, { "url": "\/study-help\/questions\/powers-company-reported-net-sales-of-1390000-and-average-accounts-10054646", "description": "Powers Company reported Net sales of $1,390,000 and average Accounts Receivable, net of $59,500. The accounts receivable turnover ratio is:", "stars": 3 }, { "url": "\/study-help\/questions\/1-provide-a-labelled-indifference-curve-diagram-a-maximizing-consumer-4632631", "description": "1. Provide a labelled Indifference Curve Diagram. A maximizing consumer with u(x, y) = x1\/2y1\/2 is endowed with x = 8 and y = 4 units of the goods. Prices are originally px = 1, py = 1. Now px = 4....", "stars": 3 }, { "url": "\/study-help\/questions\/maggie-just-had-a-car-accident-there-was-no-one-1410749", "description": "Maggie just had a car accident. There was no one seriously hurt, but both vehicles may be beyond repair. Maggie is obviously shaken up as she calls you for help. What symptoms might Maggie be...", "stars": 3 }, { "url": "\/study-help\/questions\/a-guest-received-a-full-day-package-at-the-spa-5318649", "description": "A guest received a full day package at the Spa from her husband as a gift. She makes an appointment and calls the day prior to re - confirm. When she arrives no reservations are found. The Spa is...", "stars": 3 }, { "url": "\/study-help\/questions\/1-using-invented-spelling-does-not-slow-down-or-prevent-1410818", "description": "1. Using invented spelling does not slow down or prevent a child from learning conventional spelling. True False 2. What impact has the statistical learning approach had on language learning? In...", "stars": 3 }, { "url": "\/study-help\/questions\/exercise-811-direct-materials-and-direct-labor-variances-lo-p2-7387582", "description": "Exercise 8-11 Direct materials and direct labor variances LO P2 Hutto Corp. has set the following standard direct materials and direct labor costs per unit for the product it manufactures. Direct...", "stars": 3 }, { "url": "\/study-help\/questions\/in-week-1-you-were-asked-to-consider-if-one-1411476", "description": "In Week 1, you were asked to consider if one domainphysical, cognitive, or social-emotionalwas more important than the others. Review your response. Have your views changed or strengthened? Explain...", "stars": 3 } ], "next_back_navigation": { "previous": "\/study-help\/questions\/programming-exercises-19-a-database-is-to-be-developed-to-9726481", "next": "\/study-help\/questions\/the-alpine-house-inc-is-a-large-retailer-of-snow-9726483" }, "breadcrumbs": [ { "name": "Study help", "link": "https:\/\/www.solutioninn.com\/study-help\/questions-and-answers" }, { "name": "Computer Science", "link": "https:\/\/www.solutioninn.com\/study-help\/questions-and-answers\/computer-science" }, { "name": "Databases", "link": "https:\/\/www.solutioninn.com\/study-help\/questions\/computer-science-databases" }, { "name": "****the alerts boxes and form validation are not working please fix the", "link": "https:\/\/www.solutioninn.com\/study-help\/questions\/the-alerts-boxes-and-form-validation-are-not-working-please-9726482" } ], "skill_details": { "skill_id": "656", "skill_name": "Databases", "parent_id": "8" } }