how to change background color of active link navbar

  Рет қаралды 50,534

Pranjal Koshti

Pranjal Koshti

Күн бұрын

Пікірлер: 22
@govindmaurya6619
@govindmaurya6619 3 жыл бұрын
Thank you so much..I have been looking exactly for this..thanks a lot 😁
@mambakamsateesh1500
@mambakamsateesh1500 3 жыл бұрын
Really nice ji... Keep it up
@JustinVarghese
@JustinVarghese 2 жыл бұрын
can we do this by using only html and css only ?
@pranjalkoshti8586
@pranjalkoshti8586 2 жыл бұрын
U can use proper css selectors to target
@oussamabenrejab5382
@oussamabenrejab5382 2 жыл бұрын
thanks so much ; exactly what i am looking for ... many thanks :)
@akashkunjalwar3921
@akashkunjalwar3921 3 жыл бұрын
Your code works for me, if I select the link from menu bar, however, I would like to know the code to get the other way that is, the menu bar item should highlight according to what is active when I scroll to different divisions having links. Can you please help me regarding this?
@pranjalkoshti8586
@pranjalkoshti8586 3 жыл бұрын
For that purpose, use onScroll event, check if the particular section is in viewport and update the anchor tag styling accordingly. eg if user is scrolling and about section is in viewport, anchor tag for about will get highlighted.
@govindmaurya6619
@govindmaurya6619 3 жыл бұрын
Please make a video on this topic also..
@ISOnepal
@ISOnepal 4 жыл бұрын
can we work css in the same file withing style
@pranjalkoshti8586
@pranjalkoshti8586 4 жыл бұрын
you can use style tag
@rchauhan7379
@rchauhan7379 6 жыл бұрын
How can i set as like this type menu in html?
@ArunSingh-lq1cc
@ArunSingh-lq1cc 5 жыл бұрын
Hey Hi Pranjal I have added your code in my project it is working Thanks for that But i have one problem CSS is applying to the whole page want to apply that to my header only can you tell how to do
@pranjalkoshti8586
@pranjalkoshti8586 5 жыл бұрын
Add proper css selectors, may be that must be the issue, thanks :)
@md.shahinalam752
@md.shahinalam752 3 жыл бұрын
speak loudly , not hearing anything
@thefacttitle2452
@thefacttitle2452 6 жыл бұрын
nice voice and good explanation thanks
@pranjalkoshti8586
@pranjalkoshti8586 6 жыл бұрын
thanks
@jackhad7199
@jackhad7199 5 жыл бұрын
Its not working.
@pranjalkoshti8586
@pranjalkoshti8586 5 жыл бұрын
Sorry its too late, what was the problem?
@anthonyinabo2382
@anthonyinabo2382 5 жыл бұрын
god bless you
@smiley2474
@smiley2474 3 жыл бұрын
fake. doesnt work
@rami1329
@rami1329 4 жыл бұрын
legend
@mukeshjha7181
@mukeshjha7181 5 жыл бұрын
Thanks
Active Nav Link Indicator with Vanilla Javascript
5:56
Coding in Public
Рет қаралды 122 М.
Human vs Jet Engine
00:19
MrBeast
Рет қаралды 150 МЛН
SISTER EXPOSED MY MAGIC @Whoispelagheya
00:45
MasomkaMagic
Рет қаралды 17 МЛН
How to add Smooth Scrolling to your one page website with jQuery
19:50
Top 10 CSS One Liners That Will Blow Your Mind
13:34
developedbyed
Рет қаралды 972 М.
How to create a CSS navigation bar in 6 minutes! 🧭
6:28
Bro Code
Рет қаралды 335 М.
Sticky Navbar on Scroll With CSS | Change Navbar Color on Scroll With Javascript
7:36
Fabio Musanni - Programming Channel
Рет қаралды 53 М.
Add and Remove Active Class on Click
5:20
ByteGrad
Рет қаралды 42 М.
30 Programming Truths I know at 30 that I Wish I Knew at 20
17:41
Make Nav Link Active For Each Page With JavaScript
13:58
ByteGrad
Рет қаралды 40 М.
Show Active Nav Link with JavaScript
6:50
Coding in Public
Рет қаралды 18 М.
How to Change Hyper Link Color and Size| HTML & CSS
5:59
JustCoder181
Рет қаралды 11 М.