Tell us what’s happening:
Describe your issue in detail here.
Write the details of a function that prompts the user for a color and uses what the user typed to set the link color within the existing web page Your code so far
<h1>Hello</h1>
<h1>Hello world!</h1>
Your browser information:
User Agent is: Mozilla/5.0 (Linux; Android 10; TECNO KC8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.88 Mobile Safari/537.36
1.Write the details of a function that prompts the user for a color and uses what the user typed to set the link color within the existing web page.
function changeLinkColor (){var color = prompt (“Enter a color '','''');document.link = color;}
Monday:
Question-.Write a function that generates a complete web page containing a list with 50 items. The items should be item1 through item50
<script>function genList() { document.open(); document.write("<html><head></head><body>"); document.write("<ul>"); for (var i=1; i <= 50; i++) { document.write("<li> item" + i + "</li>"); } document.write("</ul></body></html>"); document.close(); }</script>
Help me resolve and give correct answer
format:
<body ID="bdy"><p>Pick a background color for this page.</p><form name="form1"> <b> Color </b> <input type="text" name="body"><br> <input type="button" value="Change color onclick="changeBgColor()"><br></form></body>and then uses that color to set the background color of the web page.function changeBgColor() { }function changeBgColor(){var bodycolor = document.form1.body.value;document.getElementById("bdy").style.backgroundColor = bodycolor;}
I’ve edited your post for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.
You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.
.Write and test run the details of a function that prompts the user for a color and uses what the user typed to set the link color within the existing web page.
While we are primarily here to help people with their Free Code Camp progress, we are open to people on other paths, too. Some of what you are asking is pretty trivial in the Free Code Camp context, so you might find that if you’re not getting the instruction and material you need in your current studies, the FCC curriculum will really help you get started. At a modest guess I’d say investing a 4-5 hours working through the curriculum here will really pay off. You can find the curriculum at https://www.freecodecamp.org/learn.
With your current questions, we don’t have enough context to know what you already know or don’t know, so it is impossible to guide you without just telling you the answer (which we won’t do).
It is pretty typical on here for people to share a codepen / repl.it / jsfiddle example of what they have tried so that anyone helping has more of an idea of what help is actually helpful.
Please provide some example of what you’ve tried and I’m sure you’ll get more help.
Test Input
function changeLinkColor (){var color = prompt (“Enter a color '','''');document.link = color;} function display(){alert (document.exam.first.value + " " +document.exam.last.value);} function genList() { document.open(); document.write(""); document.write("
"); for (var i=1; i <= 50; i++) { document.write("