CSS Outline

CSS Outline

In CSS (Cascading Style Sheets), the outline property is used to create a visible outline around an element. It is similar to the border property, but it does not take up any space or affect the layout of the element.

The outline property accepts several values:

  • outline-width: Specifies the thickness of the outline. It can be set to a specific value (in pixels, ems, or other units) or one of the predefined values: thin, medium, or thick.
  • outline-style: Defines the style of the outline. It can be set to solid, dashed, dotted, double, groove, ridge, inset, or outset. These values are similar to the ones used for the border-style property.
  • outline-color: Sets the color of the outline. It can be specified using a color name, a hex code, an RGB value, or any other valid CSS color format.
  • outline-offset: Specifies the distance between the outline and the element’s border or edge. It creates space between the outline and the content, allowing it to be visually separated from the element.

Here’s an example of how to use the outline property:

css
/* Applying outline to an element */
.example {
  outline: 2px solid blue;
}

/* Using individual outline properties */
.example {
  outline-width: 2px;
  outline-style: solid;
  outline-color: blue;
  outline-offset: 5px;
}

It’s important to note that the outline property is not supported in some older versions of Internet Explorer (up to IE8). However, it is widely supported in modern browsers.

Leave a Reply

Your email address will not be published. Required fields are marked *

GLOTRU Footer
Popular Features
Popular Services/

Website Development & Design

App Development & Design

Graphic Design

Digital Marketing

SEO (Search Engine Optimization)

SMM (Social Media Marketing)

Cyber Security

Company

GLOTRU Founder & CEO : __Azam

Registared : Trade,MSME,etc

Board of Director

Team

About Us

Contact Us

Privacy Policy

Return & Refund Policy

Abuse Policy

Copyright Policy

Cookie Policy

Terms & Conditions

Universal Terms of Service

Disclaimer

Legal

Sponsorships

Investor

Press Releases

Our Investments

Brands

Newsroom

Business

...

_

Digital Millennium Copyright Act
DMCA.com Protection Status

_

Content similarity detection
Protected by Copyscape

_

***ANTI-PIRACY WARNING***

...................................................................................

Follow Us :

...................................................................................

SECURE SERVER : [Legal] [Privacy Policy] [Universal Terms of Service] [Do not sell my personal information]

SITE HOSTED : GLOTRU SECURE SERVER Asian Data Centre [You can host your site][Click Here]

SSL : Server Type : [Cloudflare] Certificate Issued By : [Let's Encrypt] Signature Algorithm : [ECDSA with SHA-384]

SITE BUILD SOFTWARE : Content Management System (CMS) Softwere

_

_

_