text
stringlengths
69
2.38k
<s>[INST] <<SYS>> Write an HTML page with a header that displays your name. <</SYS>> [/INST] <html> <head> <title>My webpage</title> </head> <body> <h1>My name is John Smith</h1> </body> </html> </s>
<s>[INST] <<SYS>> Update the following HTML page so it displays a simple form. <</SYS>> <!DOCTYPE html> <html> <head> <title>My Form</title> </head> <body> <!-- Your code goes here! --> </body> </html> [/INST] <!DOCTYPE html> <html> <head> <title>My Form</title> </head> <body> <form action="#"> <label for="name">Name:</label> <input type="text" name="name"> <label for="email">Email:</label> <input type="text" name="email"> <button>Submit</button> </form> </body> </html> </s>
<s>[INST] <<SYS>> Edit the existing code to focus the cursor in the input field. <</SYS>> <html> <body> <input type="text" id="myInput" /> <script type="text/javascript"> document.getElementById('myInput').focus(); </script> </body> </html> [/INST] <html> <body> <input type="text" id="myInput" autofocus /> <script type="text/javascript"> document.getElementById('myInput').focus(); </script> </body> </html> </s>
<s>[INST] <<SYS>> Compose a basic HTML page to display the phrase "Contact us now!" <</SYS>> [/INST] <html> <head> <title>Contact Page</title> </head> <body> <h1>Contact Us Now!</h1> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page with a form having two textboxes and two buttons. <</SYS>> [/INST] <html> <body> <form> <input type="text" id="textbox1" /><br> <input type="text" id="textbox2" /><br> <button name="submitbtn">Submit</button><br> <button name="resetbtn">Reset</button><br> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML template for a login form having username and password. <</SYS>> [/INST] <html> <head> <title>Login Form</title> </head> <body> <form action="" method="POST"> <label>Username:</label><input type="text" /> <label>Password:</label><input type="password" /> <input type="submit" /> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a table containing the following data in four rows. <</SYS>> Id | First Name | Last Name | Age 1 | John | Doe | 30 2 | Jane | Doe | 25 3 | Brian | Smith | 32 4 | Maria | Smith | 28 [/INST] <html> <head> <title>Table Data</title> </head> <body> <table> <thead> <tr> <th>Id</th> <th>First Name</th> <th>Last Name</th> <th>Age</th> </tr> </thead> <tbody> <tr> <td>1</td> <td>John</td> <td>Doe</td> <td>30</td> </tr> <tr> <td>2</td> <td>Jane</td> <td>Doe</td> <td>25</td> </tr> <tr> <td>3</td> <td>Brian</td> <td>Smith</td> <td>32</td> </tr> <tr> <td>4</td> <td>Maria</td> <td>Smith</td> <td>28</td> </tr> </tbody> </table> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page with two headings "Home" and "About". <</SYS>> [/INST] <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Title</title> </head> <body> <h1>Home</h1> <h1>About</h1> </body> </html> </s>
<s>[INST] <<SYS>> Develop an HTML page with a div and table, and use CSS to make alternating rows of the table red and blue. <</SYS>> [/INST] <html> <head> <style> table tr:nth-child(2n) { background-color: red; } table tr:nth-child(2n+1) { background-color: blue; } </style> </head> <body> <div> <table> <tr> <th>Cell 1</th> <th>Cell 2</th> <th>Cell 3</th> </tr> <tr> <td>Data 1</td> <td>Data 2</td> <td>Data 3</td> </tr> <tr> <td>Data 4</td> <td>Data 5</td> <td>Data 6</td> </tr> </table> </div> </body> </html> </s>
<s>[INST] <<SYS>> Generate a dynamic HTML table displaying 10 random numbers from 1 to 100. <</SYS>> [/INST] <html> <head> </head> <body> <div> <table> <tr><th>Random Numbers</th></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> <tr><td><?php echo rand(1,100); ?></td></tr> </table> </div> </body> </html> </s>
<s>[INST] <<SYS>> Develop an HTML form which includes two input fields, an label and a submit button. <</SYS>> [/INST] <html> <head> </head> <body> <form> <label>Name: </label><input type="text" name="name"><br> <label>Age: </label><input type="text" name="age"><br> <input type="submit" value="Submit"> </form> </body> </html> </s>
<s>[INST] <<SYS>> Develop an HTML page with three sections, each containing different colors. <</SYS>> [/INST] <html> <head> <style> #section1 { background-color: red; } #section2 { background-color: blue; } #section3 { background-color: yellow; } </style> </head> <body> <div id="section1"></div> <div id="section2"></div> <div id="section3"></div> </body> </html> </s>
<s>[INST] <<SYS>> Construct a set of HTML tags to design a simple two-column layout. <</SYS>> [/INST] <html> <head> <title>Two-column layout</title> </head> <body> <div class="container"> <div class="column-left"> <!--Your content here--> </div> <div class="column-right"> <!--Your content here--> </div> </div> </body> </html> </s>
<s>[INST] <<SYS>> Write some HTML code that adds a background color to the complete web page. <</SYS>> [/INST] <html> <head> <style> body {background-color: #F0F0F0;}</style> </head> </html> </s>
<s>[INST] <<SYS>> Create a website that displays the current day's weather forecast in Philadelphia. <</SYS>> [/INST] <html> <head> <title>Weather App</title> </head> <body> <h1>Weather in Philadelphia</h1> <h2>Today</h2> <div id="weather"> <script> // API call to get the weather forecast fetch("https://api.weather.gov/gridpoints/PHI/20,34/forecast") .then(response => response.json()) .then(data => { // store data in variables let tempHigh = data.properties.periods[0].temperature let tempLow = data.properties.periods[0].temperatureTrend let weatherDescription = data.properties.periods[0].shortForecast let windSpeedInMPH = data.properties.periods[0].windSpeed let windDirection = data.properties.periods[0].windDirection // create HTML string for displaying the forecast let forecastHTML = ` <p><strong>Today's High:</strong> ${tempHigh}&deg;F</p> <p><strong>Today's Low:</strong> ${tempLow}&deg;F</p> <p><strong>Description:</strong> ${weatherDescription}</p> <p><strong>Wind Speed:</strong> ${windSpeedInMPH} MPH, ${windDirection}</p> ` // display forecast on the page document.getElementById('weather').innerHTML = forecastHTML; }); </script> </div> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page which displays the result of multiplying two user-provided numbers. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Multiply</title> </head> <body> <h1>Multiplication Result</h1> <form action="" method="POST"> Enter the first number: <input type="text" name="num1"><br> Enter the second number: <input type="text" name="num2"><br> <input type="submit" value="Submit"> </form> <p> <?php if ($_SERVER['REQUEST_METHOD'] == 'POST') { $num1=$_POST['num1']; $num2=$_POST['num2']; echo "Result: ".$num1*$num2; } ?> </p> </body> </html> </s>
<s>[INST] <<SYS>> Write a short HTML page to display a welcome message. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Welcome</title> </head> <body> <h1>Welcome!</h1> </body> </html> </s>
<s>[INST] <<SYS>> Generate a valid HTML page with the following styles and content <</SYS>> background color: yellow; padding: 10px; Content: "Hello World!" [/INST] <html> <head> <title>Hello World!</title> <style> body { background-color: yellow; padding: 10px; } </style> </head> <body> <p>Hello World!</p> </body> </html> </s>
<s>[INST] <<SYS>> Edit this HTML code to add the Google Font “Roboto”. <</SYS>> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>My First Web Page</title> </head> <body> </body> </html> [/INST] <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <link href="https://fonts.googleapis.com/css?family=Roboto&display=swap" rel="stylesheet"> <title>My First Web Page</title> <style> body { font-family: 'Roboto', sans-serif; } </style> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page that displays two columns consisting of the numbers 1 to 10. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Two columns of numbers from 1 to 10</title> </head> <body> <h1>Two columns of numbers from 1 to 10</h1> <table> <tr> <th>Column 1</th> <th>Column 2</th> </tr> <tr> <td>1</td> <td>6</td> </tr> <tr> <td>2</td> <td>7</td> </tr> <tr> <td>3</td> <td>8</td> </tr> <tr> <td>4</td> <td>9</td> </tr> <tr> <td>5</td> <td>10</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Design a HTML page with a header and 2 sections <</SYS>> [/INST] <html> <head> <title>MyPage</title> </head> <body> <header> <h1>Welcome to My Page</h1> </header> <section> Content in Section 1 </section> <section> Content in Section 2 </section> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page to display a table in the following format. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Table</title> </head> <body> <table> <tr> <th>Name</th> <th>Address</th> <th>Phone</th> </tr> <tr> <td>John</td> <td>123 Fake Street</td> <td>123-456-7890</td> </tr> <tr> <td>Jane</td> <td>456 Real Street</td> <td>098-765-4321</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page containing an input field, a submit button and a table for displaying the results. <</SYS>> [/INST] <html> <head> <title>A Sample HTML Page</title> </head> <body> <form> <input type="text" id="input-field" /> <input type="submit" value="Submit" /> </form> <table> <tr> <th>Results</th> </tr> <tbody id="results-table"> </tbody> </table> </body> </html> </s>
<s>[INST] <<SYS>> Generate a web page which shows the top 10 trending movies of the year. <</SYS>> [/INST] <html> <head> <title>Top 10 Trending Movies of the Year</title> </head> <body> <h1>Top 10 Trending Movies of the Year</h1> <ul> <li>Avengers: Endgame</li> <li>Captain Marvel</li> <li>Spider-Man: Far From Home</li> <li>Toy Story 4</li> <li>Joker</li> <li>Aladdin</li> <li>John Wick 3</li> <li>The Lion King</li> <li>Rocketman</li> <li>Once Upon a Time in Hollywood</li> </ul> </body> </html> </s>
<s>[INST] <<SYS>> Generate an HTML page with a table containing all the elements of an array in JavaScript. <</SYS>> [1, 2, 3, 4] [/INST] <html> <head> <title>Array Table</title> </head> <body> <table> <tr> <th>Element Value</th> </tr> <tr> <td>1</td> </tr> <tr> <td>2</td> </tr> <tr> <td>3</td> </tr> <tr> <td>4</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page with given header and footer elements. <</SYS>> Header: <h1>Hi there!</h1> Footer: <h5>Goodbye!</h5> [/INST] <html> <head> <title>Page Title</title> </head> <body> <h1>Hi there!</h1> <div> // Page content goes here </div> <h5>Goodbye!</h5> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page that has a button to toggle a navigation bar. <</SYS>> [/INST] <html> <head> <title>Menu toggle example</title> </head> <body> <h1>Toggle Menu</h1> <div id="menu-container"> <a href="link1.html">Link 1</a> <a href="link2.html">Link 2</a> <a href="link3.html">Link 3</a> </div> <button id="toggle-menu">Toggle Menu</button> <script> let toggleButton = document.getElementById('toggle-menu'); let menuContainer = document.getElementById('menu-container'); toggleButton.onclick = function(){ if (menuContainer.style.display == 'none'){ menuContainer.style.display = 'block'; } else { menuContainer.style.display = 'none'; } } </script> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page to display all the weekdays <</SYS>> [/INST] <html> <head> <title>Weekdays</title> </head> <body> <h1>Weekdays</h1> <ul> <li>Monday</li> <li>Tuesday</li> <li>Wednesday</li> <li>Thursday</li> <li>Friday</li> <li>Saturday</li> <li>Sunday</li> </ul> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page which displays the current time and date. <</SYS>> [/INST] <html> <body> <p>Today is <span id="date"> </span> and the time is <span id="time"> </span>.</p> <script> let d = new Date(); let date = d.toDateString(); document.getElementById("date").innerHTML = date; let time = d.toLocaleTimeString(); document.getElementById("time").innerHTML = time; </script> </body> </html> </s>
<s>[INST] <<SYS>> Draft an HTML page with a table that contains three columns and two rows. <</SYS>> [/INST] <html> <head> <title>Table Example</title> </head> <body> <table> <tr> <th>Column 1</th> <th>Column 2</th> <th>Column 3</th> </tr> <tr> <td>Row 1 Data 1</td> <td>Row 1 Data 2</td> <td>Row 1 Data 3</td> </tr> <tr> <td>Row 2 Data 1</td> <td>Row 2 Data 2</td> <td>Row 2 Data 3</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page demonstrating the application of "for" loop in JavaScript <</SYS>> [/INST] <html> <head> <script> for(let i=0; i<5; i++){ console.log('loop ' + i); } </script> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Generate a HTML table to display the following data. <</SYS>> Row1: Name: Harry Age: 18 Row2: Name: Jane Age: 20 [/INST] <html> <head> <title>Data Table</title> </head> <body> <h1>Data Table</h1> <table> <tr> <th>Name</th> <th>Age</th> </tr> <tr> <td>Harry</td> <td>18</td> </tr> <tr> <td>Jane</td> <td>20</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page displaying 3 columns of data <</SYS>> Data: ["Name", "Age", "Gender"], ["Bob", 35, "Male"], ["John", 28, "Male"], ["Sarah", 39, "Female"] [/INST] <html> <head> <title>Data</title> </head> <body> <table> <thead> <th>Name</th> <th>Age</th> <th>Gender</th> </thead> <tbody> <tr> <td>Bob</td> <td>35</td> <td>Male</td> </tr> <tr> <td>John</td> <td>28</td> <td>Male</td> </tr> <tr> <td>Sarah</td> <td>39</td> <td>Female</td> </tr> </tbody> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page containing a form with three input boxes. <</SYS>> [/INST] <html> <body> <form> <input type="text" name="box1" /> <input type="text" name="box2" /> <input type="text" name="box3" /> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page of a multi-step registration form. <</SYS>> Step 1: Name and Email Step 2: Address Step 3: Password [/INST] <html> <head> <title>Registration Form</title> <style> body { font-family: sans-serif; } .container { width: 500px; margin: 0 auto; } .form-steps { padding: 20px 0; } .form-step { padding: 10px; border: 1px solid #ccc; background-color: #eee; } .active { background-color: #cdeb8e; } button { background-color: #3f51b5; color: #fff; padding: 8px 15px; border: 0; margin-top: 20px; } </style> </head> <body> <div class="container"> <div class="form-steps"> <div class="form-step active"><p>Step 1: Name and Email</p></div> <div class="form-step"><p>Step 2: Address</p></div> <div class="form-step"><p>Step 3: Password</p></div> </div> <form> <input type="text" placeholder="Name" /> <input type="text" placeholder="Email" /> <input type="text" placeholder="Address" /> <input type="password" placeholder="Password" /> <button>Submit</button> </form> </div> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML document with a heading, a paragraph and a link to www.example.com. <</SYS>> [/INST] <html> <head> <title>Example HTML</title> </head> <body> <h1>Heading</h1> <p>This is a paragraph.</p> <a href="www.example.com">Link to example.com</a> </body> </html> </s>
<s>[INST] <<SYS>> Write a HTML web page with a heading, paragraph, and a form with two input fields, one for name and one for age. <</SYS>> [/INST] <html> <head> <title>Example HTML</title> </head> <body> <h1>Heading</h1> <p>This is a paragraph.</p> <form> Name: <input type="text" name="name" /> Age: <input type="number" name="age" /> <input type="submit" /> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page with a header containing the text "My page" and an empty body section. <</SYS>> [/INST] <html> <head> <title>My page</title> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page that displays the name, address, email and phone number of a given user. <</SYS>> Name: John Doe Address: 123 Main Street Email: john@example.com Phone: 987654321 [/INST] <html> <head> <title>John Doe's information</title> </head> <body> <h1>John Doe</h1> <p> Address: 123 Main Street <br> Email: john@example.com <br> Phone: 987654321 </p> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page to display a result of a dictionary containing all countries in the world and its corresponding capital in three columns. <</SYS>> [/INST] <html> <head> <title>Countries and Capitols</title> </head> <body style="background-color: #f9f9f9; font-family: sans-serif; padding: 50px"> <h1 style="text-align:center; color: #444444;">World Countries and Capitols</h1> <p>Below is a list of countries and capitols, presented in three columns: country, capital and continent.</p> <table style="width:100%;border: 1px solid #444444; text-align: center; margin:20px auto;"> <tr> <th style="background-color:#444444; color: #ffffff">Country</th> <th style="background-color:#444444; color: #ffffff">Capital</th> <th style="background-color:#444444; color: #ffffff">Continent</th> </tr> <tr> <td>Australia</td> <td>Canberra</td> <td>Oceania</td> </tr> <tr> <td>Brazil</td> <td>Brasilia</td> <td>South America</td> </tr> <tr> <td>China</td> <td>Beijing</td> <td>Asia</td> </tr> <tr> <td>USA</td> <td>Washington D.C.</td> <td>North America</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page from scratch to display a user's contact information. <</SYS>> name: John Doe; age: 46; phone: +1 (312) 555-4879; email: john.doe@example.com; [/INST] <!DOCTYPE html> <html> <head> <title>John Doe's Contact Information</title> </head> <body> <h2>John Doe</h2> <p>Age: 46</p> <p>Phone: +1 (312) 555-4879</p> <p>Email: john.doe@example.com</p> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page with a header and a paragraph, both with some text. <</SYS>> [/INST] <html> <head> <title>My Web Page</title> </head> <body> <h1>My Web Page</h1> <p>This is my web page. It has a header and a paragraph.</p> </body> </html> </s>
<s>[INST] <<SYS>> Construct a HTML page which displays a table with all words of a given string. <</SYS>> string = "Hello World" [/INST] <html> <head> <title>Table of Words</title> </head> <body> <table border="1"> <tr> <th>Word</th> </tr> <tr> <td>Hello</td> </tr> <tr> <td>World</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page that displays the text "My favorite color is blue" in a blue font. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>My Favorite Color</title> </head> <body> <h1 style="color: blue;">My favorite color is blue</h1> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML code to display a webpage with a centered paragraph. <</SYS>> [/INST] <html> <head> <title>Centered Paragraph</title> </head> <body> <div style="text-align:center;"> <p>This is a centered paragraph.</p> </div> </body> </html> </s>
<s>[INST] <<SYS>> Create a new HTML page and add a <div> element inside the <body>. <</SYS>> [/INST] <html> <head> <title>New Page</title> </head> <body> <div></div> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page to display the current weather in your city. <</SYS>> The weather data should be in the form of temperature, humidity, wind speed, and barometric pressure. [/INST] <html> <head> <title>Current Weather</title> </head> <body> <p>Temperature: <span id="temperature"></span></p> <p>Humidity: <span id="humidity"></span></p> <p>Wind Speed: <span id="wind_speed"></span></p> <p>Barometric Pressure: <span id="pressure"></span></p> <script> // Weather data from API const api_url = 'api_url'; fetch(api_url) .then(response => response.json()) .then(data => { document.getElementById('temperature').innerHTML = data.temperature; document.getElementById('humidity').innerHTML = data.humidity; document.getElementById('wind_speed').innerHTML = data.windSpeed; document.getElementById('pressure').innerHTML = data.pressure; }); </script> </body> </html> </s>
<s>[INST] <<SYS>> Design an HTML form to register users on a website. <</SYS>> [/INST] <html> <head> <title>User Registration Form</title> </head> <body> <h1>Register a new user</h1> <form action="register.php" method="POST"> <label>First Name:</label><br> <input type="text" name="firstName" required><br><br> <label>Last Name:</label><br> <input type="text" name="lastName" required><br><br> <label>Email:</label><br> <input type="text" name="email" required><br><br> <label>Password:</label><br> <input type="password" name="password" required><br><br> <input type="submit" value="Register"> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page which displays "Hello, World!" on the screen. <</SYS>> [/INST] <html> <head> <title>Hello, World!</title> </head> <body> <h1>Hello, World!</h1> </body> </html> </s>
<s>[INST] <<SYS>> Add AJAX functionalities to the following HTML document. <</SYS>> <!DOCTYPE html> <html> <head> <title>AJAX Example</title> </head> <body> </body> </html> [/INST] <!DOCTYPE html> <html> <head> <title>AJAX Example</title> <script> function loadData(){ var xhttp = new XMLHttpRequest(); xhttp.onreadystatechange = function() { if (this.readyState == 4 && this.status == 200) { document.getElementById("data").innerHTML = this.responseText; } }; xhttp.open("GET", "data.txt", true); xhttp.send(); } </script> </head> <body> <h2>AJAX Example</h2> <div id="data">AJAX will place the data here</div> <button type="button" onclick="loadData()">Load data</button> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with an <h1> heading "Welcome!" and a <p> paragraph with the text "I am happy to be here." <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Welcome!</title> </head> <body> <h1>Welcome!</h1> <p>I am happy to be here.</p> </body> </html> </s>
<s>[INST] <<SYS>> Change the following HTML page to an Angular web page. <</SYS>> <html> <head> <title>TITLE</title> </head> <body> <h1>HEADER</h1> <p>Paragraph</p> </body> </html> [/INST] <!DOCTYPE html> <html> <head> <title>TITLE</title> <script src="https://unpkg.com/@angular/core@8.2.14/bundles/core.umd.js"></script> <script src="https://unpkg.com/@angular/common@8.2.14/bundles/common.umd.js"></script> <script src="https://unpkg.com/@angular/platform-browser@8.2.14/bundles/platform-browser.umd.js"></script> <script src="https://unpkg.com/@angular/platform-browser-dynamic@8.2.14/bundles/platform-browser-dynamic.umd.js"></script> </head> <body> <h1>HEADER</h1> <app-root>Paragraph</app-root> <script> //This will handle the rendering of the Angular app platformBrowserDynamic().bootstrapModule(AppModule); </script> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page to show a list of employees, their departments and corresponding salary ranges. <</SYS>> John Doe - Sales - 35000 - 50000 Jane Doe - Marketing - 40000 - 65000 [/INST] <html> <head> <title>Employees</title> </head> <body> <h1>Employees</h1> <ul> <li>John Doe - Sales - 35000 - 50000</li> <li>Jane Doe - Marketing - 40000 - 65000</li> </ul> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a header containing the text "Welcome to our website". <</SYS>> [/INST] <html> <head><title>Welcome to our website</title></head> <body> <h1>Welcome to our website</h1> </body> </html> </s>
<s>[INST] <<SYS>> Generate a HTML code which has a black background and white font. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <style> body { background-color: black; color: white; } </style> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Construct a HTML page that displays a form with a text field and a submit button. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Sample Form</title> </head> <body> <form action="" method="post"> <input type="text" placeholder="Input..."/> <input type="submit" value="Submit" /> </form> </body> </html> </s>
<s>[INST] <<SYS>> Edit this HTML page to make the page have a centered heading <</SYS>> <html> <head> <title>Sample Page</title> </head> <body> <h1>Heading</h1> </body> </html> [/INST] <html> <head> <title>Sample Page</title> </head> <body> <h1 style="text-align: center;">Heading</h1> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a blurred background and centered text "Hello World". <</SYS>> [/INST] <html> <head> <style> body { background-image: url("background.jpg"); background-size: cover; background-blur: 10px; } .container { position: relative; text-align: center; } </style> </head> <body> <div class="container"> <h1>Hello World</h1> </div> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page that displays the current time. <</SYS>> [/INST] <html> <head> <title>Time Display</title> <script> function updateTime() { let currTime = new Date(); document.getElementById("currentTime").innerHTML = currTime.toLocaleTimeString(); } </script> </head> <body onload="updateTime()"> <div id="currentTime"></div> </body> </html> </s>
<s>[INST] <<SYS>> Use HTML and CSS to format a page with three columns, two of which contain two paragraphs each and the last containing a list of 10 items. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>3 Column Layout</title> <style> body { width: 1000px; margin: 0 auto; } .column-left { float: left; width: 33%; } .column-center { float: left; width: 33%; } .column-right { float: left; width: 33%; } </style> </head> <body> <div class="column-left"> <p>Paragraph 1</p> <p>Paragraph 2</p> </div> <div class="column-center"> <p>Paragraph 3</p> <p>Paragraph 4</p> </div> <div class="column-right"> <ul> <li>Item 1</li> <li>Item 2</li> <li>Item 3</li> <li>Item 4</li> <li>Item 5</li> <li>Item 6</li> <li>Item 7</li> <li>Item 8</li> <li>Item 9</li> <li>Item 10</li> </ul> </div> </body> </html> </s>
<s>[INST] <<SYS>> Generate a HTML document with 3 divs, each div being 50px wide and 100px tall <</SYS>> [/INST] <html> <head> <title>HTML Div Test</title> </head> <body> <div style="width:50px; height:100px;">Div 1</div> <div style="width:50px; height:100px;">Div 2</div> <div style="width:50px; height:100px;">Div 3</div> </body> </html> </s>
<s>[INST] <<SYS>> Using jQuery, update the HTML code to provide the user a toggle switch that changes the text from "off" to "on" when clicked. <</SYS>> <div> <p>Status: <span class='status'>off</span></p> </div> [/INST] <div> <p>Status: <span class='status'>off</span> <button onclick="toggleStatus()">Toggle</button> </p> <script> function toggleStatus() { $('.status').text($('.status').text() === 'off' ? 'on' : 'off'); } </script> </div> </s>
<s>[INST] <<SYS>> Create an HTML page with a form containing a checkbox. <</SYS>> [/INST] <html> <body> <form> <input type="checkbox" /> </form> </body> </html> </s>
<s>[INST] <<SYS>> Using HTML and CSS, create a page layout with two columns and a header row. <</SYS>> [/INST] <html> <head> <style> .table { display: table; width: 100%; } .table-row { display: table-row; } .table-cell { display: table-cell; } </style> </head> <body> <div class="table"> <div class="table-row"> <div class="header table-cell">Header</div> </div> <div class="table-row"> <div class="table-cell">Column 1</div> <div class="table-cell">Column 2</div> </div> </div> </body> </html> </s>
<s>[INST] <<SYS>> Rewrite this HTML code so that it is valid HTML5. <</SYS>> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Example website</title> </head> <body> <h1>My example website</h1> <p>This is some example text</p> </body> </html> [/INST] <!DOCTYPE html> <html> <head> <title>Example website</title> </head> <body> <h1>My example website</h1> <p>This is some example text</p> </body> </html> </s>
<s>[INST] <<SYS>> Create a simple php website using the following data records. <</SYS>> [ { "firstname": "Oliver", "lastname": "Smith", "address": "1234 Main Street, City, Country" }, { "firstname": "John", "lastname": "Doe", "address": "5678 Long Road, City, Country" }, { "firstname": "Chris", "lastname": "Fitzgerald", "address": "9123 Eagle Street, City, Country" } ] [/INST] <!DOCTYPE html> <html> <head> <title>Simple PHP Website</title> </head> <body> <?php $data = [ [ "firstname" => "Oliver", "lastname" => "Smith", "address" => "1234 Main Street, City, Country" ], [ "firstname" => "John", "lastname" => "Doe", "address" => "5678 Long Road, City, Country" ], [ "firstname" => "Chris", "lastname" => "Fitzgerald", "address" => "9123 Eagle Street, City, Country" ] ]; foreach($data as $person) { echo '<p>'; echo $person['firstname'] . ' ' . $person['lastname'] . '<br/>'; echo $person['address']; echo '</p>'; } ?> </body> </html> </s>
<s>[INST] <<SYS>> Using HTML and CSS, create a page to display a list of users with their contact information <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>User Info</title> <style> tr, td { border: 1px solid black; padding: 5px; } </style> </head> <body> <table> <tr> <td>Name</td> <td>Phone Number</td> <td>Email</td> </tr> <tr> <td>John Smith</td> <td>9121231234</td> <td>john.smith@example.com</td> </tr> <tr> <td>John Doe</td> <td>4564564567</td> <td>john.doe@example.com</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Design an HTML form to enter student name, age, and course. <</SYS>> [/INST] <html> <head> <title>Student Info Form</title> </head> <body> <form action="/submit" method="POST"> <label>Name:</label><br> <input type="text" name="name"><br><br> <label>Age:</label><br> <input type="number" name="age"><br><br> <label>Course:</label><br> <input type="text" name="course"><br><br> <input type="submit" value="Submit"> </form> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML code to create a basic structure for a website. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>My Website</title> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML program to simulate a digital clock <</SYS>> [/INST] <html> <head> <title>Digital Clock</title> <script> function showTime(){ var date = new Date(); var h = date.getHours(); // 0 - 23 var m = date.getMinutes(); // 0 - 59 var s = date.getSeconds(); // 0 - 59 var session = "AM"; if(h == 0){ h = 12; } if(h > 12){ h = h - 12; session = "PM"; } h = (h < 10) ? "0" + h : h; m = (m < 10) ? "0" + m : m; s = (s < 10) ? "0" + s : s; var time = h + ":" + m + ":" + s + " " + session; document.getElementById("MyClockDisplay").innerText = time; document.getElementById("MyClockDisplay").textContent = time; setTimeout(showTime, 1000); } showTime(); </script> </head> <body> <div> <h2>Digital Clock:</h2> <div id="MyClockDisplay" class="clock"></div> </div> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page that has a table and populates the table with the given data. <</SYS>> Country | Capital India | New Delhi United States | Washington DC Canada | Ottawa [/INST] <!DOCTYPE html> <html> <head> <title>Country and Capital Table</title> </head> <body> <h1>Country and Capital Table</h1> <table> <tr> <th>Country</th> <th>Capital</th> </tr> <tr> <td>India</td> <td>New Delhi</td> </tr> <tr> <td>United States</td> <td>Washington DC</td> </tr> <tr> <td>Canada</td> <td>Ottawa</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a button and a text field to print the content of the text field when the button is clicked. <</SYS>> [/INST] <html> <head> <title>Print Text</title> </head> <body> <input type="text" id="textField" /> <button onclick="printText()">Print</button> <script> function printText(){ let text = document.getElementById("textField").value; console.log(text); } </script> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page to display three columns with headings ‘Name’, ‘Age’ and ‘Occupation’ in a table layout. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Simple Table Layout</title> </head> <body> <h1>Table with Three Columns</h1> <table> <tr> <th>Name</th> <th>Age</th> <th>Occupation</th> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Write a HTML page to set a background color for a table with the color code '#e6e6fa'. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Table with Background Color</title> </head> <body> <h1>Table with Background Color</h1> <table style="background-color: #e6e6fa;"> <tr> <th>Name</th> <th>Age</th> <th>Occupation</th> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Create an interface for a number guessing game using HTML, CSS, and JavaScript. <</SYS>> [/INST] <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Number Guessing Game</title> <style> * { padding: 0; margin: 0; } #guessing-game-container { min-height: 100vh; padding: 20px; background: #f5f5f5; text-align: center; } .form-group { display: flex; justify-content: center; align-items: center; flex-direction: column; } </style> </head> <body> <div id="guessing-game-container"> <div> <h1>Guess a number between 1 and 100!</h1> </div> <div class="form-group"> <label for="guess">Guess:</label> <input type="number" id="guess"> </div> <button id="submit-guess-btn">Submit</button> <div id="guess-notification"> </div> </div> </body> <script> const minNum = 1; const maxNum = 100; let correctNum = Math.floor(Math.random() * (maxNum - minNum + 1)) + minNum; const submitBtn = document.getElementById("submit-guess-btn"); const guessNotification = document.getElementById("guess-notification"); submitBtn.addEventListener("click", function() { const guessInput = document.getElementById("guess"); const guess = parseInt(guessInput.value); if (Number.isNaN(guess)) { guessNotification.innerHTML = "Please enter a valid number"; } else if (guess < minNum || guess > maxNum) { guessNotification.innerHTML = `Number must be between ${minNum} and ${maxNum}`; } else if (guess !== correctNum) { guessNotification.innerHTML = `Guess is ${guess < correctNum ? "too low" : "too high"}`; } else { guessNotification.innerHTML = "Correct!"; } }); </script> </html> </s>
<s>[INST] <<SYS>> Generate a valid HTML page given the body contents. <</SYS>> <h1>Hello World!</h1> <p>This is a simple HTML page.</p> [/INST] <html> <head> </head> <body> <h1>Hello World!</h1> <p>This is a simple HTML page.</p> </body> </html> </s>
<s>[INST] <<SYS>> Create a simple webpage to welcome visitors with a centered heading "Welcome". <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Welcome</title> <style> h1 { text-align: center; } </style> </head> <body> <h1>Welcome</h1> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML web page with a header, a body and a footer section. <</SYS>> [/INST] <html> <head> <title>My Web Page</title> </head> <body> <!-- content goes here --> </body> <footer> <!-- footer content goes here --> </footer> </html> </s>
<s>[INST] <<SYS>> Create a web page that contains three input boxes for a user to input name, age, and gender. <</SYS>> [/INST] <html> <head> <title>Input Form</title> </head> <body> <form> Name:<br> <input type="text" name="name"><br> Age:<br> <input type="number" name="age"><br> Gender:<br> <input type="radio" name="gender" value="male"> Male<br> <input type="radio" name="gender" value="female"> Female<br><br> <input type="submit"> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create a basic HTML skeleton for a web page. <</SYS>> [/INST] <html> <head> <title>Basic Webpage</title> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create a basic form in HTML containing two input boxes for first name and surname. <</SYS>> [/INST] <html> <head> <title>User Information Form</title> </head> <body> <form> First Name:<br> <input type="text" name="firstname"><br> Surname:<br> <input type="text" name="surname"><br><br> <input type="submit"> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create a basic HTML page with a <title> tag and a <h1> tag. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>Create a basic HTML page</title> </head> <body> <h1>Hello, World!</h1> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page that takes two text strings as inputs and outputs the longest one. <</SYS>> [/INST] <html> <head> <title>Input and Compare Strings</title> </head> <body> Enter two strings: <input type="text" id="str1" /> <input type="text" id="str2" /> <input type="button" value="Submit" onclick="compareStrings()" /> <div id="result"/> <script> function compareStrings() { let str1 = document.getElementById("str1").value; let str2 = document.getElementById("str2").value; let longest = (str1.length > str2.length) ? str1 : str2; document.getElementById("result").innerHTML = "The longest string is: " + longest; } </script> </body> </html> </s>
<s>[INST] <<SYS>> Write a HTML form to take in two user inputs and display their sum. <</SYS>> [/INST] <html> <body> <form> Enter Number 1: <input type="text" name="num1" /> <br /> Enter Number 2: <input type="text" name="num2" /> <br /> <input type="submit" value="Submit" /> </form> <script> function calculateSum() { let num1 = document.forms["form"]["num1"].value; let num2 = document.forms["form"]["num2"].value; document.write("Sum of the two numbers is: " + (num1 + num2)); } </script> </body> </html> </s>
<s>[INST] <<SYS>> Construct an HTML form with five input fields: Name, Username, Password, Email, and Phone number. <</SYS>> [/INST] <html> <body> <form> <label for="name">Name:</label> <input type="text" id="name" name="name"> <br> <label for="username">Username:</label> <input type="text" id="username" name="username"> <br> <label for="password">Password:</label> <input type="password" id="password" name="password"> <br> <label for="email">Email:</label> <input type="text" id="email" name="email"> <br> <label for="phone">Phone number:</label> <input type="number" id="phone" name="phone"> <br> </form> </body> </html> </s>
<s>[INST] <<SYS>> Format the following HTML tags correctly. <</SYS>> <html><head> <title>hello world</title></head></html> [/INST] <html> <head> <title>Hello World</title> </head> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a Table, which lists out the names and usernames of 4 people. <</SYS>> Jenny, jenny123 John, john123 Alice, alice123 Bob, bob123 [/INST] <!DOCTYPE html> <html> <head> <title>Table example</title> </head> <body> <h1>Names and Usernames</h1> <table> <thead> <tr> <th>Name</th> <th>Username</th> </tr> </thead> <tbody> <tr> <td>Jenny</td> <td>jenny123</td> </tr> <tr> <td>John</td> <td>john123</td> </tr> <tr> <td>Alice</td> <td>alice123</td> </tr> <tr> <td>Bob</td> <td>bob123</td> </tr> </tbody> </table> </body> </html> </s>
<s>[INST] <<SYS>> Build a HTML page using the given CSS class <</SYS>> CSS Classes: .container { width: 300px; height: 200px; background-color: blue; } .text { color: white; font-family: Arial; font-size: 16px; padding: 15px; text-align: center; } [/INST] <html> <head> <style> .container { width: 300px; height: 200px; background-color: blue; } .text { color: white; font-family: Arial; font-size: 16px; padding: 15px; text-align: center; } </style> </head> <body> <div class="container"> <div class="text">Hello World!</div> </div> </body> </html> </s>
<s>[INST] <<SYS>> Edit this HTML code to add a link element in the head of the page. <</SYS>> <html> <head> <title>Example page</title> </head> <body> </body> </html> [/INST] <html> <head> <title>Example page</title> <link href="style.css" rel="stylesheet"> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create a web page that shows a short biography of the given person. <</SYS>> Person: Marie Curie [/INST] <html> <head> <title>Biography of Marie Curie</title> </head> <body> <h1>Marie Curie</h1> <p>Marie Curie (1867-1934) was a Polish physicist and chemist who conducted pioneering research on radioactivity and discovered the elements radium and polonium. She was twice awarded the Nobel Prize, first in physics in 1903, and again in 1911 in chemistry. She is one of the most famous female scientists in history, and continues to be an inspiration to scientists around the world.</p> </body> </html> </s>
<s>[INST] <<SYS>> Generate the HTML code for a page with a centered headline that says "My Portfolio". <</SYS>> [/INST] <html> <head> <title>My Portfolio</title> </head> <body> <center> <h1>My Portfolio</h1> </center> </body> </html> </s>
<s>[INST] <<SYS>> Edit the following HTML structure to include the Bootstrap 4 library. <</SYS>> <html> <head> <title>My Web Page</title> </head> <body> </body> </html> [/INST] <html> <head> <title>My Web Page</title> <link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css" integrity="sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z" crossorigin="anonymous"> <script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script> <script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js" integrity="sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN" crossorigin="anonymous"></script> <script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js" integrity="sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV" crossorigin="anonymous"></script> </head> <body> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page containing a login form with the following fields: username, password, and submit button. <</SYS>> [/INST] <html> <head> <title>Login Form</title> </head> <body> <form action="/login" method="POST"> <input type="text" name="username" placeholder="Username"/> <input type="password" name="password" placeholder="Password"/> <input type="submit" value="Submit"/> </form> </body> </html> </s>
<s>[INST] <<SYS>> Create an HTML page with a text input form and a submit button. <</SYS>> [/INST] <html> <head> <title>Text Input Form</title> </head> <body> <form action="/submit" method="POST"> <input type="text" name="input" placeholder="Enter Text"/> <input type="submit" value="Submit"/> </form> </body> </html> </s>
<s>[INST] <<SYS>> Write an HTML page that displays a table containing the following columns: "Name", "Age", and "Marital Status". <</SYS>> [/INST] <html> <head> <title>Example Table</title> </head> <body> <table> <tr> <th>Name</th> <th>Age</th> <th>Marital Status</th> </tr> <tr> <td>John</td> <td>25</td> <td>Single</td> </tr> <tr> <td>Jane</td> <td>30</td> <td>Married</td> </tr> </table> </body> </html> </s>
<s>[INST] <<SYS>> Construct a basic HTML page that renders a heading, a description of the page, and a photo. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>My Page</title> </head> <body> <h1>My Page</h1> <p>This is my first HTML page.</p> <img src="sample-image.jpg" alt="sample image"> </body> </html> </s>
<s>[INST] <<SYS>> Create a HTML page with a list of items. <</SYS>> [/INST] <html> <head> <title>My List</title> </head> <body> <h1>My List</h1> <ul> <li>Item 1</li> <li>Item 2</li> <li>Item 3</li> </ul> </body> </html> </s>
<s>[INST] <<SYS>> Create a website using HTML and CSS. <</SYS>> [/INST] <!DOCTYPE html> <html> <head> <title>My Website</title> <link rel="stylesheet" href="style.css"> <head> <body> <h1>My Website</h1> <div class="content"> Content goes here. </div> </body> </html> //style.css body { font-family: sans-serif; font-size: 14px; color: #000; background-color: #fff; } h1 { text-align: center; color: #444; font-size: 20px; margin-top: 20px; } .content { font-size: 12px; padding: 10px; } </s>
<s>[INST] <<SYS>> Write HTML code to create a navigation bar with links to Home and About pages. <</SYS>> [/INST] <div> <ul> <li><a href="/home">Home</a></li> <li><a href="/about">About</a></li> </ul> </div> </s>
<s>[INST] <<SYS>> Create a HTML page which includes a header, subheader and a paragraph of text. <</SYS>> [/INST] <html> <head> <title>My Page</title> </head> <body> <h1>My Page</h1> <h2>Subheader</h2> <p>This is some text in my page.</p> </body> </html> </s>