The error you are encountering when inserting a PDF file through the CMS-button in Joomla 5.1 seems to be related to the TinyMCE editor and the Joomla media manager integration. This error is specific to the joomla-media-select.min.js script and appears to involve an issue with the getSelection function.
Here are some potential steps to resolve or work around this issue:
Check for Plugin Conflicts:
Disable third-party plugins one by one to see if any of them are causing a conflict.
Specifically look at any plugins related to TinyMCE or the media manager.
Review Joomla Updates:
Ensure all Joomla core and extension updates are applied. There might be a minor update or patch available that addresses this issue.
Check the Joomla issue tracker and forums for any reported bugs or fixes related to this problem.
Revert to Previous Version:
If this issue is blocking essential functionality, consider temporarily reverting to Joomla 5.0.3 where this issue does not occur until a fix is found.
Custom JavaScript Fix:
As a temporary workaround, you can consider adding custom JavaScript to handle the getSelection issue. This could involve modifying the joomla-media-select.min.js file or adding a script that ensures the getSelection function is correctly defined.
Report the Bug:
If this issue persists and there's no immediate fix, report it to the Joomla development team. Provide the detailed error message and context to help them diagnose and resolve the issue in a future update.
Alternative Editors:
Consider using an alternative editor to TinyMCE, such as JCE, which might not have this issue.
Here's a sample of custom JavaScript you could try as a temporary workaround:
javascript
Copy code
document.addEventListener('DOMContentLoaded', function() {
if (typeof window.getSelection === 'undefined') {
window.getSelection = function() {
return {
getRangeAt: function() {
return document.createRange();
}
};
};
}
});
Include this script in your Joomla template or add it through the template's custom JavaScript options if available.
If none of these steps work providing more specific details or context might help in identifying a more precise solution.
https://www.healthquestbilling.com/services/
Here are some potential steps to resolve or work around this issue:
Check for Plugin Conflicts:
Disable third-party plugins one by one to see if any of them are causing a conflict.
Specifically look at any plugins related to TinyMCE or the media manager.
Review Joomla Updates:
Ensure all Joomla core and extension updates are applied. There might be a minor update or patch available that addresses this issue.
Check the Joomla issue tracker and forums for any reported bugs or fixes related to this problem.
Revert to Previous Version:
If this issue is blocking essential functionality, consider temporarily reverting to Joomla 5.0.3 where this issue does not occur until a fix is found.
Custom JavaScript Fix:
As a temporary workaround, you can consider adding custom JavaScript to handle the getSelection issue. This could involve modifying the joomla-media-select.min.js file or adding a script that ensures the getSelection function is correctly defined.
Report the Bug:
If this issue persists and there's no immediate fix, report it to the Joomla development team. Provide the detailed error message and context to help them diagnose and resolve the issue in a future update.
Alternative Editors:
Consider using an alternative editor to TinyMCE, such as JCE, which might not have this issue.
Here's a sample of custom JavaScript you could try as a temporary workaround:
javascript
Copy code
document.addEventListener('DOMContentLoaded', function() {
if (typeof window.getSelection === 'undefined') {
window.getSelection = function() {
return {
getRangeAt: function() {
return document.createRange();
}
};
};
}
});
Include this script in your Joomla template or add it through the template's custom JavaScript options if available.
If none of these steps work providing more specific details or context might help in identifying a more precise solution.
https://www.healthquestbilling.com/services/
Statistics: Posted by sara+69 — Fri Jun 28, 2024 2:28 pm