Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions MCA1/1B/70-ManishSinghPapola-2101107/Ans2.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
How to Link a CSS File to an HTML File(i.e., External CSS)

You can link your CSS file to your HTML file by adding a link element inside the head element of your HTML file, like so:

<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" src="style.css">
</head>
<body>

</body>
</html>

The link element has many uses, and it is important to specify the right attributes so that you can use it to import an external CSS stylesheet. We'll look at some important attributes now.

1.The rel attribute-The first of the two indispensable attributes is the rel attribute. You will use this attribute to tell the browser what the relationship is with the imported file.

You'll write rel="stylesheet" to tell the browser that you are importing a stylesheet.

2.The src attribute-The second indispensable attribute is the src attribute, which specifies the file to import.

A common situation is that the CSS file and the HTML file are in the same folder. In such a case you can write src="style.css".

If the CSS file and the HTML file are in different folders, you need to write the correct file that needs to go from the HTML file to the CSS file.

For example, a common situation is that the CSS file is in a folder that is a sibling to the HTML file, like so:

project --- index.html
css ---------- style.css
In this case you would need to write a path like "css/styles.css".

3.The type attribute-<link rel="stylesheet" src="style.css" type="text/css">
You use the type attribute to define the type of the content you're linking to. For a stylesheet, this would be text/css. But since css is the only stylesheet language used on the web, it is not only optional, but it is even a best practice not to include it.
1 change: 1 addition & 0 deletions MCA1/1B/70-ManishSinghPapola-2101107/Demo
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

53 changes: 53 additions & 0 deletions MCA1/1B/70-ManishSinghPapola-2101107/ans1.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
<!doctype html>
<html>
<head>
<title> student information </title>
</head>
<body bgcolor="sky blue">
<form>
<label> Name </label>
<input type="text" name="fname" required placeholder="enter name" maxlengTh="10"><br><br>

Email:
<input type="email" name="email" required placeholder="enter email" ><br><br>

Mobile number:
<input type="text" name="mobile" value="+91" size="2">
<input type="text" name="mobile" maxlength="10"><br><br><br>

Gender<br>
<input type="radio" name="radio" id="male">
<label for="male">Male </label><br>
<input type="radio" name="radio" id="female">
<label for="female">Female </label><br>
<input type="radio" name="radio" id="other">
<label for="other">Other </label><br><br>

<p>Courses </p>
<select>
<option> BCA </option>
<option> MCA </option>
<option> BBA </option>
<option> MBA </option>
<option> MBBS </option>
</select><br><br>

<p> Hobbies </p>
<input type="checkbox" name="hobbies">Singing
<input type="checkbox" name="hobbies">Dancing
<input type="checkbox" name="hobbies">Listening music
<input type="checkbox" name="hobbies">Reading novel<br><br>


<p> Date of Birth:</p>
<input type="datetime-local" name="d1">

<p> Address </p>
<textarea rows="5" cols="50"> </textarea><br><br>

<center>
<button> Submit </button>
</center>
</form>
</body>
</html>
1 change: 1 addition & 0 deletions MCA1/1B/hgfhfhdh
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

1 change: 1 addition & 0 deletions MCA1/1B/manish
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@