Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Sunny Side Landing Page

@TeddyGavi

Desktop design screenshot for the Agency landing page coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


How would you do a drop-down menu using only HTML and CSS?

Community feedback

Chanda 800

@Chanda-Abdul

Posted

👋 Your Sunnyside landing page looks great!

Here are two approaches you could use to create a dropdown menu using just HTML and CSS:

  • Using the :target pseudo-class: This method involves defining targets within your HTML and using CSS to show/hide content based on the target's ID. By leveraging the :target selector, you can create a dropdown effect when certain elements are clicked or targeted. https://css-tricks.com/off-canvas-menu-with-css-target/

  • Using a form input checkbox styled as a menu: This method utilizes a checkbox <input> element within a form and applies CSS styles to make it appear like a menu. By toggling the checkbox's checked state, you can control the visibility of the dropdown menu through CSS selectors and transitions. https://css-tricks.com/the-checkbox-hack/

I hope these suggestions help!. If you have any further questions, feel free to ask!

Happy coding!

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord