the effect you want to achieve is that when you click "View Baby by Category" on the right side of the picture, the drop-down menu appears on the right side of the screen. Currently, a drop-down menu appears when hovering, and you want to change it to appear after clicking. I tried the onclick event myself, but it didn"t work. Have the following questions:
- can you solve the problem with onclick alone?
- if you need to cooperate with javascript, how should you implement it in the most concise and practical js code? (try not to use jquery, but you can also use it if you can"t.)
I am not familiar with events such as onclick and javascript. I hope you can change the code and learn it by the way. Or give me a move. I hope your reply will become my motivation to learn js as soon as possible:)
Thank you!
here is the code:
</div>
</div>
</body>
</html>