Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Weird Interaction with $location.hash() and Chrome/Firefox #10659

Closed
@bobber205

Description

@bobber205

When I enter the following into Chrome

http://www.example.com/enter/contest#top

it turns into

http://www.example.com/enter/contest/#top

This also happens when just running $location.hash("top") without any hashes in the URL.

This causes $location.hash() to be "". I need this check because if I do $location.hash("top") in any repeated function I get #top#top. I have a simple "is it already 'top' if check but since chrome messes with the url, it's always blank.

$location.hash("top");
$anchorScroll();

makes the url fwiw

http://www.example.com/enter/contest/#top#top

Any ideas of a work around?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions