Browse Source
Instead of turning an empty URL into an href="" attribute that effectively does nothing, change it into an href="#" attribute that creates a link to the current page. When adding a relative/image prefix leave fragment-only links unmolested. They are meant to link somewhere on the current page and must not be changed. When inspecting the destination to determine whether to use the -i prefix instead of the -r prefix when both are given, ignore any trailing fragment. Fragments don't really make sense on image links and should never actually be sent to the server anyway by a behaving client, but match them properly in any case. Also make sure that URLs only get a prefix added at most once. Signed-off-by: Kyle J. McKay <mackyle@gmail.com>master

1 changed files with 8 additions and 3 deletions
Loading…
Reference in new issue