saving . . . saved index.html or another name has been deleted. index.html or another name has been hidden .
index.html or another name
Title
Question
You said we have name the html file as index.html
But in assignment  you asked us to name ht as wedpage.html then how it render by default index.html or manually webpage.html

JavaScript How-to--use-JS-in-HTML 03-04 min 40-50 sec 28-05-23, 11:28 a.m. Trilochana

Answers:

// assignment.js
console.log("A");
console.log("B");

<!DOCTYPE html>
<html>
<head>
  <title>My JavaScript Assignment</title>
</head>
<body>
  <h1>Check the Console!</h1>

  <!-- Linking JavaScript file -->
  <script src="assignment.js"></script>
</body>
</html>
CSS
A
B

05-04-25, 3:10 p.m. fahumithaabdul2204@gmail.com


<span data-huuid="1153926414128598914" style="color: rgb(0, 29, 53); font-family: &quot;Google Sans&quot;, Arial, sans-serif; font-size: 18px;"> <code class="mv6bHd" style="background: none 0% 0% / auto repeat scroll padding-box border-box rgb(229, 237, 255); border-radius: 4px; font-family: monospace; padding-top: 0px; padding-bottom: 0px;">index.html</code> offers the convenience of default loading on a web server, other filenames like <code class="mv6bHd" style="background: none 0% 0% / auto repeat scroll padding-box border-box rgb(229, 237, 255); border-radius: 4px; font-family: monospace; padding-top: 0px; padding-bottom: 0px;">webpage.html</code> require explicit referencing to be accessed. </span><span data-huuid="1153926414128597213" style="color: rgb(0, 29, 53); font-family: &quot;Google Sans&quot;, Arial, sans-serif; font-size: 18px;">The choice of filename depends on whether the file is intended to be a default homepage or a specific page within a larger structure</span>
26-07-25, noon siya12032008


This example shows how to link an external JavaScript file to an HTML page. When the page loads, the JavaScript file runs and prints output in the browser console.


console.log("Hello JavaScript");

<span data-end="263" data-start="96"></span>

console.log("File linked successfully");



<!DOCTYPE html>

<html>

<head>

  <title>JavaScript Linking Example</title>

</head>

<body>

  <h1>Check the Console Output</h1>


  <script src="assignment.js"></script>

</body>

</html>

13-04-26, 8:03 p.m. 25cs655@skcet.ac.in


Log-in to answer to this question.