Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Navigating around website adds a [object object] to URL after clicking around anchors

Thanks for reading. I just wanted to know why i get a "/index.html#[object Object]" at the end of URL when clicking around anchors on a single page website.

I would also like to know if i can remove it if it isn’t too game changing with htaccess or resolve the issue that is occuring?

If you require more information that isn’t in this help request feel free to ask 🙂 !

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

The website the-md.studio

>Solution :

On your custom.js file, this line (~147):

enter image description here

window.location.hash = target;

target is not the selector, is a jquery element, so it’s an object.

Change it for this one:

window.location.hash = target.selector;

I think that’s what you want

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading