HTML | Scope Attribute - GeeksforGeeks

Skip to content geeksforgeeks
  • Courses
    • DSA Courses
    • Programming Languages
  • Tutorials
    • Python Tutorial
      • Python Loops and Control Flow
    • Java
      • Java Interview Questions
      • Java Quiz
      • Advance Java
    • Programming Languages
    • System Design
    • Interview Corner
    • Computer Science Subjects
    • DevOps
    • Linux
    • Software Testing
    • Databases
    • Android
    • Excel
    • Mathematics
  • DSA
    • Data Structures
    • Algorithms
      • Analysis of Algorithms
      • Searching Algorithms
      • Sorting Algorithms
    • Practice
      • Company Wise Coding Practice
      • Practice Problems Difficulty Wise
      • Language Wise Coding Practice
      • Curated DSA Lists
    • Company Wise SDE Sheets
    • DSA Cheat Sheets
    • Puzzles
  • Data Science
    • Data Science Packages
    • Data Visualization
    • Data Analysis
  • Web Tech
    • Web Development Using Python
      • Django
      • Flask
    • Cheat Sheets
  • HTML Tutorial
  • HTML Exercises
  • HTML Tags
  • HTML Attributes
  • Global Attributes
  • Event Attributes
  • HTML Interview Questions
  • HTML DOM
  • DOM Audio/Video
  • HTML 5
  • HTML Examples
  • Color Picker
  • A to Z Guide
  • HTML Formatter
Open In App HTML | <th> scope Attribute Last Updated : 01 Aug, 2022 Summarize Comments Improve Suggest changes Like Article Like Save Share Report Follow

The HTML <th> scope Attribute is used to specify the header cell is used for header row, column, colgroup or rowgroup. This attribute does not display any visual effect on the browser but it is used for screen readers.

Syntax:

<th scope="col | row | colgroup | rowgroup">

Attribute Values:

  • col: It specifies that the header cell is used for column.
  • row: It specifies that the header cell is used for row.
  • colgroup: It specifies that the header cell is used for group of column.
  • rowgroup: It specifies that the header cell is used for group of row.

Example:

html

<!DOCTYPE html> <html> <head> <title> HTML th scope Attribute </title> </head> <body> <h1>GeeksforGeeks</h1> <h2>HTML th scope Attribute</h2> <table border="1" width="500"> <tr> <th scope="col">NAME</th> <th scope="col">AGE</th> <th scope="col">BRANCH</th> </tr> <tr> <td>BITTU</td> <td>22</td> <td>CSE</td> </tr> <tr> <td>RAKESH</td> <td>25</td> <td>EC</td> </tr> </table> </body> </html>

Output:

Supported Browsers: The browser supported by HTML <th> scope attribute are listed below:

  • Google Chrome 1
  • Edge 12
  • Internet Explorer
  • Firefox 1
  • Safari
  • Opera
Comment More info Next Article HTML <tr> align Attribute author jit_t Follow Improve

Similar Reads

  • PHP get_resource_type() Function The get_resource_type() function is an inbuilt function in PHP that is used for returning the type of resource. Syntax: get_resource_type(resource $resource) Parameters: This function accepts one parameter that described below: $resource: This parameter specifies the evaluated resource handle name.R 1 min read
  • Get and Set in TypeScript In TypeScript, you can use the get and set keywords to define getter and setter methods within a class. These methods allow you to encapsulate the access and modification of class properties, providing a way to control and customize the behavior. In this article, we are going to learn to get and set 3 min read
  • HTML DOM selection.type property The type property returns a String which describes the type of current selection. This is a read-only property. Syntax: selection.type Return Value: String describing the type of the selection. Possible return values are: None: No selection has currently been made.Caret: Only Clicked but not selecte 1 min read
  • How To Get Types From Arrays in TypeScript? In TypeScript, arrays are a common data structure, but sometimes it's necessary to extract the types of elements stored in an array for type-checking or validation purposes. TypeScript provides several ways to extract types from arrays, enabling more type-safe operations. We will explore different m 4 min read
  • PHP | ReflectionProperty getName() Function The ReflectionProperty::getName() function is an inbuilt function in PHP which is used to return the name of the specified property. Syntax: string ReflectionProperty::getName ( void ) Parameters: This function does not accept any parameters. Return Value: This function returns the name of the speci 1 min read
  • PHP gettype() Function The PHP gettype() function returns the type of a variable as a string. It identifies the variable's data type, such as string, integer, array, boolean, etc., allowing developers to check and handle different data types dynamically. Syntax: string gettype ( $var )Parameter: This function accepts a si 3 min read
  • PHP | ReflectionParameter getType() Function The ReflectionParameter::getType() function is an inbuilt function in PHP which is used to return the type of the specified parameter. Syntax: ReflectionType ReflectionParameter::getType ( void ) Parameters: This function does not accept any parameters. Return Value: This function returns the type o 2 min read
  • How to Get a Variable Type in TypeScript Understanding how to effectively ascertain the type of a variable in TypeScript is important for maintaining type safety and ensuring code robustness. In this article, we'll explore various approaches to determine the type of a variable, ranging from basic JavaScript operators to TypeScript-specific 2 min read
  • JavaScript Handler getPrototypeOf() Method JavaScript handler.getPrototypeOf() method in JavaScript is a trap for the internal method. This method returns the same value as Object.getPrototypeOf(target) if the target object is not extensible. Syntax: const p = new Proxy(obj, { getPrototypeOf(target) { ... } }); Parameters: target: The target 2 min read
  • TypeScript Interfaces Type TypeScript Interfaces Type offers an alternative method for defining an object's type, allowing for a distinct naming approach. Syntax:interface InterfaceName { property1: type1; property2?: type2; readonly property3: type3; // ... method1(): returnType1; method2(): returnType2; // ...}Parameters:in 2 min read
  • PHP | ReflectionProperty isPrivate() Function The ReflectionProperty::isPrivate() function is an inbuilt function in PHP which is used to return TRUE if the specified property is private, FALSE otherwise. Syntax: bool ReflectionProperty::isPrivate ( void ) Parameters: This function does not accept any parameter. Return Value: This function retu 2 min read
  • PHP | ReflectionMethod getPrototype() Function The ReflectionMethod::getPrototype() function is an inbuilt function in PHP which is used to return the prototype of the specified method otherwise, an exception/error is returned if the method does not have a prototype. Syntax: ReflectionMethod ReflectionMethod::getPrototype( void ) Parameters: Thi 2 min read
  • How to Get an Object Value By Key in TypeScript In TypeScript, we can get an object value by key by accessing the specific properties within the objects of the dynamic type. This can be done using Dot Notation, Bracket Notation, and Optional Chaining. In this article, we will explore all these approaches along with their implementation in terms o 5 min read
  • PHP | ReflectionProperty getModifiers() Function The ReflectionProperty::getModifiers() function is an inbuilt function in PHP which is used to return the numeric representation of the specified modifiers. Syntax: int ReflectionProperty::getModifiers ( void ) Parameters: This function does not accept any parameters. Return Value: This function ret 2 min read
  • PHP | ReflectionProperty getDocComment() Function The ReflectionProperty::getDocComment() function is an inbuilt function in PHP which is used to return the doc comment of the specified property. Syntax: string ReflectionProperty::getDocComment ( void ) Parameters: This function does not accept any parameters. Return Value: This function returns th 2 min read
  • JavaScript Object getPrototypeOf() Method The JavaScript getPrototypeOf() is an inbuilt function in JavaScript that is used to check the prototype of an object that the user has created. Most of the time, It is used to check whether two objects have the same prototype or not. The prototype here means the internal definition of the object th 2 min read
  • JavaScript Handler getOwnPropertyDescriptor() Method JavaScript handler.getOwnPropertyDescriptor() method in Javascript is a trap for the Object.getOwnPropertyDescriptor() method. A property cannot be reported as non-existent if it exists as a non-configurable own property of the target object. Syntax: const p = new Proxy(target, { getOwnPropertyDescr 2 min read
  • JavaScript Object propertyIsEnumerable() Method The propertyIsEnumerable() method returns a Boolean indicating whether the specified property is enumerable and is the object's own property. The propertyIsEnumerable() method returns false if the object doesn't have the specified property. Syntax: obj.propertyIsEnumerable(prop) Parameters: This met 1 min read
  • How to get the native type of a value in JavaScript ? JavaScript variables can store any type of value. The JavaScript typeof operator can be used to find out the native type of value. It returns a string value indicating the type of the value. Syntax: typeof(value) Possible output values of typeof: TypeResultundefined"undefined"null"object"boolean"boo 1 min read
Article Tags :
  • HTML
  • Web Technologies
  • HTML-Attributes
Like three90RightbarBannerImg Explore More We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our Cookie Policy & Privacy Policy Got It ! Lightbox Improvement Suggest changes Suggest Changes Help us improve. Share your suggestions to enhance the article. Contribute your expertise and make a difference in the GeeksforGeeks portal. geeksforgeeks-suggest-icon Create Improvement Enhance the article with your expertise. Contribute to the GeeksforGeeks community and help create better learning resources for all. geeksforgeeks-improvement-icon Suggest Changes min 4 words, max CharLimit:2000

What kind of Experience do you want to share?

Interview Experiences Admission Experiences Career Journeys Work Experiences Campus Experiences Competitive Exam Experiences

Từ khóa » Html Col Scope