How to configure URL to centralize object

1

I made a navbar that when clicking on an item it redirects to the same page for a div that has the id attribute, but the site stays navbar over the text

<li>
   <a href="#Especialidades">Especialidades</a>
</li>

Isitpossibletoconfiguresomethingsothatclickingontheitemstayslikethis?

    
asked by anonymous 30.10.2017 / 22:32

2 answers

2

Add a padding-top: 30px; to div "Specialties" that solves the problem of higher spacing.

    
30.10.2017 / 23:19
0

If the link is internal to the page, put it at the beginning of the place (in the photo as "specialties") and add a margin size the size of navbar

    
30.10.2017 / 22:35