Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic site-link detection not working #360

Closed
NickLanger1990 opened this issue Feb 8, 2022 · 1 comment
Closed

Automatic site-link detection not working #360

NickLanger1990 opened this issue Feb 8, 2022 · 1 comment
Labels

Comments

@NickLanger1990
Copy link

NickLanger1990 commented Feb 8, 2022

Description

I tried to use the new feature automatic site-link detection but cant get it to work.

Steps to reproduce

  1. go into html mode and paste <a href="/testlink" target="_blank">TestLink</a> and save. it doesnt matter if the link is relative or absolute.
  2. click on edit link.
  3. the link is still the same as before. multisite is selected in site.
  4. if i change multsite to my site a "@4" is appended to the url.
  5. if i change this changes in the modal and reopen it "mailto:" is prepended to the url.
  6. if go in html mode again in a field i already edited and change something again and click with my cursor anywhere in the field my recent changes get revoked.

Additional info

  • Craft version: Craft Pro 3.7.28
  • PHP version: 8.0.13
  • Database driver & version: MySQL 5.7.36
  • Plugins & versions: Redactor 2.9.1
@andris-sevcenko
Copy link
Contributor

Relative links won't work, because Craft uses the absolute URL to figure out which site a potential element match should be looked up by the URI.

I also improved the behavior of the site dropdown - it will now appear only for links that look like they are element references for elements that are localized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants