[null, {"document_url": "https://www.freecodecamp.org/forum/t/text-primary-class-not-working-in-h1-tag/141145", "unformatted_src": "//discourse-user-assets.s3.amazonaws.com/optimized/3X/0/b/0bac35aee1d80a534c927015ce728c3b98da8b91_1_690x387.png", "src": "http://discourse-user-assets.s3.amazonaws.com/optimized/3X/0/b/0bac35aee1d80a534c927015ce728c3b98da8b91_1_690x387.png", "formatted_filename": "bac aee d a c ce c b da b", "alt_text": "Screenshot (33)", "rendered_width": 690, "rendered_height": 387}, null]
Text-primary class not working in h1 tag

akash1 2017-08-11 12:51:37 UTC #1

.Hello friends!
I am working on “Build tribute page” challenge and I am running across a strange problem, that is, the" text-primary" class of bootstrap is working fine with all tags except for the

tag. I want the name" Dr. APJ Abdul Kalam" to be in blue using the text-primary class but its not working, although it worked just fine for the

tag.Please give ur valuale suggestions. Screenshot (33).png1366x768 262 KB

1ManStack 2017-08-11 13:54:32 UTC #2

Your problem is that your H1 tag is within your Jumbotron DIV which defines the H1 color.
To override this there are a few options, but here is my solution:

This within CSS will select the H1 element within the jumbotron class and color it to the HEX equivalent to text-primary within the Bootstrap FrameWork.

Edit: Link to the Pen for Everyone


akash1 2017-08-12 11:47:59 UTC #3

But so is my h3 tag.