37 lines
		
	
	
		
			954 B
		
	
	
	
		
			Markdown
		
	
	
	
	
	
			
		
		
	
	
			37 lines
		
	
	
		
			954 B
		
	
	
	
		
			Markdown
		
	
	
	
	
	
---
 | 
						|
title: P Align Attribute
 | 
						|
---
 | 
						|
## P Align Attribute
 | 
						|
 | 
						|
### Important
 | 
						|
This attribute is not supported in HTML5. It is recommended to use the [`text-align` CSS property](https://guide.freecodecamp.org/css/text-align).
 | 
						|
 | 
						|
To align the text inside a `<p>` tag, this attribute will help.
 | 
						|
 | 
						|
### Syntax
 | 
						|
```html
 | 
						|
<p align="position">Lorem Ipsum...</p>
 | 
						|
```
 | 
						|
 | 
						|
### Attributes 
 | 
						|
 
 | 
						|
- **left**    -  Text aligns to the left            
 | 
						|
- **right**   -  Text aligns to the right           
 | 
						|
- **center**  -  Text aligns to the center          
 | 
						|
- **justify** -  All lines of text have equal width 
 | 
						|
 | 
						|
### Example
 | 
						|
 | 
						|
```html
 | 
						|
<html>
 | 
						|
<body>
 | 
						|
<p align="center">Paragraph align attribute example</p>
 | 
						|
</body>
 | 
						|
</html>
 | 
						|
```
 | 
						|
 | 
						|
#### More Information:
 | 
						|
* [CSS `text-align`](https://guide.freecodecamp.org/css/text-align)
 | 
						|
* [W3 - HTML 4.01 Specification](https://www.w3.org/TR/html401/struct/text.html#h-9.3.1)
 | 
						|
* [MDN - CSS Text Align](https://developer.mozilla.org/en-US/docs/Web/CSS/text-align)
 |