By using our mini forum, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy

Q: which is best in External Style Sheet or Internal Style Sheet?

+1 vote
Which is best in External Style Sheet or Internal Style Sheet? what is difference between both of them?
asked in Other category by user Nehasood
recategorized by user golearnweb

1 Answer

+1 vote
There are  three different ways to insert the CSS.
"External Stylesheet", "Internal Stylesheet", or in "Inline Style".
The benefit for using each depends on what you are doing with the Style.
An internal stylesheet holds the CSS code for the webpage in the head section of the particular file. This makes it easy to apply styles like classes or id's in order to reuse the code. The downside of using an internal stylesheet is that changes to the internal stylesheet only effect the page the code is inserted into.
The External Stylesheet is a .css file that you link your website to. This makes it so that what ever you change in the .css sheet, will effect every page in your website. This prevents you from having to make many code changes in each page. This is for "global" site changes.
answered by user vilma
edited by user golearnweb