cms
cms copied to clipboard
Link Fieldtype don't translate entries to current site #multi-site
Bug description
I am using the Link Fieldtype a lot for buttons so users can choose between an url or an entry. Right now i use the Link Fieldtype in a multi-site website. When you select an entry and you create the site for another site, than the Link Fieldtype always returns the url of the entry you selected and not the url of the entry of the current site.
How to reproduce
- Have a multi-site installation
- Add a Link Fieldtype to a collection
- Create a new entry in site A and select another entry in the Link Fieldtype which also has a version for site A and site B.
- Duplicate the entry to site B and just save and publish the entry.
- In the frontend you will always get the url of Site A, even when the current site is site B
Logs
No response
Environment
Statamic 3.3.29 Pro
Laravel 8.83.23
PHP 8.0.19
4rn0/statamic-v3-image-optimizer 1.0.15
doublethreedigital/duplicator 2.3.1
joetannenbaum/antlers-stack-tags 0.1.0
optimoapps/statamic-bard-text-align 1.0.2
rias/statamic-button-box 2.0.3
spatie/statamic-algolia-places 1.1.0
spatie/statamic-responsive-images 2.13.0
withcandour/aardvark-seo 2.0.28
withcandour/statamic-markdown-table 1.0.0-beta
Installation
Fresh statamic/statamic site via CLI
Antlers Parser
runtime (new)
Additional details
I have created a solution already, i will make a PR for it.