Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Linking a CSS external sheet to a HTML pageI am trying to test my web design skills by using just a text editor rather than drea

Featured Replies

Is there some sort of code to link the two?

Do I have to do something different in a text editor to make the pages link?

Do I have to position the CSS file somewhere different in the site folder?

 

Cheers

Yes you can do this.

 

Put css in different folder and give that link to <link> tag.

 

Thanks

<link rel="stylesheet" type="text/css" href="url-to-your-stylesheet.css" />

 

This piece of code needs to go inside your <head> tag.

 

:)

Edited by MarkJenner

Where MarkJenner says href="url-to-your-stylesheet.css it may be easier for you to put the stylesheet in the same folder as the html file (and the same directory online at the server) so then the link will be simpler, for a stylesheet named styles.css it would be

<link rel="stylesheet" type="text/css" href="styles.css" />

 

If you have the stylesheet in a separate folder/directory the path will be different. If the folder/directory is called css and this folder is inside the folder with the html file (ie lower level) the code would be:-

<link rel="stylesheet" type="text/css" href="css/styles.css" />

 

and if the css folder/directory is at the same level as the folder/directory with the html file (ie both inside the root folder/directory) the link will be:-

<link rel="stylesheet" type="text/css" href="../css/styles.css" />

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.