Problem/Motivation

It's currently not possible to save a link to a piece of content that has a fragment because normalizeHref
returns the entity: style href if the original href has an entity context.

Steps to reproduce

1. Create a piece of content with an alias /foo
2. Create another piece of content with a link in a wysiwyg field linking too /foo#bar
3. Save the content and notice the Linky created will be linking directly to the content and the fragment is lost.

Proposed resolution

As per the MR - we can simply detect the fragment and return it as part of the href.

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

acbramley created an issue. See original summary.

acbramley’s picture

Issue summary: View changes
Status: Active » Needs review

  • acbramley committed ba5aa0b on 2.x
    Issue #3248329 by acbramley: Fragments are stripped from links to...
acbramley’s picture

Status: Needs review » Fixed
jibran’s picture

Are we preserving the parameters?

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.