appernetic / hugo-bootstrap-premium

Hugo appernetic bootstrap premium theme
MIT License
83 stars 62 forks source link

"Back to top" not working. #1

Closed michw closed 7 years ago

michw commented 8 years ago

Hi guys,

"Back to top" feature not working for me. I'm not sure if it is general issue or not working for me only.

Steps to reproduce: I'm using Firefox 38.8.0

  1. Go to https://blog.appernetic.io/
  2. Scroll down, to the bottom of page.
  3. Click "back to top" link.

Cheers.

appernetic commented 8 years ago

Hi, yes you are right about that. It does not work in Chrome either.

I will try to fix it!

appernetic commented 8 years ago

If you are faster feel free to post a PR! :-)

michw commented 8 years ago

Last time I played with HTML, it was enough to add <a name="top"></a> right after <body> tag, and use <a href="#top">back to the top</a>. I'm too lame at present. ;-)

You use toplink class, maybe it's connected somehow with typo in layouts/partials/bloc/footer/nav.html: toplink vs topLink.

appernetic commented 8 years ago

Yes, it could be. There shouldn't be an error because it is originally cloned from hugo-bootstrap. So it is possibly a typo somewhere.

michw commented 8 years ago

It may be more complicated somehow. If you for instance go to https://blog.appernetic.io/2016/05/27/appernetic-theme-showcase-gallery/ and add #disqus_thread (should jump to the comments) in the end of URL, it will add extra slash (... -gallery/#/disqus_...)

michw commented 8 years ago

Same for anchors at blog.appernetic.io. For instance, following is working only when accessed 1st time: https://blog.appernetic.io/2016/04/29/how-to-build-a-mailing-list-with-zapier-and-mailchimp/#process-forms-in-a-static-website. Immediately after going there, it gets 'rewrite' somehow into ...mailchimp/#/process... and it's not working.

Appernetic-service commented 8 years ago

Hm, I have tested now and you are right about the #. I think it could be my Angular popover implementation that somehow messes things up.

appernetic commented 7 years ago

I replaced the anchor #, with a Javascript version that works. I also tried to change to html5 mode in Angular, but then only the address will be rewritten no redirect. So this was the only solution that works.