How To Make Toggle Button Using HTML & CSS

  Рет қаралды 64,221

MakeTechStuff

MakeTechStuff

Жыл бұрын

In this video i show you how to make a toggle button with checkbox using html & css. Or you can say in this video we are going to design checkbox or making custom checkbox.
For source code visit 👇 :
www.maketechstuff.com/
You may have to search on website ('toggle button').
______________________________
Related Videos :
Toggle button for dark and light mode.
• Dark and Light Mode To...
Animated toggle button.
• Toggle Switch Using HT...
Website with dark and light mode.
• How To Create Website ...
Custom rounded checkbox
• How To Create Custom C...
Sidebar menu close and hide using only html and css
• Sidebar Menu using onl...

Пікірлер: 59
@tanjirnu
@tanjirnu 3 ай бұрын
Sir, we are with you . keep doing what are you doing.......
@dynashiftgaming2861
@dynashiftgaming2861 7 ай бұрын
full support man. 🖤
@matsang2008
@matsang2008 6 ай бұрын
Nice. You made it so easy. No more blah blah and straight forward. Thanks
@Maketechstuffs
@Maketechstuffs Ай бұрын
Your welcome
@Nexaman18
@Nexaman18 19 күн бұрын
@@Maketechstuffs L easy bruuuh no explation just copy paste
@jvenkatonline
@jvenkatonline Ай бұрын
Simple and clear. I have seen multiple tutorials for this functionality, but this is very simple and easy-to-understand logic without any extra steps. Thanks.👍
@Maketechstuffs
@Maketechstuffs Ай бұрын
Your welcome
@jvenkatonline
@jvenkatonline Ай бұрын
@@Maketechstuffs particularly you keep the checkbox till the last minute. finally, you hide it (display: none). I like that approach. without any explanation, I could understand what you were doing.
@BlueAngleYt
@BlueAngleYt 4 ай бұрын
Amazing
@HushCode
@HushCode 4 ай бұрын
Sympa 👍
@chrisazuaje892
@chrisazuaje892 11 ай бұрын
Great video!
@Maketechstuffs
@Maketechstuffs 10 ай бұрын
Thanks!
@sarahpires2251
@sarahpires2251 Ай бұрын
Perfect
@LuisVZMusic
@LuisVZMusic Жыл бұрын
good
@amandacolares7501
@amandacolares7501 10 ай бұрын
great tutorial
@Maketechstuffs
@Maketechstuffs 10 ай бұрын
Glad you think so!
@S-Lomar
@S-Lomar 9 ай бұрын
This guy is the best 😍😍🥰🥰🥰😍🤣😂😂🤪🤪🤪😂😂😂😂
@gbbarn
@gbbarn 18 күн бұрын
Yeah, thanks chatGPT lol.
@S-Lomar
@S-Lomar 9 ай бұрын
Well done 🥰🥰🥰🥰🥰😍🥰🥰🥰🥰🥰🥰😍🥰👍👍🥰🥰🥰🥰🥰🥰🥰😍🥰🥰🥰🥰🥰
@introvert456
@introvert456 Жыл бұрын
You could easily make it by embedding online icons , but it was a fun that you totally made it by yourself ❤️
@d.s.h6629
@d.s.h6629 Жыл бұрын
do you mean icons
@introvert456
@introvert456 Жыл бұрын
@@d.s.h6629 oh sorry i wrote fonts by mistake
@S-Lomar
@S-Lomar 9 ай бұрын
😍😍😍😍😍😍😍😍😍😍😍😍😍😍😍
@S-Lomar
@S-Lomar 8 ай бұрын
😂😂😂😂😂😂😂😂😂😂😂😂😂😂
@introvert456
@introvert456 8 ай бұрын
@@S-Lomar waddup?
@mikhaildolgov
@mikhaildolgov Жыл бұрын
👍
@chrystnx
@chrystnx 11 ай бұрын
lindo
@0xGrowth
@0xGrowth Ай бұрын
What VsCode extension are you using that reflects the changes you're making to the code directly on the webpage?
@Maketechstuffs
@Maketechstuffs Ай бұрын
Live server
@HariBalaKumarR.V
@HariBalaKumarR.V 16 күн бұрын
Sir,I am newly learning html and css may I please know a proper road map(if you could provide) on how to master html and css or where to start and to end..
@Maketechstuffs
@Maketechstuffs 16 күн бұрын
You can learn from many websites. (One name is w3schools.com). Important thing is you have to practise. By creating different forms, web page, websites, etc. Then you'll get the idea of designing. Means how i can make this element this side or that side. How i can make this element below another element. How can i make this element appear in the centre. How can i add border on the top and bottom of this element. How can i show this elements side by side or in a line, or in a row. How can i add bullet points in the list items. How can i make the extra elements to appear from second line if first line is full. , Etc.
@NadeemJohn-xu4lu
@NadeemJohn-xu4lu 6 ай бұрын
NADEEMJOHN
@namesare4fools
@namesare4fools Жыл бұрын
trust me, if your priority is to build a product just use component library
@jeloxjdm8298
@jeloxjdm8298 Жыл бұрын
Backend engineer be like:
@menephyl007
@menephyl007 3 ай бұрын
wholl
@priyadharshinis6039
@priyadharshinis6039 Жыл бұрын
How to set its button on the right corner please respond me
@Maketechstuffs
@Maketechstuffs Жыл бұрын
Just replace the container class css .container{ background-color: #fff; display: flex; float: right; }
@krstev29
@krstev29 11 ай бұрын
I just don't know why when I click on the button nothing happens, i need to hide the checkbox behind the button so if works, I think
@Maketechstuffs
@Maketechstuffs 11 ай бұрын
No it won't works. If you hide checkbox behind button then how you click checkbox. It possible when you set pointer event none to button. But then also it only works when you click on checkbox and its too small to not visible (as it behind the button). Thats why here used label tag once checkbox bind with button. Now you can place checkbox anywhere in page or even hide it. Now when you click on checkbox or button is equal to click on button(label) and checkbox. You'll find more information on website (search toggle on website).
@russellpawlett3564
@russellpawlett3564 7 ай бұрын
I had the same issue, I missed a step in the instructions . Make sure in the container you have -- I missed the id="check" which made the button not transition if clicked on
@Rudymaze
@Rudymaze 7 ай бұрын
hi guy i have all these in place but still no transition @@russellpawlett3564
@realjonav
@realjonav Жыл бұрын
hey! could you help me turn this into a darkmode button?
@Maketechstuffs
@Maketechstuffs Жыл бұрын
You can add text(dark and loght mode) in front of toggle button and use this button as dark and light mode switch. And you can change design little bit.
@realjonav
@realjonav Жыл бұрын
@@Maketechstuffs i was asking if you knew how to actually make the button do a toggle where it would actually change the site to dark mode?
@Maketechstuffs
@Maketechstuffs Жыл бұрын
Ok I'll make video on it.
@realjonav
@realjonav Жыл бұрын
@@Maketechstuffs okay i’ll be waiting! :)
@Arman-df4wo
@Arman-df4wo 2 ай бұрын
​@@realjonav what you can do is add a event listener to that checkbox [event "change"] inside that a callback function this will check if this checked box is checked or not if checked add a class to body where all the colours for dark mode are described
@ilTHfeaa
@ilTHfeaa Ай бұрын
this doesn’t work if there’s multiple though
@Maketechstuffs
@Maketechstuffs Ай бұрын
It works.
@oquangtai6889
@oquangtai6889 Жыл бұрын
how can i use this button after coding it done?
@Maketechstuffs
@Maketechstuffs Жыл бұрын
You can use it as switch (dark and light mode, to on/off something, show & hide something etc... ) you can use as setting in your software. For example if button is ON show something, if button is OFF hide something. Use as autosave functionality. if button is ON (checkbox is checked) autosave enable, if OFF(checkbox is unchecked) autosave disable. And in many other ways you can use.
@Maketechstuffs
@Maketechstuffs 10 ай бұрын
Yes! you can make toggle button functional with js.
@manashkamaldey520
@manashkamaldey520 Жыл бұрын
good
@Maketechstuffs
@Maketechstuffs Жыл бұрын
Thanks
@NadeemJohn-xu4lu
@NadeemJohn-xu4lu 6 ай бұрын
NADEEMJOHN
CSS Dark Mode Toggle Button from scratch in 6 Minutes
6:58
Red Stapler
Рет қаралды 67 М.
You Don't Need JavaScript For This - CSS ONLY Infinite Scroll
23:35
Slaying The Dragon
Рет қаралды 42 М.
Чай будешь? #чайбудешь
00:14
ПАРОДИИ НА ИЗВЕСТНЫЕ ТРЕКИ
Рет қаралды 2,3 МЛН
Watermelon Cat?! 🙀 #cat #cute #kitten
00:56
Stocat
Рет қаралды 8 МЛН
A pack of chips with a surprise 🤣😍❤️ #demariki
00:14
Demariki
Рет қаралды 9 МЛН
Create an Animated Toggle Switch Button in CSS for Your Website 🔥
9:24
ASMR Programming: Dark/Light Toggle | Pure CSS
5:33
Codetive ASMR
Рет қаралды 14 М.
How to Create Toggle Button using HTML & CSS only | Hindi
8:31
Can I Create Accessible CSS Toggle Buttons?
24:14
Web Dev Simplified
Рет қаралды 243 М.
How to create Dropdown Menu in HTML & CSS
9:24
Web Component
Рет қаралды 46 М.
How to make a website light/dark toggle with CSS & JS
16:48
Kevin Powell
Рет қаралды 117 М.
Subtle, yet Beautiful Scroll Animations
5:04
Beyond Fireship
Рет қаралды 1,6 МЛН
Animated Dark Mode Toggle | CSS Dark Mode Toggle Button
9:52
Чай будешь? #чайбудешь
00:14
ПАРОДИИ НА ИЗВЕСТНЫЕ ТРЕКИ
Рет қаралды 2,3 МЛН