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

Nested entries within CKEditor fields sometimes fail to copy to other enabled sites #254

Closed
gregorterrill opened this issue Jun 18, 2024 · 2 comments
Assignees
Labels

Comments

@gregorterrill
Copy link

Description

Two separate but related issues:

  1. Nested entries within CKEditor fields on entries in an existing section sometimes fail to copy over when that section is enabled for a new site. Only the text value of the field comes over, and the nested entries get stripped out.
  2. Copy/pasting all content (including nested entries) from one CKEditor field to another (either another entry in the same language or the same entry in another language) often fails due to "Invalid entry ID" errors about the nested entries. Sometimes it works as expected and copies the nested entries over though, so it's inconsistent.

Steps to reproduce

  1. Create two sites with different languages.
  2. Create a new section, enabled for the primary site only. Propagation method is "Save entries to all sites enabled for this section"
  3. Create a CKEditor field (set to "Translate for each language") and add it to an entry type in that section. Allow this field to insert entries
  4. Populate some content in that section with nested entries within CKEditor.
  5. Enable the section for a second site.
  6. Wait for the entries to propagate to the second site.
  7. Look in the entry content for that second site - the CKEditor text content may have copied over, but not the nested entries (sometimes, this doesn't always happen).
  8. Switch to the first site and select all > copy the content of the field (including nested entries).
  9. Switch to the second site and attempt to paste. You should see invalid entry ID errors for each of the nested entries:

Screenshot 2024-06-18 at 9 36 46 AM

Sometimes they appear like this, and then the block will disappear after saving:

Screenshot 2024-06-18 at 10 36 20 AM

Additional info

  • Craft version: 5.2.1
  • PHP version: 8.2.20
  • Database driver & version: MySQL 8.0.37
  • Plugins & versions: CKEditor 4.1.0, Code Field 5.0.0
@i-just
Copy link
Contributor

i-just commented Jun 20, 2024

Hi, thanks for reporting and for a clear description! They are two separate issues, indeed. I raised a PR for them.

@brandonkelly
Copy link
Member

CKEditor 4.2.0 is out with those fixes. Thanks again!

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

3 participants