Archived topic
How to add padding to anchor text.
9 replies · Started by Ika on March 8, 2021
Hi guys,
Hope you and your family in good health.
FYI, right now when i click the anchor text link, as expected, it will jump to the corresponding anchor text. However, i notice that the there is no top padding making the text appears very close to the top of the screen (especially when viewed on mobile).
How do i add top padding to the anchored text?
Tq
Hi there,
can you share a link to a page where i can see the issue ?
Hi David,
Pls refer to the private info section.
Tq
Hi there,
A similar question has been asked here:
https://generatepress.com/forums/topic/how-to-increase-margin-of-smooth-scroll-sections
Consider my answer on the same topic found here:
https://generatepress.com/forums/topic/how-to-increase-margin-of-smooth-scroll-sections/page/2/#post-1634951
Hi Elvin,
Am not sure on how to use the script. Do i enable it through code snippet plugin?
Hi there,
tricky one - you can try adding this CSS to create a fake space above each of your H2 elements:
h2 {
padding-top: 40px;
margin-top: -40px;
}
Hi David,
Tq so much for the great advice. It works.
Am satisfied with the level of support i receive by GP team and i've decided to purchase lifetime license. Pls advice how to proceed.
Glad to hear that - and even happier to hear you upgraded !!
Upgrade done.
Tq guys.
:)